Quantcast
Channel: NITRC CONN : functional connectivity toolbox Forum: help
Viewing all 6872 articles
Browse latest View live

RE: Setup taking a very long time

$
0
0
[color=#000000]Hello,[/color]

[color=#000000]I have a follow-up question to this. I am only processing 25 subjects, and I began running the setup ~48 hours ago and it's only 35% done with ROI extraction. I knew the processing would take time, but this seems excessive. Everything is stored locally. Is this normal? [/color]

[color=#000000]Thanks![/color]

[color=#000000]Best,[/color]

[color=#000000]Caitlin 
[/color][i]Originally posted by Alfonso Nieto-Castanon:[/i][quote][color=#000000]Hi Ami,[/color]

[color=#000000]Yes, the ROI extraction step can be particularly slow when the data is stored remotely. For relatively large datasets (e.g. hundreds of subjects) stored on a remote server I would strongly recommend using the parallelization options in CONN to speed-up your analyses (see if you institution offers cluster computing resources, if so you probably only need to know the scheduler used -e.g. Grid Engine, PBS, etc.- to use CONN's parallelization options). That can naturally speed up your analyses by several orders of magnitude. If that is not possible, then yes, moving your raw data to a local drive will still speed up all of your analyses considerably, so that is your next best choice. If your raw data is stored remotely, but your conn project is been saved to a local storage, then the Preprocessing and Setup steps will still take a relatively long time (since those steps use the raw data -remotely stored), but the subsequent Denoising/first-level/second-level analyses will be faster (since those steps no longer require the original raw data).  [/color]

[color=#000000]Hope this helps[/color]
[color=#000000]Alfonso [/color]

[color=#000000] 
[/color][i]Originally posted by Ami Tsuchida:[/i][quote]Hello,

I finished setting up functional/structural/ROI files for 200+ subjects, and pressed done in the Setup page of the GUI. It seems to be running without an error, but it's taking a very long time. In the data folder I see that it has created DATA_Subject...mat for each subject, as well as COV_Subject... and COND_Subject...mat files. It seems to be in the process of generating ROI_Subject...mat, but this is taking roughly 1 hour per subject. Is this normal?

I'm guessing that this is the step where it is extracting the time series from each ROI, but I selected average ts rather than PCA, so I'm not sure what's taking so long. I provided subject-specific gm/wm/csf masks previously processed with spm, as well as custom ROIs containing 384 labels. 

Elsewhere in the forum I saw that it's faster to write files locally, so I have project folder setup locally, and all the mat files are saved there. However, the raw functional/structural/ROI files are on a different server (or links to the files on a mounted server). If that's causing it to slow things down, do you recommend copying all the raw data? I wanted to avoid it if it's not necessary.

Please let me know if there is a quicker way to process them.

Thank you,

Ami[/quote][/quote]

RE: How does the CONN calc compute GLM stats?

$
0
0
[color=#000000]Hi Shady,[/color]

[color=#000000]The only difference there is that conn_glm is outputting the p-value associated with a one-tailed test while fitglm is outputting the two-tailed p-value instead (you can easily switch between the two by using "p2 = 2*min(p1,1-p1)", in this case simply p2=2*p1)[/color]

[color=#000000]Regarding the use of an intercept term, you are right that CONN will not automatically add an intercept term to your model. When necessary you simply have to explicitly add it by also selecting the "AllSubjects" term as part of your between-subject effects (e.g. to define a regression model you would select "AllSubjects" and your covariate and then specify a [0 1] contrast in order to evaluate the linear term). As to one is appropriate or not to explicitly include an intercept/constant term in your models there is no general rule there. Loosely speaking, you often include explicitly an AllSubjects term in regression models, but not in ANOVA-like models (where often this term is already implicitly defined through a combination of other selected effects). In any way, if CONN believes that you may be missing an intercept term in your second-level model (defined in the "second-level results" tab) it will tell you so with a message that reads something along the lines of "WARNING: possibly incorrect model" and you can see a few more details about your design by clicking on that message. [/color]

[color=#000000]Hope this helps[/color]
[color=#000000]Alfonso[/color]

[i]Originally posted by Shady El Damaty:[/i][quote]I've been playing with numbers in MATLAB and I think I've figured out how the calculator computes glm stats.  It appears that the calculator will not model an offset (or intercept) for a single factor analysis.

I ran conn_glm on a simple bivariate comparison and got the following stats:

h = 0.4712
F = 5.2878
p = 5.8960e-07
dof = 75

Note that I entered [1] for the design matrix.

Now in matlab,  using fitglm on the same data with the parameter 'intercept',false gives you:

d2~d1
distribution=normal

d = 0.57634
t = 5.2878
p = 1.1792e-06
dof = 75

The t stats are equal, however both the p values and h & d are different values.  Anyone know why this would be the case?  Also when is it appropriate to model your data with or without an intercept?[/quote]

RE: unequal group comparison

$
0
0
[color=#000000]Hi Johanna,[/color]

[color=#000000]Simply define a new second-level covariate named "case" containing 1 for the single-case subject and 0's for all the control subjects. Then in the [i]second-level results [/i]tab enter 'AllSubjects' and 'case' in the between-subject effects list and enter a [-1 1] contrast to evaluate the difference between your single-subject case and the control group. [/color]

[color=#000000]Hope this helps[/color]
[color=#000000]Alfonso[/color]
[color=#000000] 
[/color][i]Originally posted by Johanna Martin:[/i][quote]Hello all,

I'm new to conn and fMRI connectivity analysis.
I am running resting state connectivity analysis in a single case study.
I want to compare one single subject to a group of controls (n=14). I succeeded to run all steps needed to perform the analysis, but I have issues when it gets to comparing the subject to the control group.
I guess that there are several methods to do so, but I only know how to perform it in SPM (mainly by modifying the between-group variance). In your opinion, what could be the best option to run such analysis in Conn ?
Many thanks in advance !

Jo[/quote]

RE: CONN ROI without binary coding

$
0
0
[color=#000000]Hi Scott,[/color]

[color=#000000]Yes, that is perfetly fine, in the [i]Setup.ROIs [/i]tab, when defining that ROI simply select the option that reads "extract weighted sum" instead of "extract average" and that will weight each voxel by the mask value when computing the ROI timeseries (the "extract average" option effectively binarizes your mask by computing the average timeseries across any above-zero mask-value voxels, while the "extract weighted sum" will compute the weighted sum of the timeseries using each voxel mask value as the weights).[/color]

[color=#000000]Hope this helps[/color]
[color=#000000]Alfonso[/color]
[i]Originally posted by Scott Burwell:[/i][quote]Hello,

I have two questions regarding inputting an image file with a single ROI, thresholded by intensity (e.g., from ICA) but NOT binarized:
1. Will the resulting time-series for this ROI be weighted appropriately such that the most intense voxels contribute more to the ROI's time course than the ROI's least intense voxels? Or does CONN force binarizing on the ROI voxels upon import (weighting all voxels above some threshold the same)?
2. I know that people typically use binarized ROIs, but is a non-binarized ROI approach all that undesirable? I would like to construct separate ROIs from a single independent component via thresholding, but I would like to conserve the weighting for each ROI rather than binarize all ROIs. I understand that in practice, this might have to be done outside of the CONN framework, but it would be helpful to get y'alls take on the matter before I go too far down this path.

Best,
Scott[/quote]

Interaction: treatment x symptomscores

$
0
0
Dear Colleagues

I have a seamingly simple question for the second level seed2voxel analysis, where we are interested inthe effects of a treatment in relation to a numeric symptom score. So we have two groups: treatment & placebo. For each subject there is a score i.e. from 0-30.
we would first calculate:

(A) the contrast for the main effect of treatment: Treatment > Placebo [1-1]. Using the same seed we then calculate
(B) the contrast for the interaction: Treatment, Placebo, Scores for only the Treatment Group, Scores for only the Placebo Group [0 0 1 -1].

With the Rex toolbox, we then load the main effect results (from contrast (A)). Then in order to see, weather there is an effect of interaction (treatment x symptoms) we would load the SPM file of the interaction statistics (the spm.mat from (B)) and extract the results on a cluster level. As such, we then are able to interpret whether the aberrant connectivity due to treatment is affected by the sypmtomscores.

Is this procedure a valid approach?

Warm regards,
Julian

Leave one out scripts

$
0
0
Hi Alfonso,

Thank you for posting the CONN version of your SPM cross-validation scripts of the forum. The scripts work very nicely, but I have a few questions and could use some guidance on reporting the LOOCV output.

1) Are the values stored in the CV_DATA variable the GLM prediction errors after leaving out a given subject, correlations between PE estimated using the full dataset vs. the LOOCV data set, or an estimated beta value for the left out subject based on the remaining subjects?

2) Would running a t-test against zero on the CV_DATA be the correct way to validate a cluster extracted from a seed-to-voxel analysis?

3) If you were interested in testing the validity of a cluster extracted from a between-groups contrast how would one test that?  Would it be correct to use a two-sample test in this case?  

Thanks,
Jennifer

RE: reporting 3-way interaction

$
0
0
[color=#000000]Dear Alfonso and others,[/color]

[color=#000000]Having read and applied tips from below conversation I wanted to check whether my ANOVA is done correctly as well, as it is a bit more complicated and confusing.[/color]

[color=#000000]I have two groups, two working memory conditions (before and after intervention) with 4 levels, and three sets of ROIs I wish to test for connectivity changes. Since I do not hypothesise that the ROIs differ from each other regarding connectivity strength this is rather a 2-way ANOVA if I'm not mistaken?[/color]

So the working memory task (WM) has four increasing levels of difficulty, which I want to model as [-3 -1 1 3]. 

If my hypothesis is that there is a between-group difference in connectivity strength related to WM difficulty; then I want to model an F-test as follows:

Group: GroupA, GroupB
Conditions: WM_beforeIntervention level 1:4 [-3 1 1 3], WM_afterIntervention level 1:4 [-3 1 1 3]
ROI: 3 sets of ROIs that I want to test the connectivity between

F-test for Difference between groups - F-test for difference between before/after condition - test ROI connectivity

Group [1 -1;-1 1] - Condition [-3 -1 1 3 3 1 -1 -3; 3 1 -1 -3 -3 -1 1 3] - ROI [1] (select 'only test the 6 selected ROIs').

I hope I was clear in explaining my contrast. I wonder if above contrast is the best way to test this hypothesis? 

thanks for your time!
Helene


[i]Originally posted by Alfonso Nieto-Castanon:[/i][quote][color=#000000]Dear Bruno[/color]

[color=#000000]If you want to use F-stats (and that is typically the best choice for this sort of interaction analyses, unless you have an a priori hypothesis about the directionality of the expected interaction effect) simply switch the option in the [i]results explorer [/i]window that reads 'one-sided (positive)' to 'two-sided', and that will be exactly equivalent to the standard F-test (which is blind to the directionality of the interaction effect) for this same interaction analysis. [/color]

If in doubt, or if you prefer to have F-stat values directly, you could also simply enter in the 'between-subjects contrast' field [1 -1; 1 -1] (instead of just [1 -1]), and that will give you exactly the same results as the analysis above, but now all statistics will be reported using F-stats instead of T-stats. Another alternative would be, in the original analysis [i]results explorer [/i]window, click on the 'display SPM' button and define there a new F-contrast with the [-1 1] values. Again, all of these options will produce exactly the same second-level results as your original analyses (using the 'two-sided' option), you will see exactly the same significant clusters, the same cluster-level statistics, etc. (they will only vary in the choice of voxel-level statistics being reported -either T(dof) or F(1,dof) stats-) 

Hope this helps
Alfonso

[i]Originally posted by Bruno Baumann:[/i][quote]Dear Alfredo,

after reading several posts I'm still a bit puzzled how to report the results of a mixed-design ANOVA.
I set up a 2x2x2 model (group, condition, roi). The 3-way interaction gives me a T-value instead of F-values which would be expected for a rmANOVA for example.
group: [1 -1]
condition: [1 -1]
roi: [1 -1]
If I understand correctly this is founded in the way results are calculated (t-tests for within-subject-effects on 1st-level, subsequent results in t-tests on 2nd level (between-subjects-effects))
If I want to report F-values is it the correct way to calculate the F=t^2 as indicated in that post (https://www.nitrc.org/forum/message.php?...)?
I hope the specifications are sufficient.
Thanks in advance and best wishes,
Bruno[/quote][/quote]

RE: Error in Batching Results

$
0
0
Hi Alfonso,

I was wondering if you could look at my script.  I am still getting the same error.  I have searched through the forums for an answer and have come up empty handed.  I have also started several new scripts to try and figure out my error, but with 7 new scripts done, I still haven't found where I am going wrong.  Thank you for all your help!

Any help is appreciated!
Marlene

RE: T value interpretation in 2nd level analysis

$
0
0
Hi Alfonso

Thanks for your reply. Kind of put me in the right track. However, although I am using second level analysis and i am regressing the finding with the lateralization index, I am using just Lateralization index  in Subject Effects, one condition (rest), Between subject Contrast [1] and between condition contrast[ 1](see attached image).  Thanks to your reply I think I understand the the T value gives me the strength to reject the hypothesis of having no relationship between the connectivity of the analyzed ROI and the given lat index.

I have a group of 36 subjects, and I am  interested in calculating the fixed effect in the second level analysis. In the conn versions after conn12p, just the random effect is presented in second level analysis. Is there a way I can see the fixed effect results on each subject?where is it stored?  I noticed the only way to see that for a single subject is duplicating the subject and analyzing a group of 2 subjects.  This is a bit time consuming, is there a way I can get the fixed effect results in conn 15 or 16? I guess to have the second level random effect figured out you need to calculate somewhere the fixed effects in the population members. Any suggestion is highly appreciated.

Thanks a lot and best regards

Magno

fixed effect results in second level analysis

$
0
0
I have a group of 36 subjects, and I am interested in calculating the fixed effect in the second level analysis. In the conn versions after conn12p, just the random effect is presented in second level analysis. Is there a way I can see the fixed effect results on each subject?where is it stored? I noticed the only way to see that for a single subject is duplicating the subject and analyzing a group of 2 subjects. This is a bit time consuming, is there a way I can get the fixed effect results in conn 15 or 16? I guess to have the second level random effect figured out you need to calculate somewhere the fixed effects in the population members. Any suggestion is highly appreciated.

Thanks a lot and best regards

Magno

Despiking

$
0
0
Can anyone provide information on when I would choose:

No despiking
Despiking before regression
Despiking after regression

Thanks in advance

Andrew

Dynamic Connectivity Time Course Movie Save?

$
0
0
Hi, Alfonso,

Is there a "save as..." function for the CONN dynamic connectivity estimated dynamic connectivity or dynamic vs. static connectivity plot "play" feature?  It would be wonderful to have the ability to save these as a .mpg or other video file format.  Even better if you could save it with the temporal components and ROI-to-ROI connectivity dynamic series at the bottom with the plots at the top.

BTW - the dynamic connectivity features are awesome!  Are there plans to update the CONN manual with more explanatory text and guidance on its use?

Once again thank you and Susan for creating a wonderful resource for the imaging community.

Warm regards,
Jeff

ICA procedure?

$
0
0
Hello,

I have been unable to find specific information on how the CONN toolbox performs ICA on group data. The Whitfield-Gabrieli & Nieto-Castanon, 2012 paper doesn't go into detail about which flavor of ICA CONN uses.

Can anyone provide references or the specific procedure for how CONN carries out group ICA analysis?  Are any additional steps taken by the software to build confidence about the discovered components (like ICASSO)? 

Thank you very much,
Dan

registration problem

$
0
0
Hi!

I am running 7T MRI analyses in conn. The resting state is 1.25 mm isotropic, the T1 image is in 0.7mm isotropic.
For the ROIs then I am examining (small nuclei), I have used ANTs to coregister them to the T1's. 
I checked the registration in FSLview and it matched. 
Because of the noise surrounding the brain on 7T T1 images, I chose to use brain extracted T1s in fsl orientation (using fslreorient2std). The ROIs match on these skull-stripped FSL oriented T1s.

I uploaded these T1s, the registered ROis and the fMRI images to conn and applied the default preprocessing pipeline (changing the slice time correction manually and reducing the smoothing). Now, I see that the registration of the ROIs do not fit on the anatomical image and not on the fMRI image? (completely outside the brain)
What is happening here? What should I do?

Many thanks!
Heidi

Voxel size after preprocessing

$
0
0
Dear all,

after the default preprocessing pipeline of my rsfMRI data, the resulting data is a 91x109x91 matrix with voxel sizes 2mmx2mmx2mm. Is there any way I can get the resulting data after the preprocessing pipeline to be a 61x73x61 matrix with voxel size 3mmx3mmx3mm?

Best,
Sascha

RE: strategy to analyse surface-based data

$
0
0
dear experts

do you have any new ideas to this question below?

best wishes

[i]Originally posted by Vivian Roger Steiger:[/i][quote]Dear experts,

I'm a new user of Conn and need some advice from pros on how to properly setup a surface-based analysis.

So far I've conducted a surface-based analysis with FreeSurfer, where I got a lot of mc-corrected clusters in a simple group comparison approach.
(I've used 'make_average_subject' to generate a specific analysis space for stats instead of fsaverage since I have a special population)

I'd like to use these significant mc-corrected clusters to start a seed-based analysis using CONN and the corresponding resting state data in order bring structural and functional findings together.

What would be the optimal strategy to start such an analysis?

Thank you very much for your help

Best,

vivian[/quote]

Phase Correction

$
0
0
Hello,

I need to use the Conn preprocessing unwarping/phase procedure. I have an EPI series and an SPM (.nii) VDM. I am attempting to just use the Realignment. Unwarp, and phase correction preprocessing step...and would prefer not to run all the other preprocessing procedures. The EPI is loaded, but it does not ask me to load the VDM. It just gives me the following error:


ERROR DESCRIPTION:

Undefined function or variable 'fmfile'.
Error in conn_setup_preproc (line 776)
if isempty(fmfile),return;end
Error in conn (line 776)
ok=conn_setup_preproc('',varargin{2:end});
Error in conn_menumanager (line 119)
feval(CONN_MM.MENU{n0}.callback{n1}{1},CONN_MM.MENU{n0}.callback{n1}{2:end});
CONN v.16.b
SPM12 + DEM FieldMap MEEGtools
Matlab v.2013a
storage: 156753.0Gb available

Please advise.

Thank you!

-Nick

RE: Why are we getting "Nan"

$
0
0
[color=#000000]Hi Alfonso,[/color]

[color=#000000]I hope you're well. I know you are very busy, but it would be great to hear your thoughts on our previous questions (please see below) - we would deeply appreciate it. The main question is why do we get "NaN" in the results window for any ROI that is selected in the between source contrast - this is at the second level analysis? [/color]

[color=#000000]Many thanks,[/color]
[color=#000000]Diana.
[/color][i]Originally posted by Diana Parvinchi:[/i][quote]Hi Alfonso,

We have two questions regarding Conn and hope that you can help us. Before asking you the questions, let me quickly summarize our study. We are looking at the correlation between functional connectivity and social skills in 3 age groups of children and adolescents with autism spectrum disorder. We recently revised our list of ROIs and re-ran the analysis. In second-level results (ROI to ROI), we select 6 regressors (three age-groups and their corresponding scores on a given clinical measure) from the "subject effects" list. Then, we enter this contrast [0 0 0 1 0 0;0 0 0 0 1 0; 0 0 0 0 0 1] and select all of the ROI (24 in total) in the "between-sources contrasts" in order to run an f-test. Last time, we ran this procedure all went fine. However this time, for some reason, when a specific ROI is selected, that seed gets "NaN" for results in the Analysis results window - as if that seed is being masked – not examining FC with itself. As a result, when all ROIs are selected, we get "NaN" in the results window for all the seeds. The reason we are selecting all of the ROIs is to control for multiple comparisons.
1) Do you know why we're getting "Nan" this time and how can we control for multiple comparisons given this issue?
2) We are also getting an error message that reads:
"warning: no valid data for ROI 6 in /Users/Diana/Desktop/POND_Imaging_Data/MR160-088-0019-01/nifti_archive/rs_fmri_001.nii (scan # 1/120)"
Given this error message, will the later analyses be affected?

Thank you very much for your help.
Diana.[/quote]

RE: Creating preprocessing pipeline

$
0
0
Hi Humza,

That is a good point, currently there is no way in conn to save those changes and later import them into a standard preprocessing pipeline, I will see if I can add this functionality to one of the next releases. In the meantime I would probably suggest to simply use the save button in the SPM batch gui after making your changes, and then use scripts to automate the preprocessing steps; at that point you may load and run the saved batch step using something like:

spm_jobman('initcfg'); % general initialization (need to be run just once)

load mybatchstep.mat matlabbatch;
% here add any necessary changes to the matlabbatch variable (e.g. change the subjects)
spm_jobman('run',matlabbatch);

Hope this helps
Alfonso

[i]Originally posted by Humza Ahmed:[/i][quote]Hello I am trying to spatially preprocess data using the CONN GUI. Some of my preprocessing steps however will use settings that differ from the default SPM parameters. I realize that I can change the settings of individual preprocessing steps by going through the apply individual step option within the structural/functional menus. This opens up an SPM Batch Editor where I can make edits and save them. How can I ensure that these saved edits will be used when creating an actual pipeline in order to help automate processing.

Thanks,

Humza[/quote]

RE: "Imported Values" greater than 1?

$
0
0
Thanks Scott. I thought with a bivariate correlation the "import values" would return the raw correlation values, but I guess not :) 
Anyhow, thanks again for the reply.
Viewing all 6872 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>