[ncl-talk] Overlay two grids with different projections
Brandon Fisel
bjfisel at gmail.com
Fri May 21 14:50:44 MDT 2021
Hello,
I am trying to overlay two different grids, which are both on different
projections to see the differences between the grids.
One grid (rectilinear, lat-lon) has attributes:
dimensions:
lat = 258 ;
lon = 600 ;
variables:
double mask(lat, lon) ;
mask:_FillValue = 1.00000002004088e+20 ;
mask:long_name = "Land Mask" ;
mask:missing_value = 1.e+20f ;
mask:standard_name = "land_binary_mask" ;
mask:units = "1" ;
double lat(lat) ;
lat:long_name = "latitude" ;
lat:units = "degrees_north" ;
lat:standard_name = "latitude" ;
double lon(lon) ;
lon:long_name = "longitude" ;
lon:units = "degrees_east" ;
lon:standard_name = "longitude" ;
The other grid (cylindrical, rotated mercator) has attributes:
dimensions:
y = 278 ;
x = 334 ;
variables:
float mask(y, x) ;
mask:_FillValue = 1.e+20f ;
mask:coordinates = "lat lon" ;
mask:grid_mapping = "rotated_mercator" ;
mask:long_name = "Land Area Fraction" ;
mask:missing_value = 1.e+20f ;
mask:standard_name = "land_area_fraction" ;
mask:units = "%" ;
double lat(y, x) ;
lat:_Coordinate_AxisType = "Lat" ;
lat:long_name = "Latitude on Cross Points" ;
lat:standard_name = "latitude" ;
lat:units = "degrees_north" ;
lat:grid_mapping = "rcm_map" ;
double lon(y, x) ;
lon:_Coordinate_AxisType = "Lon" ;
lon:long_name = "Longitude on Cross Points" ;
lon:standard_name = "longitude" ;
lon:units = "degrees_east" ;
lon:grid_mapping = "rcm_map" ;
char oblique_mercator ;
oblique_mercator:grid_mapping_name = "oblique_mercator" ;
oblique_mercator:latitude_of_projection_origin = 46. ;
oblique_mercator:longitude_of_projection_origin = 263. ;
oblique_mercator:_CoordinateTransformType = "Projection" ;
oblique_mercator:_CoordinateAxisTypes = "GeoX GeoY" ;
oblique_mercator:azimuth_of_central_line = 90. ;
oblique_mercator:scale_factor_at_projection_origin = 1. ;
oblique_mercator:false_easting = 0. ;
oblique_mercator:false_northing = 0. ;
char rotated_mercator ;
rotated_mercator:grid_mapping_name = "rotated_mercator" ;
rotated_mercator:azimuth_of_central_line = 90. ;
rotated_mercator:latitude_of_projection_origin = 46.5 ;
rotated_mercator:longitude_of_projection_origin = 263. ;
rotated_mercator:scale_factor_at_projection_origin = 1. ;
rotated_mercator:false_easting = 0. ;
rotated_mercator:false_northing = 0. ;
double x(x) ;
x:_CoordinateAxisType = "GeoX" ;
x:axis = "X" ;
x:long_name = "x-coordinate in Cartesian system" ;
x:standard_name = "projection_x_coordinate" ;
x:units = "m" ;
double y(y) ;
y:_CoordinateAxisType = "GeoY" ;
y:axis = "Y" ;
y:long_name = "y-coordinate in Cartesian system" ;
y:standard_name = "projection_y_coordinate" ;
y:units = "m" ;
I have been following something similar to
https://www.ncl.ucar.edu/Applications/Scripts/datagrid_3.ncl from NCL
Graphics: Drawing locations of data values via markers or lines (ucar.edu)
<https://www.ncl.ucar.edu/Applications/datagrid.shtml>, but it seems to
only plot the lat-lon grid and not also the rotated mercator grid.
Is this possible to plot two different projections of a grid as an overlay?
Thanks,
BJF
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.ucar.edu/pipermail/ncl-talk/attachments/20210521/20679785/attachment.html>
More information about the ncl-talk
mailing list