Working with marine environmental variables, Copernicus Marine Environment Monitoring Service and reprojections.
In the Step by Step tutorial No. 13, we give you some tips about the different sources of information and where to get it.
EARTH DAY Slide show EARTHDAY.ORG is unwavering in our commitment to end plas...
13.- Working with marine environmental variables in ModestR (Version ModestR 5.3 or higher)
1. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
Step by step tutorial:
Working with marine
environmental variables,
CMEMS and reprojections.
2. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
What do you need for this tutorial:
1. ModestR v.5.3 or higher installed
2. Internet connection
3. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
In the Step by Step tutorial No. 11, we
gave you some tips about the
different sources of information and
where to get it.
Now, we want to show you how to
access the information in a more
detailed way.
4. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
Copernicus
Marine Environment Monitoring Service
1. ¿What is Copernicus Marine Environment Monitoring Service?
R// Copernicus is the “European Programme for the establishment of an European capacity for Earth
Observation and Monitoring”. It has 3 components, being the Service component the one related to
the pre-operational, operational or in development phase products.
2. ¿What is the CMEMS for?
R// CMEMS is in an operational mode and “is designed to respond to issues emerging in the
environmental, business and scientific sectors. Using information from both satellite and in situ
observations, it provides state-of-the-art analyses and forecasts daily, which offer an unprecedented
capability to observe, understand and anticipate marine environment events”
5. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
Copernicus
Marine Environment Monitoring Service
3. ¿ How do I access CMEMS and its datasets?
R// Open access information >> http://marine.copernicus.eu/ >> Register!
6. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
Copernicus
Marine Environment Monitoring Service
3. ¿ How do I access CMEMS and its datasets?
R// Open access information >>
http://marine.copernicus.eu/ >> Register >> Online
Catalogue >> Add to cart >> Download >> Choose a
dataset >> Apply filters >> Download the dataset
Before your selection, please consider:
Domain:
Global?
Specific doman? >> Knowing the limits is highly
recomended.
Parameter.
Temporal coverage.
Spatial resolution.
Depth level.
8. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
The downloading options
depend on the size of the file.
The name of the file is pretty long.
Change it into a shorter one is highly
recomended.
9. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
Copernicus
Marine Environment Monitoring Service
3. ¿ How can I use CMEMS datasets with ModestR?
R// Exactly as you did before (Tutorial 3), but selecting the netCDF file option: single file, multiple files or
folder:
MapMaker
Layers
Manage
Environmental
variables
At this level, you can decide to
import the folder or créate one (add
type).
At the end, the idea is to have the
environmental information
organized.
10. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
¿What if the data have different
projections?
11. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
Copernicus
Marine Environment Monitoring Service
4. ¿What if the data have different projections?
R// At the moment ModestR supports data with equirectangular projection and CMEMS offers a variety of
datasets with different projections and coordinate reference systems . Before downloading the information,
please check in the “more info” appart.
12. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
Copernicus
Marine Environment Monitoring Service
4. ¿What if the data have a different projection?
If the reference system is
different than this, you’ll
need to reproject the data.
13. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
Reprojecting the data
To reproject the data, please follow the next steps.
Example for a 64 bit versions of Windows:
1. Download, run and install Cygwin: Download cygwin setup utility from https://www.cygwin.com/ . Select
the 64-bit version (Windows 64bit version required). Run the cygwin setup (e.g setup-x86_64.exe). Use
default settings for installation (typically it will install in C:cygwin64).
2. Packages: On the Select Packages installation step, search for the following packages and change the
status from Skip to install (version to be installed will appear):
• netcdf • libproj • gcc-g++ • udunits • gcc-core
3. Complete installation: Verify the correct installation of the Cygwin tool by checking the path C:cygwin64.
4. Climate Data Operators -CDO: CDO is a collection of command line operators to manipulate and analyse
Climate and NWP model Data. Supported data formats are GRIB 1/2, netCDF 3/4, SERVICE, EXTRA and
IEG. There are more than 600 operators available.
Go to https://code.mpimet.mpg.de/ >> Projects >> CDO >> Downloads.
14. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
Reprojecting the data
5. Climate Data Operators –CDO:
Download the last version available and labeled as cygwin64.
Uncompress the file, that will contain just the cdo.exe file, in the C:cygwin64bin folder (intended that you
installed Cygwin in C:cygwin64).
To make it easier working with cdo, we suggest copying the netCDF files you want to process to the folder
C:cygwin64homeuser (where user will be the Windows account user name you used to install Cygwin).
To reproyect/interpolate ORCA-format rasters to regular lon/lat a grid-description file probably be needed..
Run Cygwin terminal (by default an icon has been added to your desktop, as well as to your Windows Start
programs list).
15. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
Reprojecting the data
5. Climate Data Operators –CDO:
You also must create a text file named “grid”, with the following characteristics:
gridtype = lonlat Identifies the wanted gridtype as a lon/lat regular
grid
xsize = 1440 Number of columns of the resulting raster
ysize = 664 Number of rows of the resulting raster
xfirst = -180 Longitude of the left corner of the raster
xinc = 0.25 X size of the cells; take into account that (xfirst+
xsize* xinc) should match the longitude of the
right corner of the resulting raster (e.g. 180)
yfirst = -77 Latitude of the bottom corner of the raster.
yinc = 0.25 Y size of the cells; take into account that (yfirst+
ysize* yinc) should match the latitude of the top
corner of the resulting raster (e.g. 90)
Please, copy it in the folder
C:cygwin64homeuser (see step 9).
16. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
Reprojecting the data
5. Climate Data Operators –CDO:
Cygwin terminal is a Linux-like shell. Type ls command then press Intro, to see a list of files in the default
folder. If you copied the netCDF files as indicated in step 9, they should be in the list:
17. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
Reprojecting the data
5. Climate Data Operators –CDO:
Run the following cod command to perform reprojection/interpolation:
where “input_file.nc” is the original file to reproject and the “output_file.nc” will be the result.
Output file generated can be found in the folder C:cygwin64homeuser (see step 9).
For more options, CDO user guide can be found in CDO website:
https://code.mpimet.mpg.de/projects/cdo/embedded/cdo.pdf
cdo remapnn,grid.txt Input_file.nc output_file.nc
18. MODESTR QUICK TUTORIALS HTTP://WWW.IPEZ.ES/MODESTR/
It was the Step by step tutorial:
Working with marine environmental
variables, CMEMS and reprojections
Thank you for your interest.
After running the Cygwin, you can import the reprojected variables exactly as you did before (Tutorial 3),
but selecting the netCDF file option: single file, multiple files or folder.
You can find this one and other tutorials in
http://www.ipez.es/ModestR
By Estefanía Isaza Toro
Colaborator of
the ModestR team