I used the duration-modulated parameter for 3ddeconvolve (dmblock), so the output for each condition is not a single average Coefficient value, but instead, it is one coefficient value for each trial. For instance, for Subj1, the Cond1 output includes 'Cond1#0_Coef', 'Cond1#1_Coef', 'Cond1#2_Coef'...'Cond1#10_Coef'.
I want to use 3dmaskave to find the average signal change for Cond1, but there are a variable number of sub-bricks for each condition and each subject. Currently, I am able to do this by selecting the corresponding sub-brick indices for each condition, for example, 3dmaskave stats.subj1_REML+tlrc'[1..21(2)]. However, this is not a good solution, because there are a variable number of trials for each subject and each condition.
Is there a way to specify the condition, but instead of using the corresponding number (i.e. Cond1#2_Coef), use a wildcard indicator instead (e.g. Cond1#*_Coef)?
Thanks for the help!
best,
donna