Mapping from voxel i,j,k in image A.img to the appropriate voxel in
image B.img would be done by:
MA=spm_get_space('A.img');
MB=spm_get_space('B.img');
M = MB\MA;
vox = M(1:3,:)*[i; j; k; 1]
Note that voxels are indexde from 1..N rather than from 0..N-1.
Best regards,
-John
2012/1/9 Sinem Burcu Erdoğan <[log in to unmask]>:
> Dear SPMers;
> I have a question related to finding the transfer matrix that maps
> anatomical image to functional image. I have coregistered my structural
> (256*256*125) and functional images (64*64*30) and obtained a coregistered
> image( 64*64*30). Now I want to find the voxel to which a voxel in my
> anatomical image is mapped to on the coregistered image. When the
> coregistered image is read; there are matirces with names vox2ras0 vox2ras1
> and tkrvox2ras but when i perform matrix multiplication with the coordinates
> of one anatomical voxel (i.e [64 217 180 1]) i cannpt get the corresponding
> voxel on the coregistered image. Will you please explain me which matrix is
> used to map anatomical voxels to voxels in the coregistered image?
>
>
> Thank you;
> Burcu
>
> --
> Sinem Burcu ERDOĞAN
> Research Assistant
> Bogazici University
> Biomedical Engineering Institute
> Kandilli Kampüs
> 34684 Çengelköy / İSTANBUL TURKEY
> Tel :+90-216-5163433
> Fax :+90-216-5163479
> e-mail: [log in to unmask]
|