% Example 1
clear all % clears all variables in your workspace

% ***** THIS SECTION IS WHAT YOU NEED TO EDIT FIRST! **********************************
% change the data location and file name to match your data
data_location = 'C:\Users\mm3196\dos\PW3\'; 
data_file_name = 'ESACCI-SEAICE-L4-SICONC-AMSR_25.0kmEASE2-NH-20160801-fv2.1.nc';           
% *************************************************************************************


% this line joins together the data location and filename to make a path
% for the data
data_path = strcat(data_location,data_file_name);

% This line uses the function getnet to read in the netcdf (.nc) files
% into matlab
sea_ice = getnet(data_path);
% sea_ice is our structure of data which contains all the data from the
% data file

% Here we extract the data we want from the structure called sea_ice
ice_concentration = sea_ice.Data.ice_conc;
x = sea_ice.Data.xc;
y = sea_ice.Data.yc;

% Plotting
figure()
pcolor(x,y,ice_concentration'); shading flat; % the shading flat here gets rid of the black grid lines
title('Put title here')
c = colorbar();
c.Label.String = 'put colorbar label here';
xlabel('x label here');
ylabel('y label here');