Re: Fwd: need leave increase the figure for a good view, please

From: Debora Alvim <deborasalvim_at_nyahnyahspammersnyahnyah>
Date: Wed Aug 07 2013 - 12:00:57 MDT

Dear Kyle,

I thank for information.

I made the recommendation and too tried test maximize_output(wks,True) in the
other places of my script, but what it does when I put
maximize_output(wks,True)
  the same your recommendation or in different place, the result is that
plot only a single map in the figure and need the 15 maps in the same
figure.

Thanks
Cheers,
Debora Alvim.

2013/8/7 Kyle Griffin <ksgriffin2@wisc.edu>

> I would recommend the use of maximize_output at the end of your script. It
> should be called after you have added everything to the plot and
> essentially right before you want to look at the image. You'll notice, if
> you look at the code that accompanies the example you linked to, that the
> call to maximize_output is the last procedure call in the script. See:
> http://www.ncl.ucar.edu/Applications/Scripts/panel_20.ncl
>
> You will also most likely want to set gsnDraw and gsnFrame to False
> earlier in your script to ensure that everything is drawn at the same time
> when you call maximize_output (it looks like you have this done already,
> which is great!). I'm not sure if the gsn_panel call works any differently,
> as I've never had to maximize a panel plot.
>
> In the script in your original email, I would include the call as such:
>
> resP = True ; modify the panel plot
> resP@txString = "Precipitacao convectiva"
> resP@gsnPanelLabelBar = True ; add common colorbar
> resP@gsnMaximize = True
> resP@gsnFrame = True
> resP@lbLabelFontHeightF = 0.007 ; make labels smaller
> gsn_panel(wks,plot,(/15,3/),resP) ; now draw as one plot
> ;This is the new line
> maximize_output(wks,True)
> end
>
> If this still doesn't work, let us know.
>
>
> Kyle
>
>
> ----------------------------------------
> Kyle S. Griffin
> Department of Atmospheric and Oceanic Sciences
> University of Wisconsin - Madison
> Room 1421
> 1225 W Dayton St, Madison, WI 53706
> Email: ksgriffin2@wisc.edu
>
>
> On Wed, Aug 7, 2013 at 10:28 AM, Debora Alvim <deborasalvim@gmail.com>wrote:
>
>> Hi NCL,
>>
>> I don't need better my resolution. The resolution figure is good.
>>
>> I need maximize plots in all frame. I need this figure in entire
>> workstation. I saw this example
>> http://www.ncl.ucar.edu/Applications/Images/panel_20_lg.png
>> but I don't know where put in my script
>>
>> psres = True
>> maximize_output(wks,psres)
>>
>> if you can help me I'll be thankful
>>
>> Look my figure attached in this email, the size is terrible.
>>
>> Thank you,
>> Debora Alvim.
>>
>>
>>
>>
>>
>>
>> 2013/8/7 Kyle Griffin <ksgriffin2@wisc.edu>
>>
>>> Hi Debora,
>>>
>>> I'd recommend trying to use the wkWidth and wkHeight settings, as these
>>> work well when you're outputting directly to PNG format. In general, try
>>> the lines below before creating your wks
>>>
>>> wksType = "png"
>>> ; The next two statements specify the width and height of the PNG output
>>> in pixels.
>>> wksType@wkWidth = 1000
>>> wksType@wkHeight = 1200
>>>
>>> ; This replaces the gsn_open_wks line you included in your script
>>> previously
>>> wks = gsn_open_wks(wksType,"prcv")
>>>
>>>
>>> You may also want to look into the maximize_output function (see NCL
>>> site) as well if you want to be sure your figure is filling the entire
>>> workstation.
>>>
>>> Hope this helps,
>>>
>>>
>>> Kyle
>>>
>>> ----------------------------------------
>>> Kyle S. Griffin
>>> Department of Atmospheric and Oceanic Sciences
>>> University of Wisconsin - Madison
>>> Room 1421
>>> 1225 W Dayton St, Madison, WI 53706
>>> Email: ksgriffin2@wisc.edu
>>>
>>>
>>> On Wed, Aug 7, 2013 at 9:43 AM, Debora Alvim <deborasalvim@gmail.com>wrote:
>>>
>>>>
>>>>
>>>> Dear NCL,
>>>>
>>>> Recently I started using ncl with the help of the site, I lay in this
>>>> tool.
>>>>
>>>> I made a figure, but I would leave this bigger picture, to that I can
>>>> view the maps.
>>>>
>>>> I am sending the script and the figure attached and the same script
>>>> below.
>>>>
>>>> Thank you!
>>>>
>>>> Cheers,
>>>> Débora Alvim.
>>>> National Institute for Space Research
>>>> Cachoeira Paulista - São Paulo - Brazil
>>>>
>>>>
>>>> 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/contributed.ncl"
>>>> begin
>>>>
>>>> a = addfile ("/Users/inpe/Documents/testec/testec_199910.01_echam.nc
>>>> ","r")
>>>> printVarSummary(a->aprc)
>>>> preca = a->aprc(0,:,:)
>>>>
>>>> b = addfile ("/Users/inpe/Documents/testec/testec_199911.01_echam.nc
>>>> ","r")
>>>> printVarSummary(b->aprc)
>>>> precb = b->aprc(0,:,:)
>>>>
>>>> c = addfile ("/Users/inpe/Documents/testec/testec_199912.01_echam.nc
>>>> ","r")
>>>> printVarSummary(c->aprc)
>>>> precc = c->aprc(0,:,:)
>>>>
>>>> d = addfile ("/Users/inpe/Documents/testec/testec_200001.01_echam.nc
>>>> ","r")
>>>> printVarSummary(d->aprc)
>>>> precd = d->aprc(0,:,:)
>>>>
>>>> e = addfile ("/Users/inpe/Documents/testec/testec_200002.01_echam.nc
>>>> ","r")
>>>> printVarSummary(e->aprc)
>>>> prece = e->aprc(0,:,:)
>>>>
>>>> f = addfile ("/Users/inpe/Documents/testec/testec_200003.01_echam.nc
>>>> ","r")
>>>> printVarSummary(f->aprc)
>>>> precf = f->aprc(0,:,:)
>>>>
>>>> g = addfile ("/Users/inpe/Documents/testec/testec_200004.01_echam.nc
>>>> ","r")
>>>> printVarSummary(g->aprc)
>>>> precg = g->aprc(0,:,:)
>>>>
>>>> h = addfile ("/Users/inpe/Documents/testec/testec_200005.01_echam.nc
>>>> ","r")
>>>> printVarSummary(h->aprc)
>>>> prech = h->aprc(0,:,:)
>>>>
>>>> i = addfile ("/Users/inpe/Documents/testec/testec_200006.01_echam.nc
>>>> ","r")
>>>> printVarSummary(i->aprc)
>>>> preci = i->aprc(0,:,:)
>>>>
>>>> j = addfile ("/Users/inpe/Documents/testec/testec_200007.01_echam.nc
>>>> ","r")
>>>> printVarSummary(j->aprc)
>>>> precj = j->aprc(0,:,:)
>>>>
>>>> k = addfile ("/Users/inpe/Documents/testec/testec_200008.01_echam.nc
>>>> ","r")
>>>> printVarSummary(k->aprc)
>>>> preck = k->aprc(0,:,:)
>>>>
>>>> l = addfile ("/Users/inpe/Documents/testec/testec_200009.01_echam.nc
>>>> ","r")
>>>> printVarSummary(l->aprc)
>>>> precl = l->aprc(0,:,:)
>>>>
>>>> m = addfile ("/Users/inpe/Documents/testec/testec_200010.01_echam.nc
>>>> ","r")
>>>> printVarSummary(m->aprc)
>>>> precm = m->aprc(0,:,:)
>>>>
>>>> n = addfile ("/Users/inpe/Documents/testec/testec_200011.01_echam.nc
>>>> ","r")
>>>> printVarSummary(n->aprc)
>>>> precn = n->aprc(0,:,:)
>>>>
>>>> o = addfile ("/Users/inpe/Documents/testec/testec_200012.01_echam.nc
>>>> ","r")
>>>> printVarSummary(o->aprc)
>>>> preco = o->aprc(0,:,:)
>>>>
>>>>
>>>> ; Plot
>>>> wks = gsn_open_wks("png","prcv")
>>>> gsn_define_colormap(wks,"prcp_2")
>>>>
>>>> plot = new(15,graphic)
>>>>
>>>> res = True
>>>> res@gsnDraw = False ; don't draw
>>>> res@gsnFrame = False ; don't advance frame
>>>> res@cnInfoLabelOn = False ; turn off cn info label
>>>> res@cnFillOn = True ; turn on color
>>>> res@gsnSpreadColors = True ; spread out color table
>>>> res@gsnSpreadColorStart = 2
>>>> res@gsnSpreadColorEnd = 20
>>>> res@lbLabelBarOn = False ; turn off individual cb's
>>>>
>>>>
>>>>
>>>> plot(0) = gsn_csm_contour_map_ce(wks,preca,res)
>>>> plot(1) = gsn_csm_contour_map_ce(wks,precb,res)
>>>> plot(2) = gsn_csm_contour_map_ce(wks,precc,res)
>>>> plot(3) = gsn_csm_contour_map_ce(wks,precd,res)
>>>> plot(4) = gsn_csm_contour_map_ce(wks,prece,res)
>>>> plot(5) = gsn_csm_contour_map_ce(wks,precf,res)
>>>> plot(6) = gsn_csm_contour_map_ce(wks,precg,res)
>>>> plot(7) = gsn_csm_contour_map_ce(wks,prech,res)
>>>> plot(8) = gsn_csm_contour_map_ce(wks,preci,res)
>>>> plot(9) = gsn_csm_contour_map_ce(wks,precj,res)
>>>> plot(10) = gsn_csm_contour_map_ce(wks,preck,res)
>>>> plot(11) = gsn_csm_contour_map_ce(wks,precl,res)
>>>> plot(12) = gsn_csm_contour_map_ce(wks,precm,res)
>>>> plot(13) = gsn_csm_contour_map_ce(wks,precn,res)
>>>> plot(14) = gsn_csm_contour_map_ce(wks,preco,res)
>>>>
>>>>
>>>> resP = True ; modify the panel plot
>>>> resP@txString = "Precipitacao convectiva"
>>>> resP@gsnPanelLabelBar = True ; add common colorbar
>>>> resP@gsnMaximize = True
>>>> resP@gsnFrame = True
>>>> resP@lbLabelFontHeightF = 0.007 ; make labels smaller
>>>> gsn_panel(wks,plot,(/15,3/),resP) ; now draw as one plot
>>>> end
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> 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
Received on Wed Aug 7 12:01:40 2013

This archive was generated by hypermail 2.1.8 : Wed Aug 07 2013 - 13:59:00 MDT