Re: Composites

From: Dennis Shea <shea_at_nyahnyahspammersnyahnyah>
Date: Wed May 15 2013 - 09:25:32 MDT

   ipos = ind(pos) ; index (subscripts) values where pos=True

   f = addfile("...", "r")
   x = f->X(ipos,:,:)
   printVarSummary(x)

or, if X exist

   x = X(ipos,:,:) ; (time,lat,lon) ... (0,1,2)

   xComp = dim_avg_Wrap(x, 0) ; average selected 'time'
   printVarSummary(xComp)

or, do it directly

   xComp = dim_avg_Wrap(X(ipos,:,:), 0) ; average selected 'time'

Good Luck

On 5/15/13 8:54 AM, Nkese Mc Shine wrote:
> Dear All,
>
> I am trying to make composites of precipitation. I calculated sigma and I wanted to know the years that had values which were greater than or equal to sigma. However I want to compile only the years that have "True". These will then be used to make composites for the same period for wind. Can anyone help me?
>
>
> ; positive composites
> pos = precipJJA.ge.possigma
> printVarSummary(pos)
> print(precipJJA&time+" "+pos)
>
> Variable: pos
> Type: logical
> Total Size: 244 bytes
> 61 values
> Number of Dimensions: 1
> Dimensions and sizes: [61]
> Coordinates:
> Number Of Attributes: 1
> _FillValue : Missing
> (0) 194607 True
> (1) 194707 False
> (2) 194807 True
> (3) 194907 True
> (4) 195007 True
> (5) 195107 True
> (6) 195207 False
> (7) 195307 False
> (8) 195407 False
> (9) 195507 True
> (10) 195607 False
> (11) 195707 False
> (12) 195807 True
> (13) 195907 False
> (14) 196007 False
> (15) 196107 False
> (16) 196207 False
> (17) 196307 False
> (18) 196407 True
> (19) 196507 False
> (20) 196607 False
> (21) 196707 False
> (22) 196807 False
> (23) 196907 True
> (24) 197007 True
> (25) 197107 False
> (26) 197207 False
> (27) 197307 False
> (28) 197407 False
> (29) 197507 False
> (30) 197607 False
> (31) 197707 False
> (32) 197807 False
> (33) 197907 True
> (34) 198007 False
> (35) 198107 False
> (36) 198207 False
> (37) 198307 False
> (38) 198407 True
> (39) 198507 False
> (40) 198607 False
> (41) 198707 False
> (42) 198807 False
> (43) 198907 False
> (44) 199007 False
> (45) 199107 False
> (46) 199207 False
> (47) 199307 False
> (48) 199407 False
> (49) 199507 False
> (50) 199607 False
> (51) 199707 False
> (52) 199807 True
> (53) 199907 False
> (54) 200007 False
> (55) 200107 False
> (56) 200207 False
> (57) 200307 False
> (58) 200407 False
> (59) 200507 False
> (60) 200607 True
>
> Regards,
> Nkese.
>
>
>
> CONFIDENTIALITY: This email (including any attachments) may contain confidential, proprietary and/or privileged information. Any duplication, copying, distribution, dissemination, transmission, disclosure or use in any manner of this email (including any attachments) without the authorisation of the sender is strictly prohibited. If you receive this email (including any attachments) in error, please notify the sender and delete this email (including any attachments) from your system. Thank you.
>
>
>
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Wed May 15 09:25:37 2013

This archive was generated by hypermail 2.1.8 : Wed May 15 2013 - 10:19:28 MDT