Differences between revisions 35 and 43 (spanning 8 versions)
Revision 35 as of 2012-12-09 16:42:13
Size: 6166
Editor: jbernal
Comment:
Revision 43 as of 2018-07-25 11:57:07
Size: 8049
Comment:
Deletions are marked like this. Additions are marked like this.
Line 2: Line 2:
Line 4: Line 3:

This page describes ways of analyzing longitudinal data after processing it using the [[ LongitudinalProcessing | longitudinal stream ]] in Freesurfer.
This page describes ways of analyzing longitudinal data after processing it using the [[LongitudinalProcessing|longitudinal stream]] in Freesurfer.
Line 9: Line 7:
Freesurfer currently comes with (at least) three different frameworks for the analysis of longitudinal data: 
 1. Simplified repeated measures ANOVA (ignores correlation and timing of the measurement occasions)   2. Direct analysis of atrophy rates or percent changes (ignores correlation and single time points)
 3. Linear mixed effects models <-- recommended, but more complex 
Freesurfer currently comes with (at least) three different frameworks for the analysis of longitudinal data:

 1. Simplified [[RepeatedMeasuresAnova|repeated measures ANOVA]] (ignores correlation and timing of the measurement occasions)
 1
. [[LongitudinalTwoStageModel|Direct analysis of atrophy]] rates or percent changes (ignores correlation and single time points)
 1. [[LinearMixedEffectsModels|Linear mixed effects models]] <-- '''recommended''' (but more complex)

<<TableOfContents(2)>>
Line 16: Line 18:

This method can be used to check for differences between individual time points or compare time point differences across groups. For two time points it simplifies to a [[ PairedAnalysis ]]. 
This method can be used to check for differences between individual time points or compare time point differences across groups. For two time points it simplifies to a PairedAnalysis.
Line 20: Line 21:
Line 22: Line 24:
 * Can make use of different multiple comparisons methods that come with mri_glmfit.    * Can make use of different multiple comparisons methods that come with mri_glmfit.
Line 26: Line 27:
Line 27: Line 29:
 * Does NOT consider the timing of the measurement occasions which may result in a further reduction in power.   * Does NOT consider the timing of the measurement occasions which may result in a further reduction in power.
Line 30: Line 32:
For details see: [[ RepeatedMeasuresAnova ]] For details see: RepeatedMeasuresAnova
Line 35: Line 37:
To analyze, e.g. annualized percent change or atrophy rates for 2 or more time points, one can run a two stage model. This avoids dealing with the longitudinal correlation. The two stages are:
Line 36: Line 39:
To analyze, e.g. annualized percent change or atrophy rates for 2 or more time points, one can run a two stage model. This avoids dealing with the longitudinal correlation. The two stages are:
Line 38: Line 40:
 2. Then analyze the obtained summary measure across subjects or groups with a standard GLM.  1. Then analyze the obtained summary measure across subjects or groups with a standard GLM.
Line 40: Line 42:
This model is quite simple and can be a good choice if all subjects have the same number of time points. Linear fits into each subject data are often meaningful, as longitudinal change is almost linear within a short time frame of a few years. This model is quite simple and can be an option if all subjects have the same number of time points, approximately equally spaced. Linear fits into each subject data are often meaningful, as longitudinal change can be assumed to be almost linear within a short time frame in several applications.
Line 43: Line 45:
 * Modeling the correlation structure can be avoided.
 * Can deal with differently spaced time points.

 * Can deal with differently many and differently spaced time points (but does not model the difference in variability).
Line 49: Line 51:
 * For the simple case of two time points and when looking at simple differences this model simplifies to a paired analysis, but can additionally compute (symmetrized) percent changes. 
 * Includes code for intersecting cortex labels (across time and across subjects) to make sure that all non-cortex measures are excluded.
 * For the simple case of two time points and when looking at simple differences this model simplifies to a paired analysis, but can additionally compute (symmetrized) percent changes.
 * Includes code for intersecting cortex labels (across time and across subjects) to make sure that all non-cortex vertices are excluded.
Line 53: Line 55:
Line 57: Line 60:
 * Cannot include information from subjects with only a single time point and thus the results are likely to be biased. This also results in a further reduction in statistical power.  * Cannot include information from subjects with only a single time point and thus the results are likely to be biased and have less statistical power.
Line 59: Line 62:
The linear mixed effects model overcomes these limitations and should be used if subjects have differently many time points (or for more complex modeling).  The linear mixed effects model overcomes these limitations and should be used if subjects have differently many time points (or for more complex modeling).
Line 61: Line 64:
For details see: [[ LongitudinalTwoStageModel ]] For details see: LongitudinalTwoStageModel
Line 66: Line 69:

A Linear Mixed Effects (LME) model is the most powerful and principled approach.
A Linear Mixed Effects (LME) model is the most powerful and principled approach. We recommend this approach.
Line 70: Line 72:
Line 71: Line 74:
 * Can handle imperfect timing and different number of time points across subjects (missing data).
 * Even subjects with only a single time point can be included into these models (make sure they also run through the longitudinal stream, available with version FS 5.2, to avoid a bias due to different processing)
 * Can handle unequal timing and different number of time points across subjects (missing data).
 * Even subjects with only a single time point can be included into these models (make sure they also run through the longitudinal stream, available with version FS 5.2, to avoid a bias due to different image processing) .
Line 75: Line 78:
 * Our mass-univariate method can deal very well with the spatial correlation among measurements on the cortex and is very fast by working with spatial regions.
 * Can be used to model more complex longitudinal behavior (e.g. quadratic, or piecewise linear trajectories) and time-varying covariates.
 * It must be kept in mind that because longitudinal mixed-effects model tools are now publicly available it is likely that journal reviewers will demand those appropriate statistical models for your longitudinal studi
es.
 * Our mass-univariate method can deal very well with the spatial correlation among measurements on the cortex and is very fast by working with spatial regions in which the correlation structure is relative constant.
 * Can be used to model complex longitudinal behavior (e.g. quadratic, or piecewise linear trajectories) and time-varying covariates.
 * It seems to have become the consensus among statisticians that LME models are the right mechanism to study longitudinal data and they may be requested in journal publications by the reviewers.
Line 81: Line 83:
 * More complicated use (eg. requires distinguishing mixed effects, fixed effects ...).
 * Currently, our implementation is in Matlab.
 * Only offers FDR for multiple comparisons correction.
Line 85: Line 84:
For details see: [[ LinearMixedEffectsModels ]]  * More complicated use (e.g. requires distinguishing mixed effects from fixed effects ...).
 * Currently, our implementation is in Matlab only.
 * Currently only offers FDR for multiple comparisons correction.

[[LinearMixedEffectsModels]] allow ROI analysis as well as advanced longitudinal analysis for cortical maps. Here we only discuss how to prepare your data for that analysis. The analysis itself is performed in matlab.

Similar to regular (cross sectional) processing, ROI stats data is contained in stats files (cf. the ROI tutorial). You could, e.g., open the stats text files in each {{{tpN.long.templateID/stats/}}} dir, containing statistics such as volume of subcortical structures or thickness averages for cortical regions. These statistics can be fed into any external statistical packages to run whatever analysis you are interested in. Helpful commands to grab the data from all subjects and time points and create a single table are {{{asegstats2table}}} and {{{aparcstats2table}}}.

For example to create a table with subcoritical ROI's from all subjects and all time points you would run this :

{{{
asegstats2table --qdec-long long.qdec.table.dat --stats aseg.stats --tablefile aseg.table.txt
}}}

This will automatically grab the stats from the longitudinal directories ({{{tpN.long.templateID/stats/}}}) and create a table (rows: subject/time points, columns: structures). Similarly you can use {{{aparcstats2table}}} for surface ROI analysis.

To run [[LinearMixedEffectsModels]] on surface maps, you need to map all the data to a template (usually fsaverage) and smooth the data:
{{{
mris_preproc --qdec-long long.qdec.table.dat --target fsaverage --hemi lh --meas thickness --out lh.thickness.stack.mgh
mri_surf2surf --hemi lh --s fsaverage --sval lh.thickness.stack.mgh --tval lh.thickness.stack.fwhm10.mgh --fwhm-trg 10 --cortex --noreshape
}}}

For details see: LinearMixedEffectsModels

Longitudinal Statistics

This page describes ways of analyzing longitudinal data after processing it using the longitudinal stream in Freesurfer.

Longitudinal data are more complex than cross-sectional data, as repeated measures are correlated within each subject. The strength of this correlation will depend on the time separation between scans. In addition, extra care must be taken when the data exhibit significant between-subject variation in number of time points and between-scan intervals (imperfect timing). A statistical analysis should then consider these data features in order to obtain valid statistical inferences.

Freesurfer currently comes with (at least) three different frameworks for the analysis of longitudinal data:

  1. Simplified repeated measures ANOVA (ignores correlation and timing of the measurement occasions)

  2. Direct analysis of atrophy rates or percent changes (ignores correlation and single time points)

  3. Linear mixed effects models <-- recommended (but more complex)


Simplified Repeated Measures ANOVA

This method can be used to check for differences between individual time points or compare time point differences across groups. For two time points it simplifies to a PairedAnalysis.

Advantages:

  • Included in mri_glmfit.
  • Does not assume any specific trend in the mean response over time and thus can capture complex trajectories.
  • Can make use of different multiple comparisons methods that come with mri_glmfit.

Disadvantages:

  • Does NOT consider the correlation among the repeated measures, and thus, there is a significant reduction in statistical power.
  • Does NOT consider the timing of the measurement occasions which may result in a further reduction in power.
  • Can only be applied to balanced data (all subject have their scans acquired at the same set of measurement occasions) with a small number of repeated measures (<=3).

For details see: RepeatedMeasuresAnova


Analysis of Rates or Percent Changes

To analyze, e.g. annualized percent change or atrophy rates for 2 or more time points, one can run a two stage model. This avoids dealing with the longitudinal correlation. The two stages are:

  1. First, simplify the statistic to a single number for each subject (the difference of two time points, or the slope of the fitting line, or the annualized percent change, etc...).
  2. Then analyze the obtained summary measure across subjects or groups with a standard GLM.

This model is quite simple and can be an option if all subjects have the same number of time points, approximately equally spaced. Linear fits into each subject data are often meaningful, as longitudinal change can be assumed to be almost linear within a short time frame in several applications.

Advantages:

  • Can deal with differently many and differently spaced time points (but does not model the difference in variability).
  • Works on ROI stat (e.g. aseg.stats or aparc.stats) and on cortical maps (e.g. thickness).
  • The second stage can be performed with QDEC (simple GUI) or directly with mri_glmfit.
  • The second stage analysis can make use of different multiple comparisons methods that come with mri_glmfit.
  • Scripts are available ( long_mris_slopes and long_stats_slopes ), no matlab needed.
  • For the simple case of two time points and when looking at simple differences this model simplifies to a paired analysis, but can additionally compute (symmetrized) percent changes.
  • Includes code for intersecting cortex labels (across time and across subjects) to make sure that all non-cortex vertices are excluded.

Disadvantages:

  • Does NOT model the correlation among the repeated measures, and thus, there is a significant reduction in statistical power.
  • Does NOT account for different certainty of within subject slopes depending on the number of time points and therefore it has the highest propensity to false positives (type I family wise error in the mass-univariate setting).
  • Difficult to model non-linear temporal behaviour.
  • Difficult to deal with time varying co-variates (slopes would need to be fit into those for each subject to reduce these to a single number).
  • Cannot include information from subjects with only a single time point and thus the results are likely to be biased and have less statistical power.

The linear mixed effects model overcomes these limitations and should be used if subjects have differently many time points (or for more complex modeling).

For details see: LongitudinalTwoStageModel


Linear Mixed Effects Model

A Linear Mixed Effects (LME) model is the most powerful and principled approach. We recommend this approach.

Advantages:

  • Works for both stats (univariate) and surface analysis (mass-univariate).
  • Can handle unequal timing and different number of time points across subjects (missing data).
  • Even subjects with only a single time point can be included into these models (make sure they also run through the longitudinal stream, available with version FS 5.2, to avoid a bias due to different image processing) .
  • Appropriately models the temporal correlation.
  • Can model different variances across measurement occasions.
  • Our mass-univariate method can deal very well with the spatial correlation among measurements on the cortex and is very fast by working with spatial regions in which the correlation structure is relative constant.
  • Can be used to model complex longitudinal behavior (e.g. quadratic, or piecewise linear trajectories) and time-varying covariates.
  • It seems to have become the consensus among statisticians that LME models are the right mechanism to study longitudinal data and they may be requested in journal publications by the reviewers.

Disadvantages:

  • More complicated use (e.g. requires distinguishing mixed effects from fixed effects ...).
  • Currently, our implementation is in Matlab only.
  • Currently only offers FDR for multiple comparisons correction.

LinearMixedEffectsModels allow ROI analysis as well as advanced longitudinal analysis for cortical maps. Here we only discuss how to prepare your data for that analysis. The analysis itself is performed in matlab.

Similar to regular (cross sectional) processing, ROI stats data is contained in stats files (cf. the ROI tutorial). You could, e.g., open the stats text files in each tpN.long.templateID/stats/ dir, containing statistics such as volume of subcortical structures or thickness averages for cortical regions. These statistics can be fed into any external statistical packages to run whatever analysis you are interested in. Helpful commands to grab the data from all subjects and time points and create a single table are asegstats2table and aparcstats2table.

For example to create a table with subcoritical ROI's from all subjects and all time points you would run this :

asegstats2table --qdec-long long.qdec.table.dat --stats aseg.stats --tablefile aseg.table.txt

This will automatically grab the stats from the longitudinal directories (tpN.long.templateID/stats/) and create a table (rows: subject/time points, columns: structures). Similarly you can use aparcstats2table for surface ROI analysis.

To run LinearMixedEffectsModels on surface maps, you need to map all the data to a template (usually fsaverage) and smooth the data:

mris_preproc --qdec-long long.qdec.table.dat --target fsaverage --hemi lh --meas thickness --out lh.thickness.stack.mgh
mri_surf2surf --hemi lh --s fsaverage --sval lh.thickness.stack.mgh --tval lh.thickness.stack.fwhm10.mgh --fwhm-trg 10 --cortex --noreshape

For details see: LinearMixedEffectsModels


MartinReuter

LongitudinalStatistics (last edited 2018-07-25 12:06:32 by MorganFogarty)