<div dir="ltr"><div><div>Hello,<br><br></div>I can see where the error message came from:<br><br>function reg_multlin_stats(Y[*]:numeric, XP:numeric, opt)<br></div>[SNIP]<br><div>       if (isatt(Y,"_FillValue")  .and. any(ismissing(Y))) then<br>           print("reg_multlin_stats: Y has missing values. Not allowed!")<br>           exit<br>       end if<br></div><div>[SNIP]<br><br></div><div>The documentation for the underlying fortran subroutine says missing values are allowed. So, maybe I should not have that in the NCL interface. The interface subsequently calls:<br><br><a href="https://www.ncl.ucar.edu/Document/Functions/Built-in/reg_multlin.shtml">https://www.ncl.ucar.edu/Document/Functions/Built-in/reg_multlin.shtml</a><br><br>===========================<br><br></div><div>Can you please send a clean, 'minimalistic' script that yields the error message?<br><br></div><div>Small files can be attached to the reply. If the data file is large, please use ftp:<br><br></div><div>ftp <a href="http://ftp.cgd.ucar.edu">ftp.cgd.ucar.edu</a><br></div><div>anonymous<br></div><div>your_email<br></div><div>cd incoming<br></div><div>put ....<br></div><div>put ...<br></div><div>quit<br><br></div><div>After successful transfer, send an email indicating the name(s) of the files.<br><br></div><div>Regards <br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Nov 8, 2017 at 7:10 AM, Andreas Chrysanthou <span dir="ltr"><<a href="mailto:eeac@leeds.ac.uk" target="_blank">eeac@leeds.ac.uk</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">



<div style="word-wrap:break-word">
Hi NCL users,
<div><br>
</div>
<div>I’ve bumped into some missing values in my independent variable while trying to do a multiple linear regression analysis with reg_multin_stats function.</div>
<div><br>
</div>
<div>I want to produce lat/height plots (levxlat) of the predictors for the 31 years of my time series after the MLR as well as look at the Yest from those in terms of its spatial patterns.</div>
<div><br>
</div>
<div>The error I’m getting is <i>"reg_multlin_stats: Y has missing values. Not allowed!”</i></div>
<div><i><br>
</i></div>
<div>PrintVarSummary of the variables I’m using is just below, whereas a snippet of the script is following after that. </div>
<div><br>
</div>
<div>Any ideas on how to get round this problem?</div>
<div><br>
</div>
<div>
<div><i>Variable: WSTAR<br>
Type: float<br>
Number of Dimensions: 4<br>
Dimensions and sizes:<span class="m_1363640846215022689Apple-tab-span" style="white-space:pre-wrap"> </span>
[model | 6] x [year | 31] x [lev | 31] x [lat | 64]</i></div>
<div><i>standardize_op_ncl :<span class="m_1363640846215022689Apple-tab-span" style="white-space:pre-wrap">
</span>dim_standardize_n over dimension(s): year<br>
NCL :<span class="m_1363640846215022689Apple-tab-span" style="white-space:pre-wrap"> </span>month_to_annual<br>
actual_range :<span class="m_1363640846215022689Apple-tab-span" style="white-space:pre-wrap"> </span>( -0.6522911, 1e+20 )</i></div>
<div><i><br>
</i></div>
<div><i><br>
Variable: NIES2<br>
Type: float<br>
Number of Dimensions: 2<br>
Dimensions and sizes:<span class="m_1363640846215022689Apple-tab-span" style="white-space:pre-wrap"> </span>
[year | 31] x [reg_index | 5]<br>
Number Of Attributes: 3<br>
_FillValue :<span class="m_1363640846215022689Apple-tab-span" style="white-space:pre-wrap"> </span>1e+20<br>
NCL :<span class="m_1363640846215022689Apple-tab-span" style="white-space:pre-wrap"> </span>month_to_annual<br>
standardize_op_ncl :<span class="m_1363640846215022689Apple-tab-span" style="white-space:pre-wrap"> </span>
dim_standardize_n over dimension(s): year</i><br>
<br>
</div>
<div><br>
</div>
<div><br>
</div>
<div>
<div>NIES1  = new ( (/5,31/), "float" )  </div>
<div>    NIES1(0,:) = reg(0,{1980:2010},0)</div>
<div>    NIES1(1,:) = reg(0,{1980:2010},1)</div>
<div>    NIES1(2,:) = reg(0,{1980:2010},2)</div>
<div>    NIES1(3,:) = reg(0,{1980:2010},3)</div>
<div>    NIES1(4,:) = reg(0,{1980:2010},4)</div>
<div><br>
</div>
<div>NIES1!0 = "reg_index"</div>
<div>NIES2   = NIES1(year|:,reg_index|:)</div>
</div>
<div><br>
</div>
<div><br>
</div>
<div>
<div>nies = WSTAR(0,:,:,:)</div>
<div>test_ = test(0,:,:)</div>
</div>
<div><br>
</div>
<div>do gg = 0,dimsizes(WS_&lev)-1</div>
<div>    do hh = 0,dimsizes(WS_&lat)-1</div>
<div>        test_(gg,hh) = reg_multlin_stats(nies(:,gg,<wbr>hh),NIES2,0)</div>
<div>    end do</div>
<div>end do</div>
</div>
<div><br>
</div>
<div>Cheers,<br>
<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 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>Andreas</div>
<div>---</div>
<div><br>
</div>
<div></div>
</div>
</div>
</div>
</div>
</div>
</div>
<br>
</div>
</div>

<br>______________________________<wbr>_________________<br>
ncl-talk mailing list<br>
<a href="mailto:ncl-talk@ucar.edu">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/<wbr>mailman/listinfo/ncl-talk</a><br>
<br></blockquote></div><br></div>