
x=netcdf('Water_cpc_1980_2003.nc');
xx=x{'water'}(:);
%
file2 = 'water_cpc_1980.dat';
for ii=1:24,
file2(11:14) = num2str(1979+ii);
%
   fid = fopen(file2,'w');
%
    for kk=1:12;
     fprintf(fid, '%d \n', kk);
     for i=1:360,
      tmp(1,:) = xx((ii-1)*12+kk,:,i);
       fprintf(fid, '%7.2f ', tmp); fprintf(fid, '\n');
      end;
%
(ii-1)*12+kk
    end;
fid = fclose(fid);
end
close(x);

