
set(0, 'DefaultLineLineWidth', 2);
set(0,'defaultTextFontSize', 12);
set(0,'defaultAxesFontSize',12);
set(0,'DefaultFigureColormap',jet)
set(0,'defaultfigurecolor',[1 1 1])
set(0,'DefaultAxesTitleFontWeight', 'normal')
%%
Oxt_REM = readtable('REM.xlsx','Sheet','REM_oxyt_all');
Ach_REM = readtable('REM.xlsx','Sheet','REM_ACh_all');

%%
Oxt_REM_ALL = table2array(Oxt_REM(1:42,2:4));
thetascore_all = table2array(Oxt_REM(1:42,6:8));
%
figure;
set(gcf,'Position',[100 100 300 600])

subplot(2,1,2)
x = 1:3;
e = std(Oxt_REM_ALL)/ sqrt(length(Oxt_REM_ALL));
yyaxis left
h = errorbar(x,mean(Oxt_REM_ALL),e, 'o-','Color',[0,0.6,0]);
set(h, 'MarkerSize', 10, 'MarkerFaceColor', [0,0.6,0], ...
    'MarkerEdgeColor', [0,0.6,0]);
xlim([0.5 3.5]);

x = 1:3;
e = std(thetascore_all)/sqrt(length(thetascore_all));
yyaxis right;k = errorbar(x,mean(thetascore_all),e, 's-','Color',[0,0,0]);
set(k, 'MarkerSize', 10, 'MarkerFaceColor', [0,0,0], ...
    'MarkerEdgeColor', [0,0,0]);
box off
%
Ach_REM1 = Ach_REM;
Ach_REM1(12,:) = [];
Ach_REM_ALL = table2array(Ach_REM1(1:end,7:9));
thetascore_all = table2array(Ach_REM1(1:end,12:14));

% 
subplot(2,1,1)
x = 1:3;
e = std(Ach_REM_ALL)/ sqrt(length(Ach_REM_ALL));
yyaxis left
h = errorbar(x,mean(Ach_REM_ALL),e, 'o-','Color',[1.0, 0,0]);
set(h, 'MarkerSize', 10, 'MarkerFaceColor', [1.0,0,0], ...
    'MarkerEdgeColor', [1.0,0,0]);
xlim([0.5 3.5]);

x = 1:3;
e = std(thetascore_all)/sqrt(length(thetascore_all));
yyaxis right;k = errorbar(x,mean(thetascore_all),e, 's-','Color',[0,0,0]);
set(k, 'MarkerSize', 10, 'MarkerFaceColor', [0,0,0], ...
    'MarkerEdgeColor', [0,0,0]);
box off

xlim([0.5 3.5]);ylim([0 5]);