Skip to content

Instantly share code, notes, and snippets.

@shurru
Created September 1, 2015 21:10
Show Gist options
  • Save shurru/bb34c6a3617261824207 to your computer and use it in GitHub Desktop.
Save shurru/bb34c6a3617261824207 to your computer and use it in GitHub Desktop.
Matlab code
s = char(65:80) ;
for subj= 1:9
sheet= strcat('BL0',num2str(subj));
for ns = 1:length(s)
range = [s(ns),'2',':',s(ns),'20000'];
dat= xlsread('GSR_buttsmoothmed.xlsx',sheet, range);
datarray=[];
datarray= [datarray, dat];
M=max(datarray);
N=min(datarray);
avg= mean(datarray);
normalizer= (dat-N)/(M-N);
xlswrite('GSR_dat_min_normalized.xlsx',normalizer,sheet,range);
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment