Browse code

moved helpercode to private

git-svn-id: https://svn.discofish.de/MATLAB/spmtoolbox/SVMCrossVal@97 83ab2cfd-5345-466c-8aeb-2b2739fb922d

Christoph Budziszewski authored on07/01/2009 09:24:55
Showing1 changed files
1 1
deleted file mode 100644
... ...
@@ -1,20 +0,0 @@
1
-function vValue = VoxelValueAtTimepoint (coordinate, timepoint)
2
-% single Voxel for single coordinate
3
-
4
-if(size(coordinate,2)>1)
5
-    error('VoxelValueAtTimepoint:CoordinateError','only single Coordinate permitted.');
6
-end
7
-
8
-imageNumber = timePointToImageNumber(timepoint, 's');
9
-V           = evalin('base','SPM.xY.VY'); % Memory Mapped Images
10
-center      = round(inv(V(imageNumber).mat)*[coordinate; 1]);
11
-
12
-x           = center(1,1);
13
-y           = center(2,1);
14
-z           = center(3,1);
15
-
16
-vValue      = spm_sample_vol(V(imageNumber), x, y, z, 0);
17
-
18
-end
19
-
20
-
Browse code

SVMCrossVal toolbox init

git-svn-id: https://svn.discofish.de/MATLAB/spmtoolbox/SVMCrossVal@90 83ab2cfd-5345-466c-8aeb-2b2739fb922d

Christoph Budziszewski authored on17/12/2008 13:45:29
Showing1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,20 @@
1
+function vValue = VoxelValueAtTimepoint (coordinate, timepoint)
2
+% single Voxel for single coordinate
3
+
4
+if(size(coordinate,2)>1)
5
+    error('VoxelValueAtTimepoint:CoordinateError','only single Coordinate permitted.');
6
+end
7
+
8
+imageNumber = timePointToImageNumber(timepoint, 's');
9
+V           = evalin('base','SPM.xY.VY'); % Memory Mapped Images
10
+center      = round(inv(V(imageNumber).mat)*[coordinate; 1]);
11
+
12
+x           = center(1,1);
13
+y           = center(2,1);
14
+z           = center(3,1);
15
+
16
+vValue      = spm_sample_vol(V(imageNumber), x, y, z, 0);
17
+
18
+end
19
+
20
+