<div dir="ltr"><div dir="ltr"><div><div dir="ltr"><div>NCL's <a href="https://www.ncl.ucar.edu/Document/Functions/Built-in/specx_anal.shtml"><b>specx_anal</b></a> uses a modified Daniell smoother. It requires the argument 'jave' to be an odd number.</div><div>Please read the documentation.<br></div><div><br></div><div>Also see: <a href="https://www.ncl.ucar.edu/Applications/filter.shtml" target="_blank"><b> https://www.ncl.ucar.edu/Applications/filter.shtml</b></a></div><div><br></div><div>===</div><div><b></b><br></div></div></div><div>There is no explicit Daniell filter function in NCL. You can write your own.<br></div><div>undef ("daniell_filter")</div><div>function daniell_filter(x[*]:numeric,n[1]:integer ... )</div><div>begin</div><div> :</div><div> xDaniell = ...</div><div> :</div><div> return(xDaniell)<br></div><div>end</div><div>;--------------- MAIN -------------</div><div><br></div><div><pre> iopt = 0 ; remove series mean
jave = 0 ; no smoothing; return <b>periodogram estimates</b>
pct = 0.1 ; taper 10% of the data
dof = <a href="https://www.ncl.ucar.edu/Document/Functions/Built-in/specx_anal.shtml">specx_anal</a> (x,iopt,jave,pct) </pre></div><div> spcx = dog@spcx ; explicitly extract periodogram estimates<br></div><div> n = 12</div><div> spcx = daniell_filter(spcx, n, ...) ; apply daniell filter to periodogram<br></div><div> spcx@info = "Spectra after daniell filter n="+n</div><div><br></div><div>--------------------</div><div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Jul 15, 2020 at 9:00 AM Xi Chang <<a href="mailto:xi.chang01@gmail.com" target="_blank">xi.chang01@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="auto">Dear NCL,</div><div dir="auto"><br></div><div dir="auto">Is there any way to creat Daniell Filter for smoothing the spectra in NCL?</div><div dir="auto"><br></div><div dir="auto">Thanks</div><div dir="auto">Chang</div>
</blockquote></div>
</div>