Dennis Shea wrote:
> patton wrote:
>> Hello list,
>>
>> I'm using :
>>
>> plot = gsn_csm_contour_map_overlay(wks,vrt,Hgeo,res,resh)
>>
>> to ploting a overlay between "Relative Vorticity and Geopotential
>> Height"
>>
>> I have:
>> .
>> .
>> .
>> tf = addfile("CANUHELPME?.grib2","r")
>> U = tf->U_GRD_GDS0_ISBL_10({650},:,:) V =
>> tf->V_GRD_GDS0_ISBL_10({650},:,:)
>> Hgeo = tf->HGT_GDS0_ISBL_10({650},:,:)
>>
>> wks = gsn_open_wks("x11","HELPMEXD") ;
>> gsn_define_colormap(wks,"BlWhRe") scale =
>> 1.e05 vrt =
>> U vrt = uv2vrG_Wrap(U,V)
>> .
>> .
>> .
>> and is perfect, but is not what i want.
>>
>> uv2vrG_Wrap(U,V) Computes the vorticity via spherical harmonics and i
>> need
>> Compute it using centered finite differences.
>>
>> For that i founded :
>>
>> uv2vr_cfd() cool!! =D:::....
>>
>> but i tried writting:
>> .
>> .
>> .
>> scale = 1.e05 vrt =
>> U vrt = uv2vr_cfd(U,V,:,:,3)
>> .
>> .
>> .
>> and simply i can't plot it.
>>
>> I have been looking for examples and more documentation about that
>> function
>> but... i'm lost =D.
>>
> ====================================
>
> I speculate that the coordinate variables have not been associated with
> the vr variable as coordinate variables. Try
> vr = *uv2vr_cfd* (u,v,lat,lon, 3)
> printVarSummary(vr)
> vr_at_long_name = "vorticity"
> vr_at_units = "1/s"
> copy_VarCoords(u,vr(
> printVarSummary(vr)
Thanks Dennis,
But nothing, simply is not ploted.
i dunno what i must to put like lat and lon
i attach my grib and may ncl file, please look it.
Regards,
-- Tomás Hernández C.
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl"
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/shea_util.ncl" ;carga funciones extras
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl"
begin
tf = addfile("000la.grib2","r")
Vort = tf->ABS_V_GDS0_ISBL_10(:,:) ; 650 mb
U = tf->U_GRD_GDS0_ISBL_10(7,:,:) ;650 MB :D!
V = tf->V_GRD_GDS0_ISBL_10(7,:,:)
wks = gsn_open_wks("x11","vort") ;
gsn_define_colormap(wks,"BlWhRe") ; Change color map
scale = 1.e05
; vrt = U
; vrt = uv2vrG (U,V)
;-----------
vrt = uv2vr_cfd (U,V,lat,lon, 3)
printVarSummary(vrt)
vrt_at_long_name = "vorticity"
vrt_at_units = "1/s"
copy_VarCoords(u,vrt)
printVarSummary(vrt)
;-----------
res = True ; Set plot options
;------------;
;Plot Manager;
res_at_pmTickMarkDisplayMode = "Always" ; Enable Map Tickmarks
res_at_pmLabelBarWidthF = 0.1 ; Change labelbar width
res_at_pmLegendDisplayMode = "Always" ; Turn legends on
;--------------;
;Grafical Style n;
res_at_gsnMaximize = True ; Maximize plot in frame
res_at_gsnSpreadColors = True ; Span full color map
res_at_gsnSpreadColorStart = 16 ; Start at color index 14
res_at_gsnSpreadColorEnd = -3 ; Stop at 3rd color from end
res_at_gsnAddCyclic = False ; hace que no estire el coloreo xD
res_at_gsnStringFontHeightF = 0.02 ; Change subtitles size
res_at_gsnRightStringOrthogonalPosF = 0.02 ; and position
res_at_gsnLeftStringOrthogonalPosF = 0.02
;-------;
;Contour:
res_at_cnLevelSelectionMode = "ManualLevels" ; /"ExplicitLevels"
res_at_cnMinLevelValF = -0.0001 ; Minimum contour level
res_at_cnMaxLevelValF = 0.0001 ; Maximum contour level
res_at_cnLevelSpacingF = 0.00002 ; Contour level spacing
res_at_cnFillOn = True ; Turn on contour fill
res_at_cnLinesOn = True ; Turn off contour lines
res_at_cnHighLabelsOn = True ;Pone 1 etiqueta rara xD
;--------;
;Labelbar;
res_at_lbBoxLinesOn = False ; Turn off labelbar box lines
res_at_lbLabelAutoStride = True ; Control labelbar labels.
res_at_lbOrientation = "Vertical" ; Move labelbar to sides
res_at_lbLabelFontHeightF = 0.013 ; change labelbar height.
res_at_lbBoxLinesOn = True ; Turn off labelbar box lines.
;----;
;Maps;
res_at_mpGridAndLimbOn = True ; Turn on lat/lon grid lines
res_at_mpGridLineDashPattern = 30 ; Lat/lon lines as dashed
res_at_mpGridSpacingF = 5
res_at_mpLimitMode = "Corners" ; Elige el rango del mapa a mostrar
res_at_mpGridLineColor ="grey"
;CHILE
res_at_mpLeftCornerLatF = -70
res_at_mpLeftCornerLonF = -120
res_at_mpRightCornerLatF = -10
res_at_mpRightCornerLonF = -60
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
plot = gsn_csm_contour_map_ce(wks,vrt,res) ; Call the gsn_csm function for
; drawing contours over a map.
end
_______________________________________________
ncl-talk mailing list
ncl-talk_at_ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
This archive was generated by hypermail 2.2.0 : Wed Jan 23 2008 - 14:19:33 MST