<div dir="ltr"><div>Hi Tabish,</div><div>It seems as though your query posted a number of weeks ago was not answered. Did you find a resolution to this issue? </div><div>Looking at your code this setting should have a range of between 0 and 1:</div><div>res3@vpWidthF    = 4</div><div>I would try adjusting that to 0.8, and then also set:</div><div>res3@vpXF = 0.15</div><div>vpXF is the starting point on the x-plane for the left edge of the plot boundary (valid values are 0 to 1), and vpWidthF is the width of the plot itself. Playing with those two settings should solve your issue.</div><div>Adam</div><br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><br><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">---------- Forwarded message ---------<br>From: <b class="gmail_sendername" dir="auto">Tabish Ansari via ncl-talk</b> <span dir="auto"><<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a>></span><br>Date: Mon, Sep 9, 2019 at 8:27 PM<br>Subject: [ncl-talk] Add text leftwards of time-series plot (OR, shift plot rightwards in viewport)<br>To: <a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a> USERS <<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a>><br></div><br><br><div dir="ltr"><div style="font-family:"trebuchet ms",sans-serif">Hi</div><div style="font-family:"trebuchet ms",sans-serif"><br></div><div style="font-family:"trebuchet ms",sans-serif">I've created a panel of some time-series plots with attached x-axes. I want to add some text on the left hand side of each of these plots. However, there isn't adequate space to do this. Is there a way to shift the plot rightwards in the viewport so that more white space can be created? <br></div><div style="font-family:"trebuchet ms",sans-serif"><br></div><div style="font-family:"trebuchet ms",sans-serif">The plot is attached.  <br></div><div style="font-family:"trebuchet ms",sans-serif"><br></div><div style="font-family:"trebuchet ms",sans-serif">Here's the script:</div><div style="font-family:"trebuchet ms",sans-serif"><br></div><div style="font-family:"trebuchet ms",sans-serif"><span style="background-color:rgb(0,0,255)"><span style="color:rgb(11,83,148)"><span style="background-color:rgb(255,255,255)">; These files still have to be loaded manually<br>load "$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRF_contributed.ncl"<br>load "$NCARG_ROOT/lib/ncarg/nclscripts/contrib/time_axis_labels.ncl"<br>;load "/data1/tabish/nclscripts/cd_inv_string.ncl"<br>load "$NCARG_ROOT/lib/ncarg/nclscripts/contrib/cd_string.ncl"<br>load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"<br>load "$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRFUserARW.ncl"<br><br><br><br>begin<br><br>emisarr0 = (/100,100,100,100, 100,100,100,100, 100,100,100,100/)<br>emisarr1 = (/ 40,100,100,40, 100,100,100,100, 100,100,100,100/)<br>emisarr2 = (/20,20,20,20, 100,100,100,100, 100,100,100,100/)<br>emisarr3 = (/40,40,40,40, 40,100,100,40, 100,100,100,100/)<br>emisarr4 = (/40,40,40,40, 40,40,40,40, 100,100,100,100/)<br>emisarr5 = (/40,40,40,40, 40,40,40,40, 40,40,40,40/)<br>emisarr6 = (/30,30,30,30, 30,30,30,30, 30,30,30,30/)<br>emisarr7 = (/20,20,20,20, 20,20,20,20, 20,20,20,20/)<br>emistimearr = ispan(1,12,1)<br><br><br>;---Start the graphics<br>wks = gsn_open_wks("pdf","MPCpolicy") ; send graphics to PNG file<br><br><br>; frame(wks)<br>; xy1 will be the base plot.<br>;  amid = gsn_attach_plots(xy1,(/xy2,xy3,xy4,xy5,xy6/),res1,res2)<br><br>res3 = True<br>res3@vpXF                 = 0.35       ; x location<br><br>res3@gsnXYBarChart = True            ; Create bar plot<br>res3@trYMaxF     =  100<br>res3@trYMinF     =  0<br><br>res3@tmXTOn        = False<br>res3@tmYROn        = False<br><br>;DRAW TICKMARKS INWARDS<br>res3@tmXBMajorOutwardLengthF=0.0<br>res3@tmXBMinorOutwardLengthF=0.0<br>res3@tmYLMajorOutwardLengthF=0.0<br>res3@tmYLMinorOutwardLengthF=0.0<br><br><br>res3@tmXBMajorLengthF=0.0<br>res3@tmXBMinorLengthF=0.0<br>res3@tmXBMinorThicknessF=0.0<br>res3@tmYLMajorLengthF=0.03<br>res3@tmYLMinorLengthF=0.02<br><br>res3@tmYLMode        = "Explicit"<br>res3@tmYLValues      = (/0,20,40,60,80,100/)<br>;res3@tmYLLabels      = "" + res@tmYLValues<br>res3@tmYLLabels      = (/"0","20","40","60","80","100"/)<br>res3@tmYLMinorValues = (/10,30,50,70,90/)<br><br>res3@tmXBMode = "Explicit"<br>res3@tmXBValues = (/1,2,3,4,5,6,7,8,9,10,11,12/)<br>res3@tmXBLabels = (/"I","T","P","R","I","T","P","R","I","T","P","R"/)<br>;res3@tmXBMinorValues = (/-0.5,12.5,24.5,36.5,48.5,60.5/)<br>res3@tmXBMajorLengthF=0.0<br>res3@tmXBMinorLengthF=0.0<br><br>res3@gsnXYBarChartColors = (/"tomato","tomato","tomato","tomato","limegreen","limegreen","limegreen","limegreen","dodgerblue","dodgerblue","dodgerblue","dodgerblue"/)            ; choose colors<br>res3@xyLineColors = (/"black"/) <br>res3@vpWidthF    = 4<br>res3@vpHeightF   = 0.6<br>res3@gsnMaximize = True<br><br>res3@tmXBLabelFontHeightF = 0.035<br>res3@tmYLLabelFontHeightF = 0.06<br>res3@tiYAxisFontHeightF = 0.035<br>res3@tiYAxisString = "Emissions (%)"<br>res3@gsnDraw  = False                          ; don't draw<br>res3@gsnFrame = False                          ; don't advance frame<br><br>emisplot0 = gsn_csm_xy (wks,emistimearr,emisarr0,res3)<br>emisplot1 = gsn_csm_xy (wks,emistimearr,emisarr1,res3)<br>emisplot2 = gsn_csm_xy (wks,emistimearr,emisarr2,res3)<br>emisplot3 = gsn_csm_xy (wks,emistimearr,emisarr3,res3)<br>emisplot4 = gsn_csm_xy (wks,emistimearr,emisarr4,res3)<br>emisplot5 = gsn_csm_xy (wks,emistimearr,emisarr5,res3)<br>emisplot6 = gsn_csm_xy (wks,emistimearr,emisarr6,res3)<br>emisplot7 = gsn_csm_xy (wks,emistimearr,emisarr7,res3)<br><br>; emisplot0 will be the base plot.<br>  res1                     = True<br>  res2                     = True<br>  res1@gsnMaximize         = True<br>  res2@gsnAttachPlotsXAxis = True<br>  amid = gsn_attach_plots(emisplot0,(/emisplot1,emisplot2,emisplot3,emisplot4,emisplot5,emisplot6,emisplot7/),res1,res2)<br><br>txres               = True<br>txres@txFontHeightF = 0.008<br>gsn_text_ndc(wks,"Case0: PM~B~2.5~N~<75 ~F33~m~F21~gm~S~-3~N~",0.01,0.915,txres)<br>gsn_text_ndc(wks,"Case1: PM~B~2.5~N~=75-100 ~F33~m~F21~gm~S~-3~N~",0.01,0.81,txres)<br>gsn_text_ndc(wks,"Case2: PM~B~2.5~N~=101-125 ~F33~m~F21~gm~S~-3~N~",0.01,0.68,txres)<br>gsn_text_ndc(wks,"Case3: PM~B~2.5~N~=125-150 ~F33~m~F21~gm~S~-3~N~",0.01,0.55,txres)<br>gsn_text_ndc(wks,"Case4: PM~B~2.5~N~=151-175 ~F33~m~F21~gm~S~-3~N~",0.01,0.45,txres)<br>gsn_text_ndc(wks,"Case5: PM~B~2.5~N~=176-200 ~F33~m~F21~gm~S~-3~N~",0.01,0.35,txres)<br>gsn_text_ndc(wks,"Case6: PM~B~2.5~N~=201-220 ~F33~m~F21~gm~S~-3~N~",0.01,0.23,txres)<br>gsn_text_ndc(wks,"Case7: PM~B~2.5~N~>225 ~F33~m~F21~gm~S~-3~N~",0.01,0.1,txres)<br><br>draw(emisplot0)<span></span><br>frame(wks)</span></span><br><br><span style="color:rgb(11,83,148)"><span style="background-color:rgb(255,255,255)">end</span></span></span><br></div><div style="font-family:"trebuchet ms",sans-serif"><br></div><div style="font-family:"trebuchet ms",sans-serif">Many thanks in advance.</div><div style="font-family:"trebuchet ms",sans-serif"><br></div><div style="font-family:"trebuchet ms",sans-serif">Cheers</div><div style="font-family:"trebuchet ms",sans-serif"><br></div><div style="font-family:"trebuchet ms",sans-serif">Tabish</div><div style="font-family:"trebuchet ms",sans-serif"><br></div><div style="font-family:"trebuchet ms",sans-serif"><br></div><div><div dir="ltr"><div dir="ltr"><div><div><font size="1"><span style="font-family:tahoma,sans-serif">Tabish U Ansari<br></span></font></div><font size="1"><span style="font-family:tahoma,sans-serif">PhD student, Lancaster Environment Center<br></span></font></div><font size="1"><span style="font-family:tahoma,sans-serif">Lancaster Univeristy<br> <span>Bailrigg</span>, <span>Lancaster</span>, <br><span>LA1 4YW</span>, <span>United Kingdom</span></span></font><br></div></div></div></div>
_______________________________________________<br>
ncl-talk mailing list<br>
<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a><br>
List instructions, subscriber options, unsubscribe:<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" rel="noreferrer" target="_blank">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a></div></div>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div><div><span><font color="#888888">Adam Phillips <br></font></span></div><span><font color="#888888">Associate Scientist,  </font></span><span><font color="#888888">Climate and Global Dynamics Laboratory, NCAR<br></font></span></div></div><div><span><font color="#888888"><a href="http://www.cgd.ucar.edu/staff/asphilli/" target="_blank">www.cgd.ucar.edu/staff/asphilli/</a>   </font></span><span><font color="#888888">303-497-1726 </font></span></div><span><font color="#888888"></font></span><div><div><span><font color="#888888"><br></font></span><div><span><font color="#888888"><a href="http://www.cgd.ucar.edu/staff/asphilli" target="_blank"></a></font></span></div></div></div></div></div></div></div></div></div></div></div></div>