Skip to content
Permalink
Browse files
Overlay the models to a map and display ozone level
  • Loading branch information
olteanua committed Aug 10, 2020
1 parent da31773 commit 326c9ec7c29247fdef020bc7d760532bc1ce0908
Showing 1 changed file with 25 additions and 0 deletions.
@@ -49,4 +49,29 @@ elseif userInput == 8
pause(1)
end
clc;
%%Assign data from the file
lon = ncread(file_nc,'lon'); %%data for longtitude
lat = ncread(file_nc,'lat'); %%data for latitude
hour = ncread(file_nc,'hour'); %%data for hours
modeldata = ncread(file_nc,model); %%takes user input model
[X,Y] = meshgrid(lon,lat); %%meshgrid with data
clc;
disp('Map is processed')
%%Loops through the hours
for i = 1 : length(hour)
clf; %%clear figure
map = pcolor(X,Y,modeldata(:,:,i)'); %%assign the data
map.EdgeAlpha = 0;
map.FaceAlpha = 0.8;
load coast %%load the coastlines
cities = shaperead('worldcities', 'UseGeoCoords', true);%%load the cities
legendmap = colorbar; %%colorbar for the values of ozone
legendmap.Label.String = 'Level of Ozone';
geoshow(cities, 'Marker', '+', 'Color', 'red') %%cities on the map
hold on;
plot(long,lat,'k')
title(sprintf('Visualise the Ensemble Data on Europe'))
pause(1)
end


0 comments on commit 326c9ec

Please sign in to comment.