[ncl-talk] text res

Geeta Geeta geetag54 at yahoo.com
Mon Oct 19 11:02:22 MDT 2015


 Hi Mary. 
I have tried three things for giving a range to the rainfall. Pls see the lines 91 to 110 of my script. 



1.  I tried the following. 

1. print(nrf)
     92   colors = where(((rf.ge.0.1).and.(rf.lt.2.5)),"Blue","   ")  ; This is a string variable
     93   colors = where(((rf.ge.2.5).and.(rf.lt.7.5)),"Red","   ")
     94 ;  colors = where(((rf.ge.7.5).and.(rf.lt.15.5)),"Yellow","   ")
     95 ;  colorss= stringtoint(colors)
     
2nd Method in which I have defined the colors as an array. So there is error on line 106. Also this will give an individual color to each data. 
Variable: colors
Type: integer
Total Size: 16 bytes
            4 values
Number of Dimensions: 1
Dimensions and sizes:    [4]
Coordinates: 
(0)    1
(1)    21
(2)    41
(3)    61
fatal:Subscript out of range, error in subscript #0
fatal:An error occurred reading colors
fatal:["Execute.c":8578]:Execute: Error occurred at or near line 106 in file stn-v3.ncl

aditya at agniilap:~/geeta/ncl$ 

can U pls suggest???I also tried combining two statements with where but that did not work. 
 Geeta. 

Geeta.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20151019/4be7555b/attachment.html 


More information about the ncl-talk mailing list