0001 function vb_plot_compare_brain(analyzefile, brainfile1, brainfile2)
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017 [B, Vdim, Vsize] = vb_load_analyze_to_right(analyzefile);
0018
0019
0020
0021
0022
0023 [V1, F1] = vb_load_cortex(brainfile1);
0024 F1 = F1.F3;
0025
0026 [V2, F2] = vb_load_cortex(brainfile2);
0027 F2 = F2.F3;
0028
0029
0030 V1 = vb_spm_right_to_analyze_right(V1,Vdim,Vsize);
0031 V2 = vb_spm_right_to_analyze_right(V2,Vdim,Vsize);
0032
0033
0034
0035
0036
0037
0038 vcut = 'z';
0039 zindx = [130:10:200];
0040
0041 Msize = 1;
0042 Mtype1 = 'y-';
0043 Mtype2 = 'c-';
0044 dz = 5;
0045 xymode = 1;
0046
0047
0048 NX = 2;
0049 NY = 2;
0050 Nfig = length(zindx);
0051 nfig = NX*NY;
0052
0053 for n= 1:Nfig
0054 if nfig==NX*NY,
0055 figure; nfig=1;
0056 else
0057 nfig=nfig+1;
0058 end;
0059
0060 subplot(NY,NX,nfig);
0061
0062 vb_plot_3d_image(B, zindx(n), vcut, xymode);
0063
0064 hold on
0065 vb_plot_cross_section(V1,F1,zindx(n),vcut,dz,Msize,Mtype1,xymode);
0066 vb_plot_cross_section(V2,F2,zindx(n),vcut,dz,Msize,Mtype2,xymode);
0067 title(['z-slice (' num2str(zindx(n),3) ')'])
0068 colormap(gray);
0069 end
0070
0071 return