I want to draw current patches by m_map, WHY MY CODE ISN'T NOTICED ABOUT BUGS BUT IT DOESN'T WORK? (it was showed of running, and maintain without result during 5 hours)

2 views (last 30 days)
This is my code:
folder = 'E:\...'; cd('E:\...');
fn0 = 'TOTL_ALLM_2014_'; % files name
sf= 'trajectory'; % name of the folder
for month = 9:12
if month == 9; day = [15:30];
elseif month == 10; day = [1:31];
elseif month == 11; day = [1:30];
elseif month == 12; day = [1:11];
end
for day = day(1):day(end)
for hour = 0:23
figure;
m_proj('Equidistant Cylindrical','long',[119 123],'lat',[21 26]);
m_etopo2('contourf',[-7000:1000:0 0:1000:2000],'edgecolor','none');
m_grid('linest','none','tickdir','out','box','fancy','fontsize',12);
caxis([-7000 2000]);
filename0=[fn0 sprintf('%02d', month),'_', sprintf('%02d', day),'_',sprintf('%02d', hour), '00'];
filename=[fn0 sprintf('%02d', month),'_', sprintf('%02d', day),'_',sprintf('%02d', hour), '00.tuv'];
t = load(filename);
[x,y] = m_ll2xy(t(:,1),t(:,2),'clip','patch');
m_range_ring(x,y,t(:,11),'color','r','linewidth',2)
title(['Day 2014' num2str(month,'%02d') num2str(day,'%02d') ' Hour ' num2str(hour,'%02d')]);
set(gca,'fontsize',12);
colormap([ m_colmap('blues',70); m_colmap('greens',20)]);
c = colorbar;
c.Label.String = 'Meters';
set(gcf,'color','w');
set(gcf,'Units','centimeters','position',[3 1 16.0 16.0],'PaperPositionMode','auto');
if (~isequal(exist([folder '/' sf], 'dir'),7)); mkdir([folder '/' sf]); end
print('-dpng',[folder '/' sf '/' filename0 '.png'], '-r100');
close all; fclose all;
clear aa;
end
end
end
.
  1 Comment
KSSV
KSSV on 26 Apr 2019
raw current patches by m_map can you elaborate on this?
We cannot help unless we have data in hand.....and as you said it takes five hours...how you expect us to wait for that long?

Sign in to comment.

Answers (0)

Community Treasure Hunt

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

Start Hunting!