ASDR_percentup_ctrl_F12 = meanASDR.ctrl(:,2)./meanASDR.ctrl(:,1);
ASDR_percentup_ctrl_F24 = meanASDR.ctrl(:,3)./meanASDR.ctrl(:,1);
ASDR_percentup_ctrl_L48 = meanASDR.ctrl(:,4)./meanASDR.ctrl(:,1);
ASDR_percentup_cnqx_F12 = meanASDR.cnqx(:,2)./meanASDR.cnqx(:,1);
ASDR_percentup_cnqx_F24 = meanASDR.cnqx(:,3)./meanASDR.cnqx(:,1);
ASDR_percentup_cnqx_L48 = meanASDR.cnqx(:,4)./meanASDR.cnqx(:,1);
set(0,'DefaultAxesColorOrder',[1 0 0; 0.8 0.4 0; 0.2 0.8 0.2; 0 0.6 0.8; 0.2 0 0.9; 0.5 0 0.5; 1 0.2 0.5; 0.5 0.5 0.5]);

close all;
subplot(3,3,1); hold off;

for i = 1:8
    plot(ASDR_percentup_ctrl_F12(i),ASDR_percentup_cnqx_F12(i),'.','MarkerSize',15);
    hold all;
end
plot([0 2.5],[0 2.5],'--','Color',[0.7 0.7 0.7]); axis([0 2.5 0 2.5]); axis square;
xlimit=xlim;
set(gca,'XTick',[0:.5:xlimit(2)]);
set(gca,'XTickLabel',[0:.5:xlimit(2)]*100);
set(gca,'YTick',[0:.5:xlimit(2)]);
set(gca,'YTickLabel',[0:.5:xlimit(2)]*100);


subplot(3,3,2); hold off;
for i = 1:8
    plot(ASDR_percentup_ctrl_F24(i),ASDR_percentup_cnqx_F24(i),'.','MarkerSize',15);
    hold all;
end
plot([0 2.5],[0 2.5],'--','Color',[0.7 0.7 0.7]); axis([0 2.5 0 2.5]); axis square;
set(gca,'XTick',[0:.5:xlimit(2)]);
set(gca,'XTickLabel',[0:.5:xlimit(2)]*100);
set(gca,'YTick',[0:.5:xlimit(2)]);
set(gca,'YTickLabel',[0:.5:xlimit(2)]*100);

subplot(3,3,3); hold off;
for i = 1:8
    plot(ASDR_percentup_ctrl_L48(i),ASDR_percentup_cnqx_L48(i),'.','MarkerSize',15);
    hold all;
end
plot([0 2.5],[0 2.5],'--','Color',[0.7 0.7 0.7]); axis([0 2.5 0 2.5]); axis square;
set(gca,'XTick',[0:.5:xlimit(2)]);
set(gca,'XTickLabel',[0:.5:xlimit(2)]*100);
set(gca,'YTick',[0:.5:xlimit(2)]);
set(gca,'YTickLabel',[0:.5:xlimit(2)]*100);

%% BI
BI_percentup_ctrl_F12 = BIfilt.ctrl(:,2)./BIfilt.ctrl(:,1);
BI_percentup_ctrl_F24 = BIfilt.ctrl(:,3)./BIfilt.ctrl(:,1);
BI_percentup_ctrl_L48 = BIfilt.ctrl(:,4)./BIfilt.ctrl(:,1);
BI_percentup_cnqx_F12 = BIfilt.cnqx(:,2)./BIfilt.cnqx(:,1);
BI_percentup_cnqx_F24 = BIfilt.cnqx(:,3)./BIfilt.cnqx(:,1);
BI_percentup_cnqx_L48 = BIfilt.cnqx(:,4)./BIfilt.cnqx(:,1);

subplot(3,3,4); hold off;
for i = 1:8
    plot(BI_percentup_ctrl_F12(i),BI_percentup_cnqx_F12(i),'.','MarkerSize',15);
    hold all;
   
end
plot([0 2.5],[0 2.5],'--','Color',[0.7 0.7 0.7]); axis([0 1.5 0 1.5]); axis square;
xlimit=xlim;
set(gca,'XTick',[0:.5:xlimit(2)]);
set(gca,'XTickLabel',[0:.5:xlimit(2)]*100);
set(gca,'YTick',[0:.5:xlimit(2)]);
set(gca,'YTickLabel',[0:.5:xlimit(2)]*100);

subplot(3,3,5); hold off;
for i = 1:8
    plot(BI_percentup_ctrl_F24(i),BI_percentup_cnqx_F24(i),'.','MarkerSize',15);
    hold all;
end
plot([0 2.5],[0 2.5],'--','Color',[0.7 0.7 0.7]); axis([0 1.5 0 1.5]); axis square;
set(gca,'XTick',[0:.5:xlimit(2)]);
set(gca,'XTickLabel',[0:.5:xlimit(2)]*100);
set(gca,'YTick',[0:.5:xlimit(2)]);
set(gca,'YTickLabel',[0:.5:xlimit(2)]*100);

subplot(3,3,6); hold off;
for i = 1:8
    plot(BI_percentup_ctrl_L48(i),BI_percentup_cnqx_L48(i),'.','MarkerSize',15);
    hold all;
end
plot([0 2.5],[0 2.5],'--','Color',[0.7 0.7 0.7]); axis([0 1.5 0 1.5]); axis square;
set(gca,'XTick',[0:.5:xlimit(2)]);
set(gca,'XTickLabel',[0:.5:xlimit(2)]*100);
set(gca,'YTick',[0:.5:xlimit(2)]);
set(gca,'YTickLabel',[0:.5:xlimit(2)]*100);



%% median
med_percentup_ctrl_F12 = medianASDR.ctrl(:,2)./medianASDR.ctrl(:,1);
med_percentup_ctrl_F24 = medianASDR.ctrl(:,3)./medianASDR.ctrl(:,1);
med_percentup_ctrl_L48 = medianASDR.ctrl(:,4)./medianASDR.ctrl(:,1);
med_percentup_cnqx_F12 = medianASDR.cnqx(:,2)./medianASDR.cnqx(:,1);
med_percentup_cnqx_F24 = medianASDR.cnqx(:,3)./medianASDR.cnqx(:,1);
med_percentup_cnqx_L48 = medianASDR.cnqx(:,4)./medianASDR.cnqx(:,1);

subplot(3,3,7); hold off;
for i = 1:8
    plot(med_percentup_ctrl_F12(i),med_percentup_cnqx_F12(i),'.','MarkerSize',15);
    hold all;
end
plot([0 4.1],[0 4.1],'--','Color',[0.7 0.7 0.7]); axis([0 4.1 0 4.1]); axis square;
xlimit=xlim;
set(gca,'XTick',[0:1:xlimit(2)]);
set(gca,'XTickLabel',[0:1:xlimit(2)]*100);
set(gca,'YTick',[0:1:xlimit(2)]);
set(gca,'YTickLabel',[0:1:xlimit(2)]*100);


subplot(3,3,8); hold off;
for i = 1:8
    plot(med_percentup_ctrl_F24(i),med_percentup_cnqx_F24(i),'.','MarkerSize',15);
    hold all;
end
plot([0 4.1],[0 4.1],'--','Color',[0.7 0.7 0.7]); axis([0 4.1 0 4.1]); axis square;
set(gca,'XTick',[0:1:xlimit(2)]);
set(gca,'XTickLabel',[0:1:xlimit(2)]*100);
set(gca,'YTick',[0:1:xlimit(2)]);
set(gca,'YTickLabel',[0:1:xlimit(2)]*100);


subplot(3,3,9); hold off;
for i = 1:8
    plot(med_percentup_ctrl_L48(i),med_percentup_cnqx_L48(i),'.','MarkerSize',15);
    hold all;
end
plot([0 4.1],[0 4.1],'--','Color',[0.7 0.7 0.7]); axis([0 4.1 0 4.1]); axis square;
set(gca,'XTick',[0:1:xlimit(2)]);
set(gca,'XTickLabel',[0:1:xlimit(2)]*100);
set(gca,'YTick',[0:1:xlimit(2)]);
set(gca,'YTickLabel',[0:1:xlimit(2)]*100);


%%
for i = 1:9
    subplot(3,3,i)
    xlabel('% increase in control');
    ylabel('% increase in CNQX-treated');
    xlimit = xlim;
end
