contourPlot with non-equal interval grid data

From: p yg (pyg_1 AT hotmail.com)
Date: Sat Mar 19 2005 - 05:31:30 MST


Good everyone,

  I have make a contourPlot with Irregular grid data, in Y axis are:
    
     10
     15
     20
     22
     24
    
in other word, in Y axis, the interval is 5 from 10 to 20, while the
interval is 2 from 20 to 24.

X axis are:
     0 10 20 30 40

As above, my data is not equal interval in Y axis, but I have gotten the
equal interval contour graph. Why?
How to get the right one?

My code in HLU C:
  
  icount[0] = 5;
  icount[1] = 5;
  NhlRLSetMDFloatArray(srlist,NhlNsfDataArray,&data[0][0],2,icount);
  
   NhlRLSetFloat(srlist,NhlNsfXCStartV, 0);
   NhlRLSetFloat(srlist,NhlNsfXCEndV, 40);

  NhlRLSetFloat(srlist,NhlNsfYCStartV, 10);
  NhlRLSetFloat(srlist,NhlNsfYCEndV, 24);
 
  NhlCreate(&cndata,"cndata",NhlscalarFieldClass,appid,srlist);
  ...
  NhlRLSetInteger(srlist,NhlNcnScalarFieldData,cndata);

For example, data[5][5] = { 10, 10, 10, 10, 10,
                        20, 20, 20, 20, 20,
                        30, 30, 30, 30, 30,
                        40, 40, 40, 40, 40,
                        50, 50, 50, 50, 50 }

The above code get the graph with equal interval in Y axis as blow:
    50 50 50 50 50
    .
    .
    .
    40 40 40 40 40
    .
    .
    .
    30 30 30 30 30
    .
    .
    .
    20 20 20 20 20
    .
    .
    .
    10 10 10 10 10

but I want get the graph with non-equal interval graph as blow:
The right graph is :
    50 50 50 50 50
    .
    .
    40 40 40 40 40
    .
    .
    30 30 30 30 30
    .
    .
    .
    .
    .
    20 20 20 20 20
    .
    .
    .
    .
    .
    10 10 10 10 10

How to write the code? Thanks.

_________________________________________________________________
Ãâ·ÑÏÂÔØ MSN Explorer: http://explorer.msn.com/lccn/

_______________________________________________
ncarg-talk mailing list
ncarg-talk AT unknown
http://mailman.ucar.edu/mailman/listinfo/ncarg-talk



This archive was generated by hypermail 2b29 : Sun Mar 20 2005 - 13:30:31 MST