Re: retrieve values of NumInBins

From: Liangying Zhang <lzhang_at_nyahnyahspammersnyahnyah>
Date: Wed, 19 Jul 2006 09:07:41 -0600
It worked with Dennis' solution. But I have a panel with 4 plots, which I put them into an array. When I tried
          plot(0) = gsn_histogram(...)
          nBins = plot(0)@NumInBins
I got error message says:   
fatal:syntax error: line 115 in file plot.GPSpw.seasonalerror.ncl before or near @NumInBins
  a = plot(0)@NumInBins
--------------------------------^
It gave me syntax error if I add array index
My solution was to put  nBins = plot@NumInBins  after each plot,  it works ok, but is there any good way to handle this case?

Thanks,
Liz

Dennis Shea wrote:
I believe there is a simple way to retrieve values of attribute 
"NumInBins" from histogram plots. When I just print plot, it only shows
 NumInBins :   <ARRAY>
how to get the exact values?
    

    plot  = gsn_histogram(...)

    nBins = plot@NumInBins
    
good luck
D

  


-- 
***********************
Liangying Zhang
NCAR/ATD
Email: lzhang@ucar.edu
Phone: 303-497-2025
Fax  : 303-497-8770
***********************

_______________________________________________
ncl-talk mailing list
ncl-talk_at_ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Wed Jul 19 2006 - 09:07:41 MDT

This archive was generated by hypermail 2.2.0 : Wed Jul 19 2006 - 09:13:26 MDT