3dLME scripting issue help?

Hello, I’m a new AFNI user and I’m having some trouble getting an ICC analysis to run with the 3dLME function. Below is the error I’m getting as well as the model specification and data table I’ve been trying to run. I’ve also attached the output of the system check. Any one have ideas about what might be causing the error? Thank you in advance!

***** Summary information of data structure *****
38 subjects : s101 s103 s104 s105 s106 s107 s108 s109 s110 s111 s112 s113 s114 s115 s116 s117 s118 s119 s120 s201 s203 s204 s205 s206 s207 s208 s209 s210 s211 s212 s213 s214 s215 s216 s217 s218 s219 s220
76 response values
2 levels for factor Session : one two
0 post hoc tests

Contingency tables of subject distributions among the categorical variables:

Error in parse(text = x, keep.source = FALSE) :
:1:3: unexpected input
1: ~ â
Calls: as.formula … formula → formula.character → formula → eval → parse
Execution halted


This is the content of the text file I call in the terminal with the command tcsh -x 3dLME.txt

3dLME -prefix ICCoutput.nii -jobs 4
-model ‘1’
-ranEff ‘Session+Subj’
Subj Session InputFile
s101 one ToAnalyze/Reliability/101/s1/cope5.nii.gz
s101 two ToAnalyze/Reliability/101/s2/cope5.nii.gz
s103 one ToAnalyze/Reliability/103/s1/cope5.nii.gz
s103 two ToAnalyze/Reliability/103/s2/cope5.nii.gz
s104 one ToAnalyze/Reliability/104/s1/cope5.nii.gz
s104 two ToAnalyze/Reliability/104/s2/cope5.nii.gz
s105 one ToAnalyze/Reliability/105/s1/cope5.nii.gz
s105 two ToAnalyze/Reliability/105/s2/cope5.nii.gz
s106 one ToAnalyze/Reliability/106/s1/cope5.nii.gz
s106 two ToAnalyze/Reliability/106/s2/cope5.nii.gz
s107 one ToAnalyze/Reliability/107/s1/cope5.nii.gz
s107 two ToAnalyze/Reliability/107/s2/cope5.nii.gz
s108 one ToAnalyze/Reliability/108/s1/cope5.nii.gz
s108 two ToAnalyze/Reliability/108/s2/cope5.nii.gz
s109 one ToAnalyze/Reliability/109/s1/cope5.nii.gz
s109 two ToAnalyze/Reliability/109/s2/cope5.nii.gz
s110 one ToAnalyze/Reliability/110/s1/cope5.nii.gz
s110 two ToAnalyze/Reliability/110/s2/cope5.nii.gz
s111 one ToAnalyze/Reliability/111/s1/cope5.nii.gz
s111 two ToAnalyze/Reliability/111/s2/cope5.nii.gz
s112 one ToAnalyze/Reliability/112/s1/cope5.nii.gz
s112 two ToAnalyze/Reliability/112/s2/cope5.nii.gz
s113 one ToAnalyze/Reliability/113/s1/cope5.nii.gz
s113 two ToAnalyze/Reliability/113/s2/cope5.nii.gz
s114 one ToAnalyze/Reliability/114/s1/cope5.nii.gz
s114 two ToAnalyze/Reliability/114/s2/cope5.nii.gz
s115 one ToAnalyze/Reliability/115/s1/cope5.nii.gz
s115 two ToAnalyze/Reliability/115/s2/cope5.nii.gz
s116 one ToAnalyze/Reliability/116/s1/cope5.nii.gz
s116 two ToAnalyze/Reliability/116/s2/cope5.nii.gz
s117 one ToAnalyze/Reliability/117/s1/cope5.nii.gz
s117 two ToAnalyze/Reliability/117/s2/cope5.nii.gz
s118 one ToAnalyze/Reliability/118/s1/cope5.nii.gz
s118 two ToAnalyze/Reliability/118/s2/cope5.nii.gz
s119 one ToAnalyze/Reliability/119/s1/cope5.nii.gz
s119 two ToAnalyze/Reliability/119/s2/cope5.nii.gz
s120 one ToAnalyze/Reliability/120/s1/cope5.nii.gz
s120 two ToAnalyze/Reliability/120/s2/cope5.nii.gz
s201 one ToAnalyze/Reliability/201/s1/cope5.nii.gz
s201 two ToAnalyze/Reliability/201/s2/cope5.nii.gz
s203 one ToAnalyze/Reliability/203/s1/cope5.nii.gz
s203 two ToAnalyze/Reliability/203/s2/cope5.nii.gz
s204 one ToAnalyze/Reliability/204/s1/cope5.nii.gz
s204 two ToAnalyze/Reliability/204/s2/cope5.nii.gz
s205 one ToAnalyze/Reliability/205/s1/cope5.nii.gz
s205 two ToAnalyze/Reliability/205/s2/cope5.nii.gz
s206 one ToAnalyze/Reliability/206/s1/cope5.nii.gz
s206 two ToAnalyze/Reliability/206/s2/cope5.nii.gz
s207 one ToAnalyze/Reliability/207/s1/cope5.nii.gz
s207 two ToAnalyze/Reliability/207/s2/cope5.nii.gz
s208 one ToAnalyze/Reliability/208/s1/cope5.nii.gz
s208 two ToAnalyze/Reliability/208/s2/cope5.nii.gz
s209 one ToAnalyze/Reliability/209/s1/cope5.nii.gz
s209 two ToAnalyze/Reliability/209/s2/cope5.nii.gz
s210 one ToAnalyze/Reliability/210/s1/cope5.nii.gz
s210 two ToAnalyze/Reliability/210/s2/cope5.nii.gz
s211 one ToAnalyze/Reliability/211/s1/cope5.nii.gz
s211 two ToAnalyze/Reliability/211/s2/cope5.nii.gz
s212 one ToAnalyze/Reliability/212/s1/cope5.nii.gz
s212 two ToAnalyze/Reliability/212/s2/cope5.nii.gz
s213 one ToAnalyze/Reliability/213/s1/cope5.nii.gz
s213 two ToAnalyze/Reliability/213/s2/cope5.nii.gz
s214 one ToAnalyze/Reliability/214/s1/cope5.nii.gz
s214 two ToAnalyze/Reliability/214/s2/cope5.nii.gz
s215 one ToAnalyze/Reliability/215/s1/cope5.nii.gz
s215 two ToAnalyze/Reliability/215/s2/cope5.nii.gz
s216 one ToAnalyze/Reliability/216/s1/cope5.nii.gz
s216 two ToAnalyze/Reliability/216/s2/cope5.nii.gz
s217 one ToAnalyze/Reliability/217/s1/cope5.nii.gz
s217 two ToAnalyze/Reliability/217/s2/cope5.nii.gz
s218 one ToAnalyze/Reliability/218/s1/cope5.nii.gz
s218 two ToAnalyze/Reliability/218/s2/cope5.nii.gz
s219 one ToAnalyze/Reliability/219/s1/cope5.nii.gz
s219 two ToAnalyze/Reliability/219/s2/cope5.nii.gz
s220 one ToAnalyze/Reliability/220/s1/cope5.nii.gz
s220 two ToAnalyze/Reliability/220/s2/cope5.nii.gz \



Most likely the problem is caused by the editor you’re using. In the following two lines:

-model ‘1’ \
-ranEff ‘Session+Subj’ \

the quotes are not in a pure text format. So, use a plain text editor and replace the quotes.

Hi Gang,
I finally got back to working on this analyses, and I got it running based on your advice so thank you!

I ran the ICC analysis in order to get an image output of the reliability of a task across two scanning sessions, but I’m a bit confused by the output. There are large ‘holes’ in the image–in other words, fairly large clusters of voxels with an ICC statistic of 0. Although it could be possible that no subjects show activation in these regions, it seems unlikely that all would be 0. In the analysis, is there a certain number of non-zero inputs for a voxel needed for the ICC to be computed? I’m not sure I’ve explained this well so let me know if it is not clear.

Thanks again,


3dLME -ICC provides the estimates for ICC(2,1), which is labeled as “subject” in the output. So make sure that you’re looking at the “subject” sub-brick. If you see some zero ICC values, it means that the variance is negative at those voxels; see discussion here: https://www.biorxiv.org/content/early/2017/10/11/164327

Hi Gang,

Thank you, that makes sense then. Is it possible to compute an ICC(3,1) in 3dLME, or would I need to use 3dICC.R instead?


Is it possible to compute an ICC(3,1) in 3dLME, or would I need to use 3dICC.R instead?

I was planning to write a separate program 3dICC to include all variations, but unfortunately I haven’t implemented the plan yet. Drop me a line if you want to try a temporary version of the program.