clear


load AIS_2003_monthly_dhdt.mat
load index_land_ice.mat
in=index_land_ice;
A=AIS_2003_monthly_dhdt;

tid(1)=2003
mass(1)=0
k=1

for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2003_monthly_dhdt


load AIS_2004_monthly_dhdt.mat
A=AIS_2004_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2004_monthly_dhdt


load AIS_2005_monthly_dhdt.mat
A=AIS_2005_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2005_monthly_dhdt


load AIS_2006_monthly_dhdt.mat
A=AIS_2006_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2006_monthly_dhdt


load AIS_2007_monthly_dhdt.mat
A=AIS_2007_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2007_monthly_dhdt

load AIS_2008_monthly_dhdt.mat
A=AIS_2008_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2008_monthly_dhdt

load AIS_2009_monthly_dhdt.mat
A=AIS_2009_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2009_monthly_dhdt

load AIS_2010_monthly_dhdt.mat
A=AIS_2010_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2010_monthly_dhdt

load AIS_2011_monthly_dhdt.mat
A=AIS_2011_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2011_monthly_dhdt

load AIS_2012_monthly_dhdt.mat
A=AIS_2012_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2012_monthly_dhdt


load AIS_2013_monthly_dhdt.mat
A=AIS_2013_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2013_monthly_dhdt

load AIS_2014_monthly_dhdt.mat
A=AIS_2014_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2014_monthly_dhdt

load AIS_2015_monthly_dhdt.mat
A=AIS_2015_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2015_monthly_dhdt

load AIS_2016_monthly_dhdt.mat
A=AIS_2016_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2016_monthly_dhdt

load AIS_2017_monthly_dhdt.mat
A=AIS_2017_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2017_monthly_dhdt

load AIS_2018_monthly_dhdt.mat
A=AIS_2018_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2018_monthly_dhdt

load AIS_2019_monthly_dhdt.mat
A=AIS_2019_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2019_monthly_dhdt


load AIS_2020_monthly_dhdt.mat
A=AIS_2020_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2020_monthly_dhdt

load AIS_2021_monthly_dhdt.mat
A=AIS_2021_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2021_monthly_dhdt

load AIS_2022_monthly_dhdt.mat
A=AIS_2022_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2022_monthly_dhdt

load AIS_2023_monthly_dhdt.mat
A=AIS_2023_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2023_monthly_dhdt

load AIS_2024_monthly_dhdt.mat
A=AIS_2024_monthly_dhdt;
for i=3:14
k=k+1;
tid(k)=tid(k-1)+1/12;
dm=0.001*sum(A(in,i));
mass(k)=mass(k-1)+dm;
end
clear AIS_2024_monthly_dhdt

%%
plot(tid,mass,'.-')