> 1. You said "Personally, I would do it by relating together the old and new
> matrices in the header."
> How to relate?
> The transformation matrix is equal to new.head.mat / old.head.mat ?
You would divide one matrix by the other, either with a left division
or a right division. The exact way you do it would depend what you
want to do with the resulting matrix.
The old.head.mat is a mapping from voxel indices in the image to the
old mm coordinate system. The new.head.mat maps from the same voxel
indices to the new mm coordinate system. To map from the old mm
coordinate system to the new one, you would do:
new.head.mat / old.head.mat
This series of transforms begins by multiplying with the inverse of
old.head.mat. This inverse will map old mm coordinates to voxels.
Because the operations are performed from right to left, the next
operation is to multiply by new.head.mat. This maps voxels to the new
mm coordinates. Combining the two will give a mapping from the old mm
coordinate system to the new one.
To map from new mm coords to old ones, you would use:
old.head.mat / new.head.mat
>
> 2. "The matrix shown in the graphics window relates the voxels in one image
> to those in the other".
>
> Could you please explain more details?
> I means is it relationship of pixel value or physical coordination or voxel
> indices?
It provides a mapping from each voxel index in one image to its
estimated corresponding location (in voxel indices) in the other
image.
Best regards,
-John
> δΊ 2012-5-8 22:11, John Ashburner ει:
>
> Personally, I would do it by relating together the old and new
> matrices in the header. The matrix shown in the graphics window
> relates the voxels in one image to those in the other, which I don't
> think is what you want.
>
> Best regards,
> -John
>
>
> On 3 May 2012 09:51, Zhijiang Wang <[log in to unmask]> wrote:
>
> Hi, SPMers,
>
> After I do coregister/Estimate, there is a change in hdr.mat.
> But would anybody tell me how to get transformation matrix?
> I want to find the corresponding relationship of physical coordinates
> between two images peformed by coregister.
>
> In the results .ps file named by "spm_*.ps", there are 3 formulars about
> X1,Y1,Z1.
> Are they?
>
> Or through caculating the relationship between old.hdr.mat and new.hdr.mat?
>
> Great thanks!
>
>
> --
>
> Best wishes,
>
> Ross Wang
>
> --------------------------------------------
>
> PhD Candidate
>
> Room 407, East Segment, Material Science Building,
>
> The International WIC Institute,
>
> Brain Informatics,
>
> College of Computer Science and Technology,
>
> Beijing University of Technology,
>
> Beijing, China.
|