%---------------------------------------------------------------
% model(1) Low-Off vs High Off
%---------------------------------------------------------------
%!!!!!
%Batch runs for new randomization (NOT ATTEMPT1 subjectsTN,AG,KL!!!)
%!!!!!
clear F1 F2 F3 F4 F5 F6 F10 F8 F9 F10 F11 F12 F13 F14 F15
Mask=['snra*.img'];
FolderName=['F:\Adjectives\RefSlice2\Attempt2\FS_Adj_04\SPM\Mov0'];
F1=spm_get('Files',FolderName,Mask);
RealignFile1=spm_get('Files',FolderName,['realignment*.*'])
RealignMat1=ReadTxtMat(RealignFile1,[6 132]);
RealignMat1=RealignMat1';
if size(RealignMat1)~=[132 6]
   error('size(RealignMat1)~=[132 6]')
end
FolderName=['F:\Adjectives\RefSlice2\Attempt2\FS_Adj_04\SPM\Mov1'];
F2=spm_get('Files',FolderName,Mask);
RealignFile2=spm_get('Files',FolderName,['realignment*.*'])
RealignMat2=ReadTxtMat(RealignFile2,[6 132]);
RealignMat2=RealignMat2';
if size(RealignMat2)~=[132 6]
   error('size(RealignMat2)~=[132 6]')
end
FolderName=['F:\Adjectives\RefSlice2\Attempt2\FS_Adj_04\SPM\Mov2'];
F3=spm_get('Files',FolderName,Mask);
RealignFile3=spm_get('Files',FolderName,['realignment*.*'])
RealignMat3=ReadTxtMat(RealignFile3,[6 132]);
RealignMat3=RealignMat3';
if size(RealignMat3)~=[132 6]
   error('size(RealignMat3)~=[132 6]')
end

%F1
%F2
%F3

% Mask=['snra*.img'];
% FolderName=['D:\fmri\Adjectives\Attempt2\FS_Adj_05\SPM\Mov0'];
% F4=spm_get('Files',FolderName,Mask);
% RealignFile4=spm_get('Files',FolderName,['realignment*.*'])
% RealignMat4=ReadTxtMat(RealignFile4,[6 132]);
% RealignMat4=RealignMat4';
% if size(RealignMat4)~=[132 6]
%    error('size(RealignMat4)~=[132 6]')
% end
% FolderName=['D:\fmri\Adjectives\Attempt2\FS_Adj_05\SPM\Mov1'];
% F5=spm_get('Files',FolderName,Mask);
% RealignFile5=spm_get('Files',FolderName,['realignment*.*'])
% RealignMat5=ReadTxtMat(RealignFile5,[6 132]);
% RealignMat5=RealignMat5';
% if size(RealignMat5)~=[132 6]
%    error('size(RealignMat5)~=[132 6]')
% end
% FolderName=['D:\fmri\Adjectives\Attempt2\FS_Adj_05\SPM\Mov2'];
% F6=spm_get('Files',FolderName,Mask);
% RealignFile6=spm_get('Files',FolderName,['realignment*.*'])
% RealignMat6=ReadTxtMat(RealignFile6,[6 132]);
% RealignMat6=RealignMat6';
% if size(RealignMat6)~=[132 6]
%    error('size(RealignMat6)~=[132 6]')
% end

%F4
%F5
%F6

Mask=['snra*.img'];
FolderName=['F:\Adjectives\RefSlice2\Attempt2\Jo_Adj_06\SPM\Mov0'];
F7=spm_get('Files',FolderName,Mask);
RealignFile7=spm_get('Files',FolderName,['realignment*.*'])
RealignMat7=ReadTxtMat(RealignFile7,[6 132]);
RealignMat7=RealignMat7';
if size(RealignMat7)~=[132 6]
   error('size(RealignMat7)~=[132 6]')
end
FolderName=['F:\Adjectives\RefSlice2\Attempt2\Jo_Adj_06\SPM\Mov1'];
F8=spm_get('Files',FolderName,Mask);
RealignFile8=spm_get('Files',FolderName,['realignment*.*'])
RealignMat8=ReadTxtMat(RealignFile8,[6 132]);
RealignMat8=RealignMat8';
if size(RealignMat8)~=[132 6]
   error('size(RealignMat8)~=[132 6]')
end
FolderName=['F:\Adjectives\RefSlice2\Attempt2\Jo_Adj_06\SPM\Mov2'];
F9=spm_get('Files',FolderName,Mask);
RealignFile9=spm_get('Files',FolderName,['realignment*.*'])
RealignMat9=ReadTxtMat(RealignFile9,[6 132]);
RealignMat9=RealignMat9';
if size(RealignMat9)~=[132 6]
   error('size(RealignMat9)~=[132 6]')
end

Mask=['snra*.img'];
FolderName=['F:\Adjectives\Adjectives_JQ_007\AdjMov0\3-20020605'];
F10=spm_get('Files',FolderName,Mask);
RealignFile10=spm_get('Files',FolderName,['realignment*.*'])
RealignMat10=ReadTxtMat(RealignFile10,[6 132]);
RealignMat10=RealignMat10';
if size(RealignMat10)~=[132 6]
   error('size(RealignMat10)~=[132 6]')
end

FolderName=['F:\Adjectives\Adjectives_JQ_007\AdjMov1\4-20020605'];
F11=spm_get('Files',FolderName,Mask);
RealignFile11=spm_get('Files',FolderName,['realignment*.*'])
RealignMat11=ReadTxtMat(RealignFile11,[6 132]);
RealignMat11=RealignMat11';
if size(RealignMat11)~=[132 6]
   error('size(RealignMat11)~=[132 6]')
end
FolderName=['F:\Adjectives\Adjectives_JQ_007\AdjMov2\5-20020605'];
F12=spm_get('Files',FolderName,Mask);
RealignFile12=spm_get('Files',FolderName,['realignment*.*'])
RealignMat12=ReadTxtMat(RealignFile12,[6 132]);
RealignMat12=RealignMat12';
if size(RealignMat12)~=[132 6]
   error('size(RealignMat12)~=[132 6]')
end

Mask=['snra*.img'];
FolderName=['F:\Adjectives\Adjectives_KP_008\AdjMov0\3-20020605'];
F13=spm_get('Files',FolderName,Mask);
RealignFile13=spm_get('Files',FolderName,['realignment*.*'])
RealignMat13=ReadTxtMat(RealignFile13,[6 132]);
RealignMat13=RealignMat13';
if size(RealignMat13)~=[132 6]
   error('size(RealignMat13)~=[132 6]')
end

FolderName=['F:\Adjectives\Adjectives_KP_008\AdjMov1\4-20020605'];
F14=spm_get('Files',FolderName,Mask);
RealignFile14=spm_get('Files',FolderName,['realignment*.*'])
RealignMat14=ReadTxtMat(RealignFile14,[6 132]);
RealignMat14=RealignMat14';
if size(RealignMat14)~=[132 6]
   error('size(RealignMat14)~=[132 6]')
end

FolderName=['F:\Adjectives\Adjectives_KP_008\AdjMov2\5-20020605'];
F15=spm_get('Files',FolderName,Mask);
RealignFile15=spm_get('Files',FolderName,['realignment*.*'])
RealignMat15=ReadTxtMat(RealignFile15,[6 132]);
RealignMat15=RealignMat15';
if size(RealignMat15)~=[132 6]
   error('size(RealignMat15)~=[132 6]')
end
pause(2)

F1
F2
F3
F7
F8
F9
F10
F11
F12
F13
F14
F15
%---------------------------------------------------------------
% batch variables defined here for analysis 'model'
%---------------------------------------------------------------

model(1) = struct( ...
 'types',          4, ...
 'global_effects', {'Scaling'}, ...
 'burst_mode',     0, ...
 'HF_fil',         'specify',  ...
 'HF_cut',         [48 48 48 48 48 48 48 48 48 48 48 48], ...
 'LF_fil',         'Gaussian', ...
 'LF_cut',         [4], ...
 'int_corr',       'none', ... 
 'now_later',      1, ...
 'stop_writing',   0, ...
 'trial_fcon',     0, ...
 'RT',             3, ...
 'replicated',     0, ...
 'same_time_param',0, ...
 'nsess',          12, ...
 'nscans',         [132 132 132 132 132 132 132 132 132 132 132 132 ], ...
 'files',          {{F1 F2 F3 F7 F8 F9 F10 F11 F12 F13 F14 F15}}, ...
 'conditions_nb',  [4 4 4 4 4 4 4 4 4 4 4 4 ], ...     
 'conditions',     [1 2 3 1 2 3 1 2 3 1 2 3], ...
 'regressors_nb',  [6 6 6 6 6 6 6 6 6 6 6 6 ], ...
 'regressors',     [1 2 3 7 8 9 10 11 12 13 14 15], ...
 'parametrics_type', {{'none','none','none', 'none', 'none', 'none','none', 'none', ...
     'none', 'none', 'none', 'none'}}, ...
 'parametrics',    [], ...
 'stochastics_flag',[0 0 0 0 0 0 0 0 0 0 0 0], ...
 'stochastics',    []);
 
NScanPerBlock=4;
Base=0.5;
% Video beginnt mit PseuAudi bei Volume 5 also sollte Base=1 sein
Vis1=[1 7 9 15 17 23 25 31].*NScanPerBlock+Base
Audi1 =[3 5 11 13 19 21 27 29].*NScanPerBlock+Base
PseuVis1=[2 6 12 16 20 24 26 30].*NScanPerBlock+Base
PseuAudi1 =[4 8 10 14 18 22 28 32].*NScanPerBlock+Base

% alt:
 Vis1a=[2 7 9 13 20 22 26 30].*NScanPerBlock+Base
 Audi1a =[3 5 11 14 17 25 29 31].*NScanPerBlock+Base
 PseuVis1a=[4 6 12 16 18 23 27 32].*NScanPerBlock+Base
 PseuAudi1a =[1 8 10 15 19 21 24 28].*NScanPerBlock+Base
%-------------------------------------------
conditions(1) = struct( ...
 'names',   {{'Vis1','Audi1','PseuVis1','PseuAudi1'}}, ...
 'onsets',{{Vis1,Audi1,PseuVis1,PseuAudi1}}, ...   
 'types',    {{'epochs','epochs','epochs','epochs'}}, ...  
 'bf_ep',   [1 1 1 1], ...                                   
 'volterra',  0, ...
 'variable_dur',0);
%-------------------------------------------
bf_ep(1) = struct( ...
  'ep_type',4, ...
  'length',NScanPerBlock, ...
  'conv',  1, ...  
  'deriv', 0);
%-------------------------------------------
conditions(4) = struct( ...
 'names',   {{'Vis1a','Audi1a','PseuVis1a','PseuAudi1a'}}, ...
 'onsets',{{Vis1a,Audi1a,PseuVis1a,PseuAudi1a}}, ...   
 'types',    {{'epochs','epochs','epochs','epochs'}}, ...  
 'bf_ep',   [1 1 1 1], ...                                   
 'volterra',  0, ...
 'variable_dur',0);
%-------------------------------------------
bf_ep(1) = struct( ...
  'ep_type',4, ...
  'length',NScanPerBlock, ...
  'conv',  1, ...  
  'deriv', 0);

%-------------------------------------------
Vis2=[3 7 9 13 19 21 27 29].*NScanPerBlock+Base
Audi2 =[1 5 11 15 17 23 25 31].*NScanPerBlock+Base
PseuVis2=[4 6 12 14 18 24 28 30].*NScanPerBlock+Base
PseuAudi2 =[2 8 10 16 20 22 26 32].*NScanPerBlock+Base
% alt:
Vis2a=[1 7 10 14 20 23 27 32].*NScanPerBlock+Base
Audi2a =[3 5 12 15 18 21 26 31].*NScanPerBlock+Base
PseuVis2a=[4 6 9 13 17 24 28 30].*NScanPerBlock+Base
PseuAudi2a =[2 8 11 16 19 22 25 29].*NScanPerBlock+Base
%-------------------------------------------
conditions(2) = struct( ...
 'names',   {{'Vis2','Audi2','PseuVis2','PseuAudi2'}}, ...
 'onsets',{{Vis2,Audi2,PseuVis2,PseuAudi2}}, ...   
 'types',    {{'epochs','epochs','epochs','epochs'}}, ...  
 'bf_ep',   [1 1 1 1], ...                                   
 'volterra',  0, ...
 'variable_dur',0);
%-------------------------------------------
bf_ep(1) = struct( ...
  'ep_type',4, ...
  'length',NScanPerBlock, ...
  'conv',  1, ...  
  'deriv', 0);
%-------------------------------------------
conditions(5) = struct( ...
 'names',   {{'Vis2a','Audi2a','PseuVis2a','PseuAudi2a'}}, ...
 'onsets',{{Vis2a,Audi2a,PseuVis2a,PseuAudi2a}}, ...   
 'types',    {{'epochs','epochs','epochs','epochs'}}, ...  
 'bf_ep',   [1 1 1 1], ...                                   
 'volterra',  0, ...
 'variable_dur',0);
%-------------------------------------------
bf_ep(1) = struct( ...
  'ep_type',4, ...
  'length',NScanPerBlock, ...
  'conv',  1, ...  
  'deriv', 0);

%-------------------------------------------
%-------------------------------------------
%-------------------------------------------
Vis3=[2 6 12 16 20 22 26 32].*NScanPerBlock+Base
Audi3 =[4 8 10 14 18 24 28 30].*NScanPerBlock+Base
PseuVis3=[3 5 11 13 19 21 27 29].*NScanPerBlock+Base
PseuAudi3 =[1 7 9 15 17 23 25 31].*NScanPerBlock+Base
% alt:
Vis3a=[1 4 8 10 13 20 22 25].*NScanPerBlock+Base
Audi3a =[2 6 12 14 18 24 28 30].*NScanPerBlock+Base
PseuVis3a=[5 7 16 17 19 26 29 31].*NScanPerBlock+Base
PseuAudi3a =[3 9 11 15 21 23 27 32].*NScanPerBlock+Base
%-------------------------------------------
conditions(3) = struct( ...
 'names',   {{'Vis3','Audi3','PseuVis3','PseuAudi3'}}, ...
 'onsets',{{Vis3,Audi3,PseuVis3,PseuAudi3}}, ...   
 'types',    {{'epochs','epochs','epochs','epochs'}}, ...  
 'bf_ep',   [1 1 1 1], ...                                   
 'volterra',  0, ...
 'variable_dur',0);
%-------------------------------------------
bf_ep(1) = struct( ...
  'ep_type',4, ...
  'length',NScanPerBlock, ...
  'conv',  1, ...  
  'deriv', 0);
%-------------------------------------------
conditions(6) = struct( ...
 'names',   {{'Vis3a','Audi3a','PseuVis3a','PseuAudi3a'}}, ...
 'onsets',{{Vis3a,Audi3a,PseuVis3a,PseuAudi3a}}, ...   
 'types',    {{'epochs','epochs','epochs','epochs'}}, ...  
 'bf_ep',   [1 1 1 1], ...                                   
 'volterra',  0, ...
 'variable_dur',0);
%-------------------------------------------
bf_ep(1) = struct( ...
  'ep_type',4, ...
  'length',NScanPerBlock, ...
  'conv',  1, ...  
  'deriv', 0);

%-------------------------------------------
% Zahl der Regressoren von 6 auf 9 erhoeht
% 15.4.02
% auf 12 erhoeht (4 Vpn) 23.5.02
%-------------------------------------------

regressors(1) = struct( ...
'names', {{'x1','y1','z1','Pitch1','Roll1','Yaw1'}}, ...
'values',RealignMat1);
regressors(2) = struct( ...
'names', {{'x2','y2','z2','Pitch2','Roll2','Yaw2'}}, ...
'values',RealignMat2);
regressors(3) = struct( ...
'names', {{'x3','y3','z3','Pitch3','Roll3','Yaw3'}}, ...
'values',RealignMat3);
regressors(7) = struct( ...
'names', {{'x7','y7','z7','Pitch7','Roll7','Yaw7'}}, ...
'values',RealignMat10);
regressors(8) = struct( ...
'names', {{'x8','y8','z8','Pitch8','Roll8','Yaw8'}}, ...
'values',RealignMat8);
regressors(9) = struct( ...
'names', {{'x9','y9','z9','Pitch9','Roll9','Yaw9'}}, ...
'values',RealignMat9);
regressors(10) = struct( ...
'names', {{'x10','y10','z10','Pitch10','Roll10','Yaw10'}}, ...
'values',RealignMat10);
regressors(11) = struct( ...
'names', {{'x11','y11','z11','Pitch11','Roll11','Yaw11'}}, ...
'values',RealignMat11);
regressors(12) = struct( ...
'names', {{'x12','y12','z12','Pitch12','Roll12','Yaw12'}}, ...
'values',RealignMat12);
regressors(13) = struct( ...
'names', {{'x13','y13','z13','Pitch13','Roll13','Yaw13'}}, ...
'values',RealignMat13);
regressors(14) = struct( ...
'names', {{'x14','y14','z14','Pitch14','Roll14','Yaw14'}}, ...
'values',RealignMat14);
regressors(15) = struct( ...
'names', {{'x15','y15','z15','Pitch15','Roll15','Yaw15'}}, ...
'values',RealignMat15);

%-------------------------------------------
%-------------11111, 222222 & 333333 = All--
%-------------------------------------------
Vec=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
%-------------------------------------------
Vis1=1;
PseuVis1=-1;
Vis2=1;
PseuVis2=-1;
Vis3=1;
PseuVis3=-1;
CVisBTPseuVisAll=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisLTPseuVisAll=-CVisBTPseuVisAll;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 

Audi1=1;
PseuAudi1=-1;
Audi2=1;
PseuAudi2=-1;
Audi3=1;
PseuAudi3=-1;
CAudiBTPseuAudiAll=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CAudiLTPseuAudiAll=-CAudiBTPseuAudiAll;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis1=1;
PseuVis1=-1;
Vis2=1;
PseuVis2=-1;
Vis3=1;
PseuVis3=-1;
Audi1=1;
PseuAudi1=-1;
Audi2=1;
PseuAudi2=-1;
Audi3=1;
PseuAudi3=-1;
CVisAudiBTPseuVisAudiAll=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisAudiLTPseuVisAudiAll=-CVisAudiBTPseuVisAudiAll;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis1=1;
PseuVis1=-1;
Vis2=1;
PseuVis2=-1;
Vis3=1;
PseuVis3=-1;
Audi1=-1;
PseuAudi1=1;
Audi2=-1;
PseuAudi2=1;
Audi3=-1;
PseuAudi3=1;
CVisBTAudiAll=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisLTAudiAll=-CVisBTAudiAll;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis1=0;
PseuVis1=1;
Vis2=0;
PseuVis2=1;
Vis3=0;
PseuVis3=1;
Audi1=0;
PseuAudi1=-1;
Audi2=0;
PseuAudi2=-1;
Audi3=0;
PseuAudi3=-1;
CPseuVisBTPseuAudiAll=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
%--------------111111---------------------
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis1=1;
PseuVis1=-1;
CVisBTPseuVis1=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisLTPseuVis1=-CVisBTPseuVis1;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Audi1=1;
PseuAudi1=-1;
CAudiBTPseuAudi1=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CAudiLTPseuAudi1=-CAudiBTPseuAudi1;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis1=1;
PseuVis1=-1;
Audi1=1;
PseuAudi1=-1;
CVisAudiBTPseuVisAudi1=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisAudiLTPseuVisAudi1=-CVisAudiBTPseuVisAudi1;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis1=1;
PseuVis1=-1;
Audi1=-1;
PseuAudi1=1;
CVisBTAudi1=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisLTAudi1=-CVisBTAudi1;
%-------------------------------------------
%--------------22222222---------------------
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis2=1;
PseuVis2=-1;
CVisBTPseuVis2=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisLTPseuVis2=-CVisBTPseuVis2;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Audi2=1;
PseuAudi2=-1;
CAudiBTPseuAudi2=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CAudiLTPseuAudi2=-CAudiBTPseuAudi2;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis2=1;
PseuVis2=-1;
Audi2=1;
PseuAudi2=-1;
CVisAudiBTPseuVisAudi2=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisAudiLTPseuVisAudi2=-CVisAudiBTPseuVisAudi2;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis2=1;
PseuVis2=-1;
Audi2=-1;
PseuAudi2=1;
CVisBTAudi2=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisLTAudi2=-CVisBTAudi2;
%-------------------------------------------
%--------------33333333---------------------
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis3=1;
PseuVis3=-1;
CVisBTPseuVis3=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisLTPseuVis3=-CVisBTPseuVis3;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Audi3=1;
PseuAudi3=-1;
CAudiBTPseuAudi3=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CAudiLTPseuAudi3=-CAudiBTPseuAudi3;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis3=1;
PseuVis3=-1;
Audi3=1;
PseuAudi3=-1;
CVisAudiBTPseuVisAudi3=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisAudiLTPseuVisAudi3=-CVisAudiBTPseuVisAudi3;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis3=1;
PseuVis3=-1;
Audi3=-1;
PseuAudi3=1;
CVisBTAudi3=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisLTAudi3=-CVisBTAudi3;
%-------------------------------------------
%----------------Linear------------------
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis1=-1;
PseuVis1=1;
Vis3=1;
PseuVis3=-1;
CVisBTPseuVisLin=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
CVisLTPseuVisLin=-CVisBTPseuVisLin;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Audi1=-1;
PseuAudi1=1;
Audi3=1;
PseuAudi3=-1;
CAudiBTPseuAudiLin=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CAudiLTPseuAudiLin=-CAudiBTPseuAudiLin;
%-------------------------------------------
Vis1=0; Audi1=0; PseuVis1=0; PseuAudi1=0; Vis2=0; Audi2=0; PseuVis2=0; PseuAudi2=0; Vis3=0; Audi3=0; PseuVis3=0; PseuAudi3=0; 
Vis1=-1;
PseuVis1=1;
Vis3=1;
PseuVis3=-1;
Audi1=-1;
PseuAudi1=1;
Audi3=1;
PseuAudi3=-1;
CVisAudiBTPseuVisAudiLin=[Vis1 Audi1 PseuVis1 PseuAudi1 0 0 0 0 0 0 Vis2 Audi2 PseuVis2 PseuAudi2 0 0 0 0 0 0 Vis3 Audi3 PseuVis3 PseuAudi3 0 0 0 0 0 0]
%-------------------------------------------
CVisAudiLTPseuVisAudiLin=-CVisAudiBTPseuVisAudiLin;

NZeros=zeros(1,12);
CVisBTPseuVisAll=[CVisBTPseuVisAll,CVisBTPseuVisAll, CVisBTPseuVisAll, CVisBTPseuVisAll, NZeros]
CVisLTPseuVisAll=[CVisLTPseuVisAll, CVisLTPseuVisAll, CVisLTPseuVisAll, CVisLTPseuVisAll, NZeros]
CAudiBTPseuAudiAll=[CAudiBTPseuAudiAll, CAudiBTPseuAudiAll, CAudiBTPseuAudiAll, CAudiBTPseuAudiAll, NZeros]
CAudiLTPseuAudiAll=[CAudiLTPseuAudiAll, CAudiLTPseuAudiAll, CAudiLTPseuAudiAll, CAudiLTPseuAudiAll,NZeros]
CVisAudiBTPseuVisAudiAll=[CVisAudiBTPseuVisAudiAll, CVisAudiBTPseuVisAudiAll, CVisAudiBTPseuVisAudiAll, CVisAudiBTPseuVisAudiAll, NZeros]
CVisAudiLTPseuVisAudiAll=[CVisAudiLTPseuVisAudiAll, CVisAudiLTPseuVisAudiAll, CVisAudiLTPseuVisAudiAll, CVisAudiLTPseuVisAudiAll, NZeros]
CVisBTAudiAll=[CVisBTAudiAll, CVisBTAudiAll, CVisBTAudiAll, CVisBTAudiAll, NZeros]
CVisLTAudiAll=[CVisLTAudiAll, CVisLTAudiAll, CVisLTAudiAll, CVisLTAudiAll,  NZeros]
CPseuVisBTPseuAudiAll=[CPseuVisBTPseuAudiAll, CPseuVisBTPseuAudiAll, CPseuVisBTPseuAudiAll, CPseuVisBTPseuAudiAll,  NZeros] 
CVisBTPseuVis1=[CVisBTPseuVis1, CVisBTPseuVis1, CVisBTPseuVis1, CVisBTPseuVis1,  NZeros]
CVisLTPseuVis1=[CVisLTPseuVis1, CVisLTPseuVis1, CVisLTPseuVis1, CVisLTPseuVis1,  NZeros]
CAudiBTPseuAudi1=[CAudiBTPseuAudi1, CAudiBTPseuAudi1, CAudiBTPseuAudi1, CAudiBTPseuAudi1,  NZeros] 
CAudiLTPseuAudi1=[CAudiLTPseuAudi1, CAudiLTPseuAudi1, CAudiLTPseuAudi1, CAudiLTPseuAudi1,  NZeros]
CVisAudiBTPseuVisAudi1=[CVisAudiBTPseuVisAudi1, CVisAudiBTPseuVisAudi1, CVisAudiBTPseuVisAudi1, CVisAudiBTPseuVisAudi1,  NZeros]
CVisAudiLTPseuVisAudi1=[CVisAudiLTPseuVisAudi1, CVisAudiLTPseuVisAudi1, CVisAudiLTPseuVisAudi1, CVisAudiLTPseuVisAudi1,  NZeros]
CVisBTAudi1=[CVisBTAudi1, CVisBTAudi1, CVisBTAudi1, CVisBTAudi1, NZeros]
CVisLTAudi1=[CVisLTAudi1, CVisLTAudi1,CVisLTAudi1, CVisLTAudi1,  NZeros]
CVisBTPseuVis2=[CVisBTPseuVis2, CVisBTPseuVis2, CVisBTPseuVis2,  CVisBTPseuVis2,  NZeros]
CVisLTPseuVis2=[CVisLTPseuVis2, CVisLTPseuVis2, CVisLTPseuVis2, CVisLTPseuVis2, NZeros]
CAudiBTPseuAudi2=[CAudiBTPseuAudi2, CAudiBTPseuAudi2, CAudiBTPseuAudi2, CAudiBTPseuAudi2,  NZeros]
CAudiLTPseuAudi2=[CAudiLTPseuAudi2, CAudiLTPseuAudi2, CAudiLTPseuAudi2, CAudiLTPseuAudi2,  NZeros]
CVisAudiBTPseuVisAudi2=[CVisAudiBTPseuVisAudi2, CVisAudiBTPseuVisAudi2, CVisAudiBTPseuVisAudi2, CVisAudiBTPseuVisAudi2, NZeros]
CVisAudiLTPseuVisAudi2=[CVisAudiLTPseuVisAudi2, CVisAudiLTPseuVisAudi2, CVisAudiLTPseuVisAudi2, CVisAudiLTPseuVisAudi2, NZeros]
CVisBTAudi2=[CVisBTAudi2, CVisBTAudi2, CVisBTAudi2, CVisBTAudi2, NZeros]
CVisLTAudi2=[CVisLTAudi2, CVisLTAudi2, CVisLTAudi2, CVisLTAudi2,  NZeros]
CVisBTPseuVis3=[CVisBTPseuVis3, CVisBTPseuVis3, CVisBTPseuVis3, CVisBTPseuVis3, NZeros]
CVisLTPseuVis3=[CVisLTPseuVis3, CVisLTPseuVis3, CVisLTPseuVis3, CVisLTPseuVis3, NZeros]
CAudiBTPseuAudi3=[CAudiBTPseuAudi3, CAudiBTPseuAudi3, CAudiBTPseuAudi3, CAudiBTPseuAudi3, NZeros]
CAudiLTPseuAudi3=[CAudiLTPseuAudi3, CAudiLTPseuAudi3, CAudiLTPseuAudi3, CAudiLTPseuAudi3, NZeros]
CVisAudiBTPseuVisAudi3=[CVisAudiBTPseuVisAudi3, CVisAudiBTPseuVisAudi3, CVisAudiBTPseuVisAudi3, CVisAudiBTPseuVisAudi3, NZeros]
CVisAudiLTPseuVisAudi3=[CVisAudiLTPseuVisAudi3, CVisAudiLTPseuVisAudi3, CVisAudiLTPseuVisAudi3, CVisAudiLTPseuVisAudi3, NZeros]
CVisBTAudi3=[CVisBTAudi3, CVisBTAudi3, CVisBTAudi3, CVisBTAudi3, NZeros]
CVisLTAudi3=[CVisLTAudi3, CVisLTAudi3, CVisLTAudi3, CVisLTAudi3, NZeros]
CVisBTPseuVisLin=[CVisBTPseuVisLin, CVisBTPseuVisLin, CVisBTPseuVisLin, CVisBTPseuVisLin, NZeros]
CVisLTPseuVisLin=[CVisLTPseuVisLin, CVisLTPseuVisLin, CVisLTPseuVisLin, CVisLTPseuVisLin, NZeros]
CAudiBTPseuAudiLin=[CAudiBTPseuAudiLin, CAudiBTPseuAudiLin, CAudiBTPseuAudiLin, CAudiBTPseuAudiLin, NZeros]
CAudiLTPseuAudiLin=[CAudiLTPseuAudiLin, CAudiLTPseuAudiLin, CAudiLTPseuAudiLin, CAudiLTPseuAudiLin, NZeros]
CVisAudiBTPseuVisAudiLin=[CVisAudiBTPseuVisAudiLin, CVisAudiBTPseuVisAudiLin, CVisAudiBTPseuVisAudiLin, CVisAudiBTPseuVisAudiLin, NZeros]
CVisAudiLTPseuVisAudiLin=[CVisAudiLTPseuVisAudiLin, CVisAudiLTPseuVisAudiLin, CVisAudiLTPseuVisAudiLin, CVisAudiLTPseuVisAudiLin, NZeros]

contrasts(1) = struct( ...
'names',  {{...
'CVisBTPseuVisAll','CVisLTPseuVisAll','CAudiBTPseuAudiAll','CAudiLTPseuAudiAll', ...
'CVisAudiBTPseuVisAudiAll','CVisAudiLTPseuVisAudiAll','CVisBTAudiAll','CVisLTAudiAll', ...
'CPseuVisBTPseuAudiAll','CVisBTPseuVis1','CVisLTPseuVis1','CAudiBTPseuAudi1','CAudiLTPseuAudi1', ...
'CVisAudiBTPseuVisAudi1','CVisAudiLTPseuVisAudi1','CVisBTAudi1','CVisLTAudi1', ...
'CVisBTPseuVis2','CVisLTPseuVis2','CAudiBTPseuAudi2','CAudiLTPseuAudi2', ...
'CVisAudiBTPseuVisAudi2','CVisAudiLTPseuVisAudi2','CVisBTAudi2','CVisLTAudi2', ...
'CVisBTPseuVis3','CVisLTPseuVis3','CAudiBTPseuAudi3','CAudiLTPseuAudi3', ...
'CVisAudiBTPseuVisAudi3','CVisAudiLTPseuVisAudi3','CVisBTAudi3','CVisLTAudi3', ...
'CVisBTPseuVisLin','CVisLTPseuVisLin','CAudiBTPseuAudiLin','CAudiLTPseuAudiLin', ....
'CVisAudiBTPseuVisAudiLin','CVisAudiLTPseuVisAudiLin', ...
}}, ...
'types',   {{ ...
'T','T','T','T','T','T','T','T',...
'T','T','T','T','T','T','T','T',...
'T','T','T','T','T','T','T','T',...
'T','T','T','T','T','T','T','T',...
'T','T','T','T','T','T', 'T',...
}}, ...
'values',  {{...
CVisBTPseuVisAll,CVisLTPseuVisAll,CAudiBTPseuAudiAll,CAudiLTPseuAudiAll, ...
CVisAudiBTPseuVisAudiAll,CVisAudiLTPseuVisAudiAll,CVisBTAudiAll,CVisLTAudiAll, ...
CPseuVisBTPseuAudiAll, CVisBTPseuVis1,CVisLTPseuVis1,CAudiBTPseuAudi1,CAudiLTPseuAudi1, ...
CVisAudiBTPseuVisAudi1,CVisAudiLTPseuVisAudi1,CVisBTAudi1,CVisLTAudi1, ...
CVisBTPseuVis2,CVisLTPseuVis2,CAudiBTPseuAudi2,CAudiLTPseuAudi2, ...
CVisAudiBTPseuVisAudi2,CVisAudiLTPseuVisAudi2,CVisBTAudi2,CVisLTAudi2, ...
CVisBTPseuVis3,CVisLTPseuVis3,CAudiBTPseuAudi3,CAudiLTPseuAudi3, ...
CVisAudiBTPseuVisAudi3,CVisAudiLTPseuVisAudi3,CVisBTAudi3,CVisLTAudi3,...
CVisBTPseuVisLin,CVisLTPseuVisLin,CAudiBTPseuAudiLin,CAudiLTPseuAudiLin, ....
CVisAudiBTPseuVisAudiLin,CVisAudiLTPseuVisAudiLin, ...
}} ...
);

