git.schokokeks.org
Repositories
Help
Report an Issue
SVMCrossVal.git
Code
Commits
Branches
Tags
Suche
Strukturansicht:
2095645
Branches
Tags
master
SVMCrossVal.git
VoxelValueAtTimepoint.m
SVMCrossVal toolbox init
Christoph Budziszewski
commited
2095645
at 2008-12-17 13:45:29
VoxelValueAtTimepoint.m
Blame
History
Raw
function vValue = VoxelValueAtTimepoint (coordinate, timepoint) % single Voxel for single coordinate if(size(coordinate,2)>1) error('VoxelValueAtTimepoint:CoordinateError','only single Coordinate permitted.'); end imageNumber = timePointToImageNumber(timepoint, 's'); V = evalin('base','SPM.xY.VY'); % Memory Mapped Images center = round(inv(V(imageNumber).mat)*[coordinate; 1]); x = center(1,1); y = center(2,1); z = center(3,1); vValue = spm_sample_vol(V(imageNumber), x, y, z, 0); end