Re: map projection

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Tue, 12 Feb 2008 14:43:52 -0700 (MST)

Hi Mike,

I noticed you have:

   res_at_tfDoNDCOverlay = True

Setting this resource to True indicates that when you overlay the
contours on the map, you don't need for any transformation to take
place because you've already done all the work of setting up the map
projection to *exactly* match the projection and area that the data
were orignally measured on.

This also generally means that your data variable ("var" in this case)
doesn't have any lat/lon coordinate arrays attached to it.

In your case, it looks like you might have 2D lat/lon coordinates
associated with your data? That is, are your "lat" and "lon" variables
the same dimensionality as "var", and do they contain the lat/lon
coordinates for each of var's points?

If so, you could try this:

; res_at_tfDoNDCOverlay = True
    var_at_lat2d = lat
    var_at_lon2d = lon

and see if this makes a difference. Doing this will cause your data to
go through a transformation, and hence it's not as crucial that you
get the projection exactly correct.

If this information doesn't help, then let me know. Perhaps you could
also provide me with the full script and data so I can take a look.

--Mary

On Tue, 12 Feb 2008, Michael Notaro wrote:

> I am trying to plot data with the following projection information.
> However, the data doesn't seem to correctly plot in the correct
> position on the map. A clip of the related code is included below.
> Any idea what might be wrong? Since I have 4 points specified
> in the projection data, is mpLimitMode="Corners" correct to use,
> since it only allows 2 points? I am also not entirely sure about
> mpLambertMeridianF.
>
> Thanks, Mike
>
> Lower left lat : -2.417 deg
> Lower left lon : -143.913 deg
> Upper left lat : 54.626 deg
> Upper left lon : 157.412 deg
> Lower right lat : -2.382 deg
> Lower right lon : -62.143 deg
> Upper right lat : 54.686 deg
> Upper right lon : -3.476 deg
> projection = ALBERS Conical Equal-area projection
> uses the clark ellipsoid
> first standard parallel = 20
> second standard parallel = 60
> lat0 = 45.0
> lon0 = -103.0
> cell height = 8 km
> cell width = 8 km
> xsize = 1280
> ysize = 1024
>
> --------------------------
>
> res_at_gsnAddCyclic = False
> res_at_mpLimitMode = "Corners"
> res_at_mpLeftCornerLatF = lat(0,0)
> res_at_mpLeftCornerLonF = lon(0,0)
> res_at_mpRightCornerLatF = lat(1023,1279)
> res_at_mpRightCornerLonF = lon(1023,1279)
> res_at_mpProjection = "LambertConformal"
> res_at_mpLambertParallel1F = 20.
> res_at_mpLambertParallel2F = 60.
> res_at_mpLambertMeridianF = -106.
> res_at_tfDoNDCOverlay = True
> res_at_trYReverse=True
> plot = gsn_csm_contour_map(wks,var,res)
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk_at_ucar.edu
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
_______________________________________________
ncl-talk mailing list
ncl-talk_at_ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Feb 12 2008 - 14:43:52 MST

This archive was generated by hypermail 2.2.0 : Tue Feb 12 2008 - 14:45:27 MST