Re: Matching the boundary of data and map, Thanks!

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Tue Apr 01 2014 - 15:55:10 MDT

Xiaoming,

Is it possible that you have a rotated grid? I will have to ask for Dave Brown’s help on additional parameters you might need to set.

Is this a WRF output file?

—Mary

On Apr 1, 2014, at 10:46 AM, Xiaoming Sun <yueyunxiaoming@gmail.com> wrote:

> Dear Dr. Mary,
>
> Thanks for your help!
>
> 1) The three values mentioned in the previous E-mail are from the global attributes of the data as follows,
> :CEN_LAT = -17.50001f ;
> :CEN_LON = -57.29999f ;
> :TRUELAT1 = -38.f ;
> :TRUELAT2 = 8.f ;
> :MOAD_CEN_LAT = -17.50001f ;
> :STAND_LON = -57.3f ;
> :POLE_LAT = 90.f ;
> :POLE_LON = 0.f ;
> I think I picked up the correct values as
> res@mpLambertParallel1F = -38.0
> res@mpLambertParallel2F = 8.0
> res@mpLambertMeridianF = -57.3
>
> 2) the mp*Corner* resources were used exactly the same as
> http://www.ncl.ucar.edu/Applications/lcnative.shtml
> , which in my script were
> res@mpLeftCornerLatF = lat2d(0, 0)
> res@mpLeftCornerLonF = lon2d(0, 0)
> res@mpRightCornerLatF = lat2d(dimDATA(0)-1, dimDATA(1)-1)
> res@mpRightCornerLonF = lon2d(dimDATA(0)-1, dimDATA(1)-1)
>
> 3) For tfDoNDCOverlay
> According to the description of tfDoNDCOverlay
> As expected,
> 3a) When
> tfDoNDCOverlay = True
> , the map and data won't match.
> please see attached
> mapDataBdytfDoNDCOverlayEQTrue.pdf
> By the way, the 2D coordinate was provided to the data
> either using
> curVar@lat2d = lat2d_Data
> curVar@lon2d = lon2d_Data
> or per
> res@sfXArray = lon2d_Data
> res@sfYArray = lat2d_Data
> , although both produce the same plot.
>
> 3b) When
> tfDoNDCOverlay = False
> , the map and data matches, but part of the data cannot be displayed.
> This is because the shape of the domain
> i.e., its upper-left corner is more westward than its bottom-left corner.
> please see attached
> mapDataBdytfDoNDCOverlayEQFalse.pdf
>
> 3a) and 3b) made me try something else, e.g., masked lambert conformal projection, although I am clear that it won't work.
>
> I am wondering is there any approach to make a plot of the data, but without extra regions except for the data?
>
> Thanks again,
>
> Best Regards,
>
> Xiaoming
>
>
>
>
>
>
>
>
>
>
> On Tue, Apr 1, 2014 at 11:39 AM, Mary Haley <haley@ucar.edu> wrote:
> Dear Xiaoming,
>
> If your data boundary is not matching the map boundary, this is usually because your map projection parameters are not correct.
>
> You need to know *exactly* what Lambert Conformal parallels and meridian were used for your data, and then use these values.
>
> How are you getting these three values? Sometimes they are on the file, say as global attributes, or they may be attached to your data variable as attributes.
>
> You probably don’t want to use the masked lambert conformal option, because this is mainly for viewing a smaller section of your original lambert conformal map.
>
> Finally, are you also setting the two corners of your projection as seen in “lcnative_1.ncl”, via the mp*Corner* resources?
>
> http://www.ncl.ucar.edu/Applications/lcnative.shtml
>
> This example is also setting “tfDoNDCOverlay” to True, but you don’t need to do this if you are providing lat/lon coordinates to the plotting function.
>
> —Mary
>
> On Mar 31, 2014, at 4:56 PM, Xiaoming Sun <yueyunxiaoming@gmail.com> wrote:
>
>>
>> Dear All,
>>
>> I am plotting some regional data using lambertconformal projection.
>> The data go across the equator, with most of them in the Southern Hemisphere.
>> res@mpLambertParallel1F = -38.0
>> res@mpLambertParallel2F = 8.0
>> res@mpLambertMeridianF = -57.3
>>
>> I am hoping to have the map boundary directly along with the data boundary,
>> (please see attached PDF plot, which DOES NOT).
>>
>> Then, I tried masked lambert conformal projection
>> as described at
>> http://www.ncl.ucar.edu/Applications/lcmask.shtml
>>
>> However, this cannot work,
>> because the data go across the equator
>> and got the following information
>> "
>> (0) mask_lambert_conformal: warning: you are not authorized to specify.
>> (0) a maxlat that is above the equator and a minlat that is below
>> (0) the equator. No masking will take place.
>> "
>>
>> Did anyone go through this before?
>>
>> Any help is appreciated!
>>
>> Thanks,
>>
>> Best Regards,
>>
>> Xiaoming
>> --
>> Xiaoming Sun
>> <DataMapBoundaryMatching.pdf>_______________________________________________
>> ncl-talk mailing list
>> List instructions, subscriber options, unsubscribe:
>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
>
>
>
> --
> Xiaoming Sun
> <mapDataBdytfDoNDCOverlayEQFalse.pdf><mapDataBdytfDoNDCOverlayEQTRUE.pdf>

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Apr 1 15:55:24 2014

This archive was generated by hypermail 2.1.8 : Thu Apr 03 2014 - 13:36:27 MDT