unexpected behavior for ind

From: Joel Norris <jnorris_at_nyahnyahspammersnyahnyah>
Date: Fri Feb 26 2010 - 21:08:44 MST

I'd like to use "ind" to find data that does not have a particular value
or is missing, but it unexpectedly does not return the indices of missing
data.

Here's a short sample script.

 Copyright (C) 1995-2009 - All Rights Reserved
 University Corporation for Atmospheric Research
 NCAR Command Language Version 5.1.1
 The use of this software is governed by a License Agreement.
 See http://www.ncl.ucar.edu/ for more details.
ncl 0> a = (/10,20,30,-999/)
ncl 1> a@_FillValue = -999
ncl 2> print(ind(a.ne.10))
(0) 1
(1) 2
ncl 3> print(ind(ismissing(a)))
(0) 3
ncl 4> print(ind(a.ne.10.or.ismissing(a)))
(0) 1
(1) 2

Why doesn't "ind" return 1, 2, and 3?

Joel

-- 
Joel Norris       Associate Professor of Climate and Atmospheric Sciences
Scripps Institution of Oceanography     email: jnorris@ucsd.edu
University of California, San Diego       phone: (858) 822-4420
9500 Gilman Drive DEPT 0224             fax: (858) 534-8561
La Jolla, CA 92093-0224                     http://meteora.ucsd.edu/~jnorris/
Delivery Address:   Scripps Institution of Oceanography
                           8810 Shellback Way
                           Room 440, Nierenberg Hall
                           La Jolla, CA 92037
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Fri Feb 26 21:08:55 2010

This archive was generated by hypermail 2.1.8 : Mon Mar 01 2010 - 08:49:37 MST