<html><head></head><body><div style="color:#000; background-color:#fff; font-family:verdana, helvetica, sans-serif;font-size:16px"><div id="yui_3_16_0_ym19_1_1512501861679_9557"><span></span>Thank you dear Dennis for your help. I am sorry if my questions look too basic. I already read the filtering examples. <br></div><div dir="ltr" id="yui_3_16_0_ym19_1_1512501861679_9602">The fact is that using their method (you can see my code in my previous post), from daily rainfall data I got negative values after filtering, what is abnormal. <br></div><div id="yui_3_16_0_ym19_1_1512501861679_9582" class="signature">-----------------------------<br>GUIGMA</div> <div class="qtdSeparateBR"><br><br></div><div style="display: block;" class="yahoo_quoted"> <div style="font-family: verdana, helvetica, sans-serif; font-size: 16px;"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, Sans-Serif; font-size: 16px;"> <div dir="ltr"><font size="2" face="Arial"> On Tuesday, 5 December 2017, 19:03, Dennis Shea <shea@ucar.edu> wrote:<br></font></div> <br><br> <div class="y_msg_container"><div id="yiv8018064329"><div><div dir="ltr"><div><div><div><div><div>Please look at the filtering examples:<br clear="none"> <a rel="nofollow" shape="rect" target="_blank" href="https://www.ncl.ucar.edu/Applications/filter.shtml">https://www.ncl.ucar.edu/Applications/filter.shtml</a><br clear="none"><br clear="none"></div> In particular, run Example 8<br clear="none"><br clear="none"></div>[1] yes, of course ... more weights can create a sharper cutoff but there is a larger loass od data at the beginning and end.<br clear="none"><br clear="none"></div>[2] re: <span id="yiv8018064329gmail-m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3866">practical criterion .... That is up to you as a scientist.<br clear="none"><br clear="none">--<br clear="none"></span></div><span id="yiv8018064329gmail-m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3866">Note ncl-talk is not the place to learn about filtering.<br clear="none"><br clear="none"></span></div><span id="yiv8018064329gmail-m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3866">Good luck<br clear="none"></span><div><div><span id="yiv8018064329gmail-m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3866"><br clear="none"><br clear="none"></span></div></div></div><div class="yiv8018064329gmail_extra"><br clear="none"><div class="yiv8018064329gmail_quote">On Tue, Dec 5, 2017 at 9:14 AM, Kiswendsida Hyacinthe GUIGMA <span dir="ltr"><<a rel="nofollow" shape="rect" ymailto="mailto:karongseba@gmail.com" target="_blank" href="mailto:karongseba@gmail.com">karongseba@gmail.com</a>></span> wrote:<br clear="none"><blockquote class="yiv8018064329gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div class="yiv8018064329yqt0581134612" id="yiv8018064329yqt42637"><div><div style="color:#000;background-color:#fff;font-family:verdana, helvetica, sans-serif;font-size:16px;"><div id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3785"><span id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3864">Dear NCL users,</span></div><div dir="ltr" id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3823"><span id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3866">I am very new on NCL and I am trying to filter my rainfall data using Lanczos Filter (bandpass 10-90 day filtering). My question concerns the processing of the weights. I would like to know <br clear="none"></span></div><div dir="ltr" id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3884"><span id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3866">1-is there any relationship between the number of weights to choose and the cutoff frequencies?</span></div><div dir="ltr" id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3929"><span id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3866">2-is there any practical criterion to choose the number of weights? I know that this number influences the loss of data.</span></div><div dir="ltr" id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4139"><span id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3866">Below is my code:</span></div><div dir="ltr" id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4147"><span id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3866"><br clear="none">------------------------------ ------------------------------ ------------------------------ ------------------------------ ------------------------------ ----------------</span></div><div dir="ltr" id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3965"><span id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3866">;import the file<br id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4027" clear="none">gpcp=addfile("gpcp_Sahel.nc"," r")<br id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4028" clear="none">rr=gpcp->precip<br id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4029" clear="none">;filter parameters<br id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4030" clear="none">ihp=2 ;bandpass<br id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4031" clear="none">sigma=1.0 ; Lanczos sigma<br id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4032" clear="none">nWgt = 81 ; number of weights -> means 40 data lost at the beginning and 40 data lost at the end. <br id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4033" clear="none">fca = 1./90. ; start freq ;highpass= 90 days<br id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4034" clear="none">fcb = 1./10. ; last freq; lowpass= 10 days<br id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4035" clear="none">wgt = filwgts_lanczos (nWgt, ihp, fca, fcb, sigma )<br id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4036" clear="none">printVarSummary(wgt)<br id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4037" clear="none">xBPF = wgt_runave_n_Wrap ( rr, wgt, 0, 0) ; 10-90 day bp performed across time dimension(0) of rr (meaning the time dimension)<br id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4038" clear="none"></span></div><div id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3786"><div id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4166"> ----------------------------- ------------------------------ ------------------------------ ------------------------------ ------------------------------ ----------------</div><div id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4167"><br clear="none"></div><div id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4168"><br clear="none"></div><div id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4157"><br clear="none"></div><div id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4158"><br clear="none"></div><div id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4169"><br clear="none"></div><div id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_4170">Cheers,<br clear="none"></div></div><div class="yiv8018064329m_-6632467413770190592signature" id="yiv8018064329m_-6632467413770190592yui_3_16_0_ym19_1_1512489722799_3869"><br clear="none">GUIGMA</div></div></div></div><br clear="none">______________________________ _________________<br clear="none">
ncl-talk mailing list<br clear="none">
<a rel="nofollow" shape="rect" ymailto="mailto:ncl-talk@ucar.edu" target="_blank" href="mailto:ncl-talk@ucar.edu">ncl-talk@ucar.edu</a><br clear="none">
List instructions, subscriber options, unsubscribe:<br clear="none">
<a rel="nofollow" shape="rect" target="_blank" href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk">http://mailman.ucar.edu/ mailman/listinfo/ncl-talk</a><br clear="none">
<br clear="none"></blockquote></div><br clear="none"></div></div></div><br><br></div> </div> </div> </div></div></body></html>