[ncl-talk] DECADAL SVD

Dennis Shea shea at ucar.edu
Wed Dec 11 10:09:16 MST 2019


The script would require a substantive time investment to understand it.

---

*filwgts_lanczos*
<http://www.ncl.ucar.edu/Document/Functions/Built-in/filwgts_lanczos.shtml>


*---*

*re: "As far I understand Lanczos filter by default replace missing values
with fill value."*.

NCL has a nice feature where upon input if a variable has a missing_value
attribute and no _FillValue attribute, NCL will 'dynamically' add a
_FillValue attribute. I believe that CRU datasets have both _FillValue and
missing_value attributes so this language feature is not applied.

The Lanczos filter only recognizes the _FillValue attribute.

ncl 0>     nwt = 9
ncl 1>     fca = 0.2
ncl 2>     ihp = 0
ncl 3>     nsigma = 1.
ncl 4>     wgt = *filwgts_lanczos* (nwt, ihp, fca, -999., nsigma)
ncl 5>     N = 120
ncl 6>     x = *random_normal*(0,5,N)
ncl 7>     xFilter = *wgt_runave* ( x, wgt, 0 )
ncl 8>     print(x+"   "+xFilter)

(0)     4.35164   *9.96921e+36*
(1)     4.36462   9.96921e+36
(2)     9.73397   9.96921e+36
(3)     4.91265   9.96921e+36
(4)     1.76982   1.85172
(5)     -0.634983   -0.730493
(6)     -4.29466   -0.420796

[SNIP]

(114)   -0.780523   0.369537
(115)   -5.00307   -1.90461
(116)   3.39464   *9.96921e+36*
(117)   -5.93985   9.96921e+36
(118)   -1.86471   9.96921e+36
(119)   -2.42371   9.96921e+36

So the beginning and ending (nwgt/2=4) of the filtered series are padded
with _FillValue.

Since NCL's SVD does not allow _FillValue, you must input just the temporal
segment that has no _FillValue.

===========

*PLEASE NOTE: * Cherry (1996) discusses Singular Value Decomposition (SVD)
and Canonical Correlation Analysis (CCA). Cherry's summary comment is:
"Both methods have a high potential to produce spurious spatial patterns.
Caution is always called for in interpreting results from either method."
Newman and Sardeshmukh (1995) came to a similar conclusion in their paper
which focused on SVD: "These results suggest that any physical
interpretation of SVD pairs may be unjustified."

*REFERENCES:*

Cherry, S. (1996):  *Singular Value Decomposition Analysis and
Canonical Correlation Analysis*
<https://doi.org/10.1175/1520-0442(1996)009<2003:SVDAAC>2.0.CO;2>.
J. Climate: pp 2003-2009.

Newman, M. and Sardeshmukh, P.D. (1995): *A Caveat Concerning Singular
Value Decomposition*
<https://doi.org/10.1175/1520-0442(1995)008<0352:ACCSVD>2.0.CO;2>
J. Climate: pp 352-360.


On Wed, Dec 11, 2019 at 5:44 AM dickson mbigi via ncl-talk <
ncl-talk at ucar.edu> wrote:

> Dear concerned expert(s),
>
> I am running decadal SVD between rainfall and SST. The script (attached)
> works well without filtering(smoothing) but once Lanczos low pass filter is
> applied I get the following error.  The problem occur in the place of
> dealing with missing values because the variable NMS1 has  [1]dimensions
> and  sizes . Without filtering NMS1 had [657].  As far I understand Lanczos
> filter by default replace missing values with fill value. Could be that be
> the reason and if that is the case how could I run the SVD without the
> aspect of missing values?
>
> Any help/guidance will highly be appreciated.
>
>
>
> [image: image.png]
>
> Regards,
>
> Dickson Mbigi,
>
> Institute of Atmospheric Physics,
>
> University of Chinese Academy of Sciences,
>
> Beijing, China.
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20191211/a80a1645/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image.png
Type: image/png
Size: 34054 bytes
Desc: not available
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20191211/a80a1645/attachment.png>


More information about the ncl-talk mailing list