<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div>I recommend using stat_dispersion:</div><div><a href="http://www.ncl.ucar.edu/Document/Functions/Contributed/stat_dispersion.shtml">http://www.ncl.ucar.edu/Document/Functions/Contributed/stat_dispersion.shtml</a></div><div><br></div><div>-Jonathan</div><div><br></div><div><br></div><div><br><div><div>On Sep 12, 2014, at 12:49 PM, Marcella, Marc &lt;<a href="mailto:MMarcella@AIR-WORLDWIDE.COM">MMarcella@AIR-WORLDWIDE.COM</a>&gt; wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div lang="EN-US" link="blue" vlink="purple" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;"><div class="WordSection1" style="page: WordSection1;"><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">Hi all,<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><br>Im having a bit of a problem trying to elegantly script calculating annual max values when I have varying amount of values for each year. For example, I have one text file with the year stamp for each event, and in another I have the corresponding wind value for that event.&nbsp; Some years there are four measurements, some years one, other years ten. Im trying to use a do loop that goes through each year in the text file to find the beginning and end index (i.e. what index refers to the beginning of that year’s values in the wind file and the index that refers to the last value of that year).&nbsp; I was then going to use that specific year’s indices with the max command on the wind value file.&nbsp; But I’m having not having too much luck and it’s getting messy with all the do and if statements.&nbsp; Any ideas?&nbsp; Are there simpler functions that Im not aware of built into NCL that can help with this?&nbsp; Any help would be greatly appreciated.<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p>&nbsp;</o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">Thanks,<br>Marc<o:p></o:p></div></div>_______________________________________________<br>ncl-talk mailing list<br>List instructions, subscriber options, unsubscribe:<br><a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" style="color: purple; text-decoration: underline;">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a></div></blockquote></div><br></div></body></html>