<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Thanks Dennis!<div class=""><br class=""></div><div class="">-Jonathan</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><div><blockquote type="cite" class=""><div class="">On Apr 24, 2015, at 4:50 PM, Dennis Shea &lt;<a href="mailto:shea@ucar.edu" class="">shea@ucar.edu</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class=""><div class=""><div class=""><div class="">====<br class="">6.3.0<br class=""><br class=""><a href="http://www.ncl.ucar.edu/current_release.shtml" class="">http://www.ncl.ucar.edu/current_release.shtml</a><br class=""></div>Under 'Bugs Fixed'<br class=""><br class=""><div class="">


<br class="webkit-block-placeholder"></div><a href="http://www.ncl.ucar.edu/Document/Functions/Contributed/stat_dispersion.shtml" class=""><strong class="">stat_dispersion</strong></a> - The
second returned element returned was the sample variance and not the
sample standard deviation as is documented. In 6.3.0, the sample
standard deviation will be returned.
<br class=""><br class="">=====<br class=""><br class=""></div>%&gt; ncl -V<br class="">6.3.0<br class=""><br class="">&nbsp; a = (/-20.46505, -4.795454, -1.454606,-2.677286, -1.868608, -0.4972475, 1.18715, -1.657706, -3.428875, -2.766053, -1.689298, -0.3371645, -0.640966, -0.7326741/)<br class=""><br class="">&nbsp; opt = True<br class="">&nbsp; opt@PrintStat = True<br class="">&nbsp; stata = stat_dispersion(a, opt )<br class=""><br class=""><br class="">Copyright (C) 1995-2015 - All Rights Reserved<br class="">&nbsp;University Corporation for Atmospheric Research<br class="">&nbsp;NCAR Command Language Version 6.3.0&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;====================<br class="">&nbsp;The use of this software is governed by a License Agreement.<br class="">&nbsp;See <a href="http://www.ncl.ucar.edu/" class="">http://www.ncl.ucar.edu/</a> for more details.<br class="">(0)&nbsp;&nbsp;&nbsp; &nbsp;<br class="">(0)&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; ===&gt; Robust Dispersion Statistics &lt;===<br class="">(0)&nbsp;&nbsp;&nbsp; &nbsp;[0]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Mean=-2.98742<br class="">(0)&nbsp;&nbsp;&nbsp; &nbsp;[1]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; StdDev=5.24311&nbsp;&nbsp;&nbsp; &lt;=====<br class="">(0)&nbsp;&nbsp;&nbsp; &nbsp;[2]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Min=-20.465<br class="">(0)&nbsp;&nbsp;&nbsp; &nbsp;[3]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; LowDec=-20.465<br class=""></div>[SNIP]<br class=""><br class=""><div class=""><div class=""><br class=""></div></div></div><div class="gmail_extra"><br class=""><div class="gmail_quote">On Fri, Apr 24, 2015 at 2:25 PM, jbuzan <span dir="ltr" class="">&lt;<a href="mailto:jbuzan@purdue.edu" target="_blank" class="">jbuzan@purdue.edu</a>&gt;</span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word" class="">I don’t know if this has been fixed in 6.3.0, but there was a change in stat_dispersion and the standard deviation is no longer calculated. &nbsp;it is the variance.<div class=""><br class=""></div><div class="">you can change:</div><div class="">$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl</div><div class="">(I renamed the file)</div><div class=""><br class=""></div><div class="">and commented out:</div><div class="">&nbsp; &nbsp; &nbsp;; statx(1) = moment(1)&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;; std. deviation<br class=""><br class=""></div><div class="">and replaced with:</div><div class="">&nbsp; &nbsp; &nbsp;&nbsp;statx(1) = stddev(x)&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;; std. deviation<br class=""><br class=""></div><div class=""><br class=""></div><div class="">-Jonathan</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""><div class=""><blockquote type="cite" class=""><div class=""><div class="h5"><div class="">On Apr 24, 2015, at 4:20 PM, Rainer Luptowitz &lt;<a href="mailto:rlupt001@ucr.edu" target="_blank" class="">rlupt001@ucr.edu</a>&gt; wrote:</div><br class=""></div></div><div class=""><div class=""><div class="h5"><div dir="ltr" class="">Hi ncl-talk,<div class=""><br class=""></div><div class="">Is the standard deviation computed in the "stats_dispersion" function actually a variance?</div><div class=""><br class=""></div><div class="">I test this and it appears to be variance instead of stats_dispersion as seen in with sample "a" below.</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><div class="">Variable: a&nbsp;</div><div class="">Type: float</div><div class="">Total Size: 56 bytes</div><div class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 14 values</div><div class="">Number of Dimensions: 1</div><div class="">Dimensions and sizes:<span style="white-space:pre-wrap" class="">        </span>[ncl_join | 14] &nbsp; &nbsp;; I had joined 8 files trends with "addfiles" function</div><div class="">Coordinates:</div><div class="">Number Of Attributes: 0</div></div><div class=""><div class="">(0)<span style="white-space:pre-wrap" class="">        </span>-20.46505</div><div class="">(1)<span style="white-space:pre-wrap" class="">        </span>-4.795454</div><div class="">(2)<span style="white-space:pre-wrap" class="">        </span>-1.454606</div><div class="">(3)<span style="white-space:pre-wrap" class="">        </span>-2.677286</div><div class="">(4)<span style="white-space:pre-wrap" class="">        </span>-1.868608</div><div class="">(5)<span style="white-space:pre-wrap" class="">        </span>-0.4972475</div><div class="">(6)<span style="white-space:pre-wrap" class="">        </span>1.18715</div><div class="">(7)<span style="white-space:pre-wrap" class="">        </span>-1.657706</div><div class="">(8)<span style="white-space:pre-wrap" class="">        </span>-3.428875</div><div class="">(9)<span style="white-space:pre-wrap" class="">        </span>-2.766053</div><div class="">(10)<span style="white-space:pre-wrap" class="">        </span>-1.689298</div><div class="">(11)<span style="white-space:pre-wrap" class="">        </span>-0.3371645</div><div class="">(12)<span style="white-space:pre-wrap" class="">        </span>-0.640966</div><div class="">(13)<span style="white-space:pre-wrap" class="">        </span>-0.7326741</div><div class=""><br class=""></div><div class="">; ncl code compare variance to standard deviation</div><div class=""><br class=""></div><div class="">; the above data was placed into an array named "a"</div><div class=""><div class="">a = (/-20.46505, -4.795454, -1.454606,-2.677286, -1.868608, -0.4972475, 1.18715, -1.657706, -3.428875, -2.766053, -1.689298, -0.3371645, -0.640966, -0.7326741/)</div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">; Input</div><div class="">Var_a = variance(a) &nbsp;; calc variance</div><div class="">print(Var_a)</div><div class="">StdDev_a = stddev(a) ; calc standard deviation</div><div class="">print(StdDev_a)</div></div><div class=""><div class="">opt = True</div><div class="">opt@PrintStat = True</div><div class="">Stats_a = stat_dispersion(a,opt)</div></div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">; Output</div><div class="">; from individually calculating Variance<br class=""></div><div class=""><div class="">Variable: Var_a</div><div class="">Type: float</div><div class="">Total Size: 4 bytes</div><div class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 1 values</div><div class="">Number of Dimensions: 1</div><div class="">Dimensions and sizes:<span style="white-space:pre-wrap" class="">        </span>[1]</div><div class="">Coordinates:</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span>27.49021</div><div class=""><br class=""></div><div class="">; from individually calculating Standard Deviation</div><div class="">Variable: StdDev_a</div><div class="">Type: float</div><div class="">Total Size: 4 bytes</div><div class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 1 values</div><div class="">Number of Dimensions: 1</div><div class="">Dimensions and sizes:<span style="white-space:pre-wrap" class="">        </span>[1]</div><div class="">Coordinates:</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span>5.243111</div></div><div class=""><br class=""></div><div class="">; from Stats_Dispersion function.</div><div class="">(0)</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> &nbsp; ===&gt; Robust Dispersion Statistics &lt;===</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [0] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Mean=-2.98742</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [1] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;StdDev=27.4902 &nbsp; &nbsp;; this appears to be variance since</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [2] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Min=-20.4651</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [3] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;LowDec=-20.4651</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [4] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;LowOct=-20.4651</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [5] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;LowSex=-4.79545</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [6] &nbsp; &nbsp; LowQuartile=-3.42888</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [7] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;LowTri=-2.76605</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [8] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Median=-1.6735</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [9] &nbsp; &nbsp; &nbsp; &nbsp; HighTri=-1.45461</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [10] &nbsp; HighQuartile=-0.732674</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [11] &nbsp; &nbsp; &nbsp; &nbsp;HighSex=-0.640966</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [12] &nbsp; &nbsp; &nbsp; &nbsp;HighOct=-0.497248</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [13] &nbsp; &nbsp; &nbsp; &nbsp;HighDec=-0.497248</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [14] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Max=1.18715</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [15] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Range=21.6522</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [16] &nbsp; &nbsp; Dispersion=0.787633</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [17] &nbsp; &nbsp;RMS Anomaly=5.05239</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [18] &nbsp; &nbsp; &nbsp;# &nbsp; Total=14</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [19] &nbsp; &nbsp; &nbsp;# &nbsp; &nbsp;Used=14</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [20] &nbsp; &nbsp; &nbsp;# Missing=0</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [21] &nbsp; &nbsp; &nbsp;% Missing=0</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [22] &nbsp; &nbsp; Lower 0.1%=9.96921e+36</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [23] &nbsp; &nbsp; Lower 1.0%=9.96921e+36</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [24] &nbsp; &nbsp; Lower 5.0%=9.96921e+36</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [25] &nbsp; &nbsp; Upper 5.0%=9.96921e+36</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [26] &nbsp; &nbsp; Upper 1.0%=9.96921e+36</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [27] &nbsp; &nbsp; Upper 0.1%=9.96921e+36</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [28] &nbsp; &nbsp; &nbsp; Skewness=-2.57898</div><div class="">(0)<span style="white-space:pre-wrap" class="">        </span> [29] &nbsp; &nbsp; &nbsp; Kurtosis=5.86411</div></div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">What do you think?</div><div class=""><br class=""></div><div class="">Thank you for time and assistance,<br class=""></div><div class=""><br class=""></div><div class=""><div class=""><div class=""><div class=""><div dir="ltr" class=""><div class=""><div dir="ltr" class=""><font color="#0000ff" class=""><i class="">Rainer Luptowitz</i></font><div class=""><font color="#0000ff" class=""><i class="">Grad Student&nbsp;</i></font><div class=""><font color="#0000ff" class=""><i class="">Dept Earth Sciences</i></font></div><div class=""><font color="#0000ff" class=""><i class="">UC Riverside</i></font></div><div class=""><a href="mailto:rlupt001@ucr.edu" target="_blank" class=""><font color="#0000ff" class=""><i class="">rlupt001@ucr.edu</i></font></a></div><div class=""><br class=""></div></div></div></div></div></div></div>
</div></div></div></div></div>
_______________________________________________<br class="">ncl-talk mailing list<br class="">List instructions, subscriber options, unsubscribe:<br class=""><a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" target="_blank" class="">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a><br class=""></div></blockquote></div><br class=""></div></div><br class="">_______________________________________________<br class="">
ncl-talk mailing list<br class="">
List instructions, subscriber options, unsubscribe:<br class="">
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" target="_blank" class="">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a><br class="">
<br class=""></blockquote></div><br class=""></div>
</div></blockquote></div><br class=""></div></body></html>