[ncl-talk] Question about Ocean/Land fill color

Mary Haley haley at ucar.edu
Thu May 11 14:10:03 MDT 2017


Sun,

It helps if you can include a graphic that shows exactly what the issue is,
as I'm not sure what you mean by "I cannot get colors over the ocean and
land". Do you mean that you are only seeing filled contours?

If you could write "mor" to a netCDF file, and send me the file, then I can
run the script to see what's going on. I have a feeling that there may be
an issue with either draw order, or missing values.

To write "mor" to a file:

fout = addfile("formary.nc","c")
fout->mor = mor

Then send me the formary.nc file.

thanks,

--Mary


On Tue, May 9, 2017 at 2:47 PM, Sunmin Park <mireiyue at gmail.com> wrote:

> Hello,
>
> I am trying to fill colors in the ocean and land. I also use “rasterfill”.
>
> When I use raster fill, I cannot get colors over the ocean and land even
> though I have following;
>
>   res at cnFillOn            = True
>   res at mpOceanFillColor       = "lightblue"            ; array index in
> color map
>   res at mpLandFillColor        = "light yellow" ;ienna"          ; for
> land, ocean, and inland h20
>
> when I turn off raster fill I get less dataset presented over the plot…
>
>   res                     = True               ; plot mods desired
>   res at cnFillOn            = True               ; turn on color
>   res at gsnSpreadColors     = True               ; use full color map
>   res at cnLinesOn           = False              ; no contour lines
>   res at cnLineLabelsOn      = False              ; no line labels
>   res at cnFillMode       = "RasterFill"       ; Raster Mode
>
>   res at gsnDraw             = False              ; don't draw yet
>   res at gsnFrame            = False              ; don't advance frame yet
>   res at gsnAddCyclic        = False
>
>   res at cnFillDrawOrder  = "Predraw"          ; areas before map gets set
>
>   res at mpOceanFillColor       = "lightblue"            ; array index in
> color map
>   res at mpLandFillColor        = "light yellow" ;ienna"          ; for
> land, ocean, and inland h20
>
> res at cnLevelSelectionMode = "ExplicitLevels"
> res at cnLevels=(/1,2,3,4,5/)
> res at cnFillColors = (/2,3,4,8,9,10/) ;need to have one more number than
> levels, legend has one more space (room)
>
>   res at tmXBLabelFontHeightF     = 0.014         ; adjust some font heights
>   res at tmYLLabelFontHeightF     = 0.014
>   res at tiMainFontHeightF        = 0.022
>   res at txFontHeightF            = 0.017
>   res at lbLabelBarOn             = False        ; turn off label bar
>
>   plot = new(1,graphic)
>   @cnFillOn            = Truelot(0) = gsn_csm_contour_map_ce(wks,mor,res)
>
>   ppres                  = True
>   ppres at gsnPanelLabelBar = True                   ; common label bar
>   gsn_panel(wks,plot,(/1,1/),ppres)
>
> I appreciate any helps and comments.
>
> Thank you
> Sun-
>
>
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170511/ef2875dd/attachment.html 


More information about the ncl-talk mailing list