<div dir="ltr"><div>Yes! I missed it accidentally :) the plot works. <br></div>Thank you for the input I am grateful for that<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Aug 6, 2014 at 6:42 PM, Dennis Shea <span dir="ltr"><<a href="mailto:shea@ucar.edu" target="_blank">shea@ucar.edu</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div><div><div>When I 1st looked I thought you had left out some code so people would focus on the graphics part. <br>
It was pointed out to me that this was your entire code.<br><br></div>You allocated space for 12 plots via<div class=""><br>
<br> wks = gsn_open_wks ("ps", "panel" ) <br></div> plot = new ( 12 , graphic) ; <=== all are _FillValue<br><br></div>But you did not fill the graphical plot array with any contents<br>
<br></div> do nmo=0,11<br> :<br></div> plot(nmo) = .gsn...(wks,...,hres)<br></div> end do<br><br><br><div><div> <br><div><div><br><br></div></div></div></div></div><div class="HOEnZb">
<div class="h5"><div class="gmail_extra">
<br><br><div class="gmail_quote">On Wed, Aug 6, 2014 at 6:58 PM, Dennis Shea <span dir="ltr"><<a href="mailto:shea@ucar.edu" target="_blank">shea@ucar.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr"><div>Did you read the gsn_panel documentation? <br><br><a href="https://www.ncl.ucar.edu/Document/Graphics/Interfaces/gsn_panel.shtml" target="_blank">https://www.ncl.ucar.edu/Document/Graphics/Interfaces/gsn_panel.shtml</a><br>
<br></div>In particular, <br><br><pre>        procedure gsn_panel (
                wks : graphic,
                plots [*] : graphic,
                dims [*] : integer,
                res [1] : logical
        )
<br><em>dims</em>
An array of integers indicating the configuration of the plots on the
frame. <em>dims</em> can either be two integers representing the
number of rows and columns of the paneled lots ....<br>^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^<br></pre><pre>Think<br></pre><pre> dims = (/nrow,ncol/) <br><br>====<br><br>So, all you need is<br><br> pres = True<br>
pres@gsnMaximize = True<br><br>Then<br><br> gsn_panel(wks,plot,(/3,4/),pres) ; 3 rows; each row having 4 plots<br></pre><pre>or<br><br> gsn_panel(wks,plot,(/4,3/),pres) ; 4 rows; each row having 3 plots<br></pre><div dir="ltr">
<br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote"><div><div>On Wed, Aug 6, 2014 at 5:45 PM, Ipshita Majhi <span dir="ltr"><<a href="mailto:ipmajhi@alaska.edu" target="_blank">ipmajhi@alaska.edu</a>></span> wrote:<br>
</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><div dir="ltr">Hi,<br><br>I am trying to plot 12 plots in one panel. Each column with 4 plots and three columns like that. Here is the code, I would be grateful if you could tell me where the error is. Thanking you in advance<br>
===========================================<br>; To plot decadal plots<br>; ===========================================<br>;<br>; Concepts illustrated:<br>; - Specifying how many plots to draw in each row<br>; - Left-justifying and centering paneled plots<br>
;<br>load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"<br>load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl"<br><br>begin<br><br> ;=============================================<br>; data processing<br>
;=============================================<br> x=asciiread("~/Documents/PhD_June_2015/NCL_Moonsoon/Data_output/all_month_decade",(/13,12/), "float")<br> year_decadal=ispan(1880,2012,10)<br>;==============================================<br>
; create plot<br>;=============================================<br> <br><br> wks = gsn_open_wks ("ps", "panel" ) <br> plot = new ( 12 , graphic)<br><br><br> hres = True<br> hres@gsnDraw = False<br>
hres@gsnFrame = False<br><br> hres@tiMainString = "Decadal Mean"<br><br> hres@cnLevelSelectionMode = "ManualLevels" ; manual levels<br> hres@cnMinLevelValF = -10.<br>
hres@cnMaxLevelValF = 10.<br> hres@cnLevelSpacingF = 2. <br><br>;==============================================<br>; create panel<br>;=============================================<br> pres = True<br>
pres@gsnPanelRowSpec = True ; tell panel what order to plt<br> gsn_panel(wks,plot,(/4,4,4/),pres)<br><br> pres@gsnPanelCenter = False<br> gsn_panel(wks,plot,(/4,4,4/),pres)<br>end<br></div>
<br></div></div>_______________________________________________<br>
ncl-talk mailing list<br>
List instructions, subscriber options, unsubscribe:<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" target="_blank">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a><br>
<br></blockquote></div><br></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div>