필터 지우기
필터 지우기

Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

Regarding Plotting

조회 수: 1 (최근 30일)
Uday
Uday 2011년 8월 14일
마감: MATLAB Answer Bot 2021년 8월 20일
I have 9 years pollution data and I would like to plot monthly maps. I have code those can process all data, but I do not know how to save each and every image (jpg,pdf). It will be nice if somebody can tell me how to fix this problem.

답변 (2개)

Jan
Jan 2011년 8월 14일
Look in the documentation:
help saveas
help print
help imwrite
  댓글 수: 2
Uday
Uday 2011년 8월 14일
do I need to write loop for saving all images ?
my codes are
for i=1:length(dir_list)
if strfind(dir_list(i).name,'2003')==19
data=dlmread(strcat(path,dir_list(i).name),'',55);
end
latitude=data(:,7);
lon_t=data(:,8);
longitude=rem((lon_t+180),360)-180
co=data(:,38);
figure(1)
load coast
h1=axesm('MapProjection','eqdcylin',... % There are many different map projections available. I don't claim this is the best.
'Grid','off',... % The default is to have a grid over the whole map, which I usually get rid of.
'MapLatLimit',[15-d_deg/2 45+d_deg/2],... %This defines the latitude and longitude limits of the plot. These include the whole globe
'MapLonLimit',[(-105-d_deg/2) (-75+d_deg/2)],...
'MeridianLabel','off',... %This turns off the meridian labels altogether
'Frame','on'); %This turns off the frame around the whole plot.
plotm(lat,long,'k')
hold on
tightmap on
colormap(jet);
grid on
h=surfacem(latgrid,longrid,grid_ch4);
colorbar
% legend('show')
xlabel('Longitude');
ylabel('Latitude');
title('SCIAMACHY XCH4 Jan 2003');
saveas(h1,'jpg');
Uday
Uday 2011년 8월 14일
I wanted to save every month image separately and I have give them different name too for e.g Jan 2003 , March 2004 ..

Walter Roberson
Walter Roberson 2011년 8월 14일

이 질문은 마감되었습니다.

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by