Re: gsn_add_polyline not working in 6.2.0

From: Don Murray (NOAA Affiliate) <don.murray_at_nyahnyahspammersnyahnyah>
Date: Tue Apr 15 2014 - 10:04:38 MDT

Thanks, Adam!

On 4/15/14 9:58 AM, Adam Phillips wrote:
> Hi Don,
> A second alternative would be to do this:
> equa = gsn_add_polyline(wks,plot,(/0,180,360/),(/0,0,0/),resp) ; equator
> Adam
>
> On 04/15/2014 09:56 AM, Mary Haley wrote:
>> Hi Don,
>>
>> I was able to reproduce your problem and have filed a critical ticket
>> on it (NCL-1943).
>>
>> The only work-around I can come up with is to draw the line in two
>> separate pieces:
>>
>> equa1 = gsn_add_polyline(wks,plot,(/-180,0/),(/0,0/),resp)
>> equa2 = gsn_add_polyline(wks,plot,(/0,180/),(/0,0/),resp)
>>
>> We will likely release a V6.2.1 to fix some bugs in V6.2.0, and this
>> will be high on the list.
>>
>> —Mary
>>
>> On Apr 15, 2014, at 9:07 AM, Don Murray (NOAA Affiliate)
>> <don.murray@noaa.gov <mailto:don.murray@noaa.gov>> wrote:
>>
>>> Hi-
>>>
>>> I have a script that has been running fine under NCL 6.1.2, but now is
>>> not acting the same under 6.2.0. The part that isn't working is drawing
>>> a polyline along the equator. The relevant code is:
>>>
>>> plot = gsn_csm_contour_map(wks,data,rescf) ; color-filled
>>> if (.not.isanom) then
>>> plot1 = gsn_csm_contour(wks,data,rescn) ; contours
>>> overlay(plot,plot1)
>>> end if
>>> dlin = gsn_add_polyline(wks,plot,(/180,180/),(/-90,90/),resp) ;
>>> dateline
>>> equa = gsn_add_polyline(wks,plot,(/0,360/),(/0,0/),resp) ; equator
>>> draw(plot)
>>> draw(lbid)
>>> gsn_text_ndc(wks,"NOAA/ESRL/PSD",0.088,0.190,restx)
>>> if (isanom) then
>>> gsn_text_ndc(wks,"Base Period: "+baseDateString,0.52,0.190,restxa)
>>> end if
>>> frame(wks)
>>>
>>> In this script, a line is drawn at the dateline and the equator:
>>>
>>> http://www.esrl.noaa.gov/psd/map/images/sst/sst.20140316.gif
>>>
>>> Since upgrading to NCL 6.2.0, the equator line is missing:
>>>
>>> http://www.esrl.noaa.gov/psd/map/images/sst/sst.20140323.gif
>>>
>>> If I print out the data summary, it looks like:
>>>
>>> Variable: data (parameter)
>>> Type: float
>>> Total Size: 259200 bytes
>>> 64800 values
>>> Number of Dimensions: 2
>>> Dimensions and sizes:[lat | 180] x [lon | 360]
>>> Coordinates:
>>> lat: [89.5..-89.5]
>>> lon: [0.5..359.5]
>>> Number Of Attributes: 18
>>> time :78257
>>> long_name :Weekly Mean of Sea Surface Temperature
>>> unpacked_valid_range :( -5, 40 )
>>> actual_range :( -1.8, 35.63 )
>>> units :degC
>>> missing_value_original :32767
>>> precision :2
>>> least_significant_digit :2
>>> var_desc :Sea Surface Temperature
>>> dataset :NOAA Optimum Interpolation (OI) SST V2
>>> level_desc :Surface
>>> statistic :Weekly Mean
>>> parent_stat :Individual obs
>>> standard_name :sea_surface_temperature
>>> _FillValue_original :32767
>>> _FillValue :32767
>>> valid_range :( -5, 40 )
>>> missing_value :32767
>>>
>>>
>>> I tried adjusting the x values to be (/1,359/), but still no line across
>>> the plot.
>>>
>>> Thoughts on what could be going wrong?
>>>
>>> Don
>>> --
>>> Don Murray
>>> NOAA/ESRL/PSD and CU-CIRES
>>> 303-497-3596
>>> http://www.esrl.noaa.gov/psd/people/don.murray/
>>> _______________________________________________
>>> ncl-talk mailing list
>>> List instructions, subscriber options, unsubscribe:
>>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>
>>
>>
>> _______________________________________________
>> ncl-talk mailing list
>> List instructions, subscriber options, unsubscribe:
>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
> --
> ______________________________________________________________
> Adam Phillipsasphilli@ucar.edu
> NCAR/Climate and Global Dynamics Division (303) 497-1726
> P.O. Box 3000
> Boulder, CO 80307-3000http://www.cgd.ucar.edu/staff/asphilli
>

-- 
Don Murray
NOAA/ESRL/PSD and CU-CIRES
303-497-3596
http://www.esrl.noaa.gov/psd/people/don.murray/
Received on Tue Apr 15 10:04:54 2014

This archive was generated by hypermail 2.1.8 : Tue Apr 15 2014 - 10:45:19 MDT