This shows you the differences between two versions of the page.
neuroimagen:byicv [2016/07/19 10:38] osotolongo |
neuroimagen:byicv [2020/08/04 10:58] |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== How to correct by Intracranial Volume (ICV) ====== | ||
- | {{ : | ||
- | I'm going to suppose you did the pipeline thing over your MRI images and you already have the // | ||
- | <code bash> | ||
- | $ sed ' | ||
- | </ | ||
- | |||
- | Let's say we want to get the hippocampus volume (HV) corrected by ICV. Then we must get Left and Right HV and calculate its medium value. **HV = 0.5*(HVR+HVL)** | ||
- | |||
- | Now first step is to fit a straight line for HV //vs// ICV and the ICV mean value (< | ||
- | |||
- | Now we need to get the data. Let's try it in R. | ||
- | <code R> | ||
- | x <- read.csv(" | ||
- | x$HV = 0.5*(x$" | ||
- | a <- lm(x$HV~x$" | ||
- | b=a$coefficients[[2]] | ||
- | x$aHV = x$HV - b*(x$EstimatedTotalIntraCranialVol_eTIV - mean(x$EstimatedTotalIntraCranialVol_eTIV, | ||
- | write.csv(x, | ||
- | </ | ||
- | |||
- | ==== For ADNIMERGE package ==== | ||
- | |||
- | <code R> | ||
- | library(" | ||
- | a <- lm(adnimerge$Hippocampus~adnimerge$ICV) | ||
- | adnimerge$aHV = adnimerge$Hippocampus - a$coefficients[[2]]*(adnimerge$ICV - mean(adnimerge$ICV, | ||
- | </ |