clc;clear all;close all;
addpath('/data3/yiwen/matlab_toolbox/tight_subplot/')

pathi='/data3/yiwen/cesm2/JGR_ocean/Model_output/AMOC_timeseries/'
pathi2='/data3/yiwen/cesm2/JGR_ocean/OBS_array/RAPID/2018/'
%======= timeseries data =======%
load([pathi 'G_JRA55_test1_1st']);CTRL=SV_yr;
load([pathi 'KPP_ICE_linear_1st']);POP2_BG0_1st=SV_yr;
load([pathi 'KPP_R']);G_JRA_ts_1st=SV_yr;

%==== OBS data ====%
load([pathi2,'MOC_OBS_time'])
time=linspace(1958,2018,61);

set(0,'defaultfigurecolor','w')
plot(time,CTRL,'Linewidth',2.5,'LineStyle','--');hold on
plot(time,POP2_BG0_1st,'Linewidth',4);hold on
plot(time,G_JRA_ts_1st,'Linewidth',2.5,'LineStyle','--');hold on
plot([2004:1:2018],OBS_MOC_year,'Linewidth',3,'Color','k');hold on
xlabel('years');ylabel('SV')
legend('CTRL','KPP_{ICEL}','KPP_{R}','RAPID 26.5','Interpreter','tex')
set(gca,'Linewidth',3,'Fontsize',20);grid on
set(gca,'XMinorTick','on','YMinorTick','on','TickDir','out','fontweight', 'bold');ytickformat('%.2f');
xlim([1958 2018]);ylim([12 21])



