<div dir="ltr"><div dir="ltr"><div>Hi Andrea,</div><div><br></div><div>The function documentation has been changed. <br></div><div><br></div><div>The 'Description' section mentions the historical reason why 'dimension reordering' was used. <br></div><div><br></div><div>More comments are included in the examples. This includes some units information.</div><div><br></div><div><div>Example 4 illustrates a more elaborate step-by-step example of calculating</div><div>column precipitable water. It uses a different function [dim_sum_n_Wrap] which</div><div>was not available at the time that 'prcwater_dp' was created.<br></div><div><br></div></div><div><a href="https://www.ncl.ucar.edu/Document/Functions/Built-in/prcwater_dp.shtml" target="_blank"><b>https://www.ncl.ucar.edu/Document/Functions/Built-in/prcwater_dp.shtml</b></a></div>  <br></div><div dir="ltr"><br></div>D<br><div><div class="gmail_quote"><div dir="ltr">On Tue, Oct 16, 2018 at 1:56 PM Andrea Jenney <<a href="mailto:andrea@atmos.colostate.edu" target="_blank">andrea@atmos.colostate.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word;line-break:after-white-space">The third example in the <a href="https://www.ncl.ucar.edu/Document/Functions/Built-in/prcwater_dp.shtml" target="_blank">documentation</a> for the function "prcwater_dp" does not work as written (copied below):<div><br></div><div><pre style="margin-top:0px;margin-bottom:0px;padding:0px;font-size:13.3333px;line-height:12pt;font-family:courier;border-style:solid;border-width:0px 0px 15px;border-color:transparent;font-variant-ligatures:normal;background-color:rgb(255,255,255)">  q    = f->Q    ; specific humidity [kg/kg]
  hyai = f->hyai ; read from a file the interface hybrid coefficients (size = nlev)
  hybi = f->hybi ; read from a file
  ps   = f->PS   ; surface pressure [Pa]
  p0   = 100000. ; since ps is in Pa 

  dp   = <a href="https://www.ncl.ucar.edu/Document/Functions/Built-in/dpres_hybrid_ccm.shtml" style="margin:0px;padding:0px;text-decoration:none;color:rgb(133,45,133);font-family:verdana,sans-serif" target="_blank"><b style="margin:0px;padding:0px">dpres_hybrid_ccm</b></a>(ps,p0,hyai,hybi)   
; dp(ntime,nlev-1,nlat,nlon)
  dp!0 = "time"
  dp!1 = "lev"
  dp!2 = "lat"
  dp!3 = "lon"

  pw = <b style="margin:0px;padding:0px">prcwater_dp</b>(q(time|:,lat|:,lon|:,lev|:),dp(time|:,lat|:,lon|:,lev|:))    
; pw [kg/m2]
  pw@long_name = "total column precipitable water"
  pw@units     = "kg/m2"</pre><div><br></div></div><div>This is because the level dimension that "dpres_hybrid_ccm" outputs has size nlev-1 (which is noted in the example code), and the "prcwater_dp" function requires that the level dimensions be the same length. </div><div><br></div><div>I can work around this by subsetting the specific humidity, q, to leave out the highest level (so that its level dimension now has size nlev-1), but I just wanted to make a note that the example is not sufficient. </div><div><br></div><div>
<div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><div><span style="background-color:rgb(255,255,255)">---</span></div><div><span style="background-color:rgb(255,255,255)">Andrea Jenney</span><br><span style="background-color:rgb(255,255,255)">PhD Student | Randall & Barnes Groups</span></div><div><span style="background-color:rgb(255,255,255)">Colorado State University | Dept. of Atmospheric Science </span></div><div><br></div></div><br class="m_2710199177568396314m_5200040413766952430m_7683542956966418607Apple-interchange-newline"></div><br class="m_2710199177568396314m_5200040413766952430m_7683542956966418607Apple-interchange-newline"></div><br class="m_2710199177568396314m_5200040413766952430m_7683542956966418607Apple-interchange-newline"></div><br class="m_2710199177568396314m_5200040413766952430m_7683542956966418607Apple-interchange-newline"><br class="m_2710199177568396314m_5200040413766952430m_7683542956966418607Apple-interchange-newline">
</div>
<br></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><br>
</blockquote></div></div></div>