Print

Print


Hi Allison,

This looks like a shell scripting issue. Have you tried escaping the inner
quotes? Something as "\"Atlas Name\""?

You might as well just drop the for-loop and copy-paste the command for as
many atlases you are interested in, and making small edits by hand. The
number isn't too large, shouldn't be no more than a handful.

All the best,

Anderson


On 29 August 2017 at 21:11, Allison Jack <[log in to unmask]> wrote:

> Hi FSL experts,
>
> I'm trying to use autoaq with a for loop that cycles through a couple
> different atlases. Right now I'm just going off of the usage text for
> autoaq; I couldn't find any documentation for the tool on the wiki and I
> didn't see an answer on the listserv--apologies if I've missed something.
>
> Basically, I'm looking for an example of correct usage of the -u option.
> Everything works great when I run it outside of a loop, e.g.,
>
>  autoaq -i thresh_tstat1.nii.gz -a "Juelich Histological Atlas" -t .0001
> -p -u -o test.txt
>
> But then I tried this:
>
> for ATLAS in '"Juelich Histological Atlas"' '"Harvard-Oxford Cortical
> Structural Atlas"'; do
>  autoaq -i thresh_tstat1.nii.gz -a $ATLAS -t .0001 -p -u -o test_loop.txt
> done
>
> and I got the following errors:
>
> /Applications/fsl/bin/autoaq: line 69: ${OUT}: ambiguous redirect
> /Applications/fsl/bin/autoaq: line 76: ${NEWOUT}: ambiguous redirect
>
> And then it dumped the usage for cluster.
>
> Help?
>
> Thanks!
> A
>