Hi Alex, we don't have an elegant solution to this, but you can do it in matlab easily enough. If your data D are in a N-by-327684 matrix (I assume that this is left and right hemis), then
a.vol = permute(D(:,1:163842),[2 3 4 1]); MRIwrite(a,'lh.yourdata.mgh');
b.vol = permute(D(:,163843:end),[2 3 4 1]); MRIwrite(b,'rh.yourdata.mgh');
doug
Alexander Lebedev wrote:
Excuse me for disturbing Douglas,
The matter is that I have the coefficients for each vertex and I would like to find the easiest way to display them into the brain space, showing their importance for the classification. My original ascii file contains N-by-327684 matrix (N subjects, 327 684 vertices - 163 842 for each hemisphere). But I can easily change it if necessary... I'm just wondering if there is a way to do this... I'm asking because it seems like "y.mgh -> y.asc" (mri_convert y.mgh y.ascii --ascii) conversion is available only one-way.
Regards, Alex
- Alexander Lebedev awlman@rambler.ru [Fri, 27 Jan 2012 10:07:11
+0400]:
Yes, sorry...
Alex
Hi Alex, I'm not sure I understand what you mean. Do you mean that
you
have a coefficient for each vertex and you want to display your
results
on a surface and need to get them into a format that FS can read? doug
Alexander Lebedev wrote:
Yes, thanks a lot Douglas! That's what I was looking for. And it's much easier than my approach... I needed to extract the vertices
in
order to perform a multivariate analysis in R. May I also ask
another
question then? I have performed pls-regression and would like to
map
the coefficients into the brain space... Is there such an
opportunity
(at least theoretically speaking) ?
Regards, Alex