Hi - avwmaths is old C code, you should try avwmaths++
This should output the same type as the input, or you can force it
with the -odt option at the very end of the command.
This may also fix the header problem, if not you'll need to look into
your code to see which field it's unhappy with...
Cheers, Steve.
On 16 Nov 2006, at 09:42, Alle Meije Wink wrote:
> Hi, I tried to mask a statistic image with a template, by doing
>
> $avwmaths Stat0.nii -mas Templ.nii maskedStat0.nii
>
> masking went fine, everything looks OK in FSLview, but when I try
> to open the masked image in my own program (which is based on the
> NifTI reference library) it says `not a valid nifti file'. Does
> avwmaths do anything to the header, or something like that, that
> makes the NifTI ref lib not recognise it anymore?
>
> Also, the data type has changed, without me asking for it, from
> double to float. Is there any reason for that (and could that
> reason be removed?)
>
> Thanks very much
> Alle Meije
------------------------------------------------------------------------
---
Stephen M. Smith, Professor of Biomedical Engineering
Associate Director, Oxford University FMRIB Centre
FMRIB, JR Hospital, Headington, Oxford OX3 9DU, UK
+44 (0) 1865 222726 (fax 222717)
[log in to unmask] http://www.fmrib.ox.ac.uk/~steve
------------------------------------------------------------------------
---
|