Betsy:

Chris indicated how you could use Construct as I implied in my earlier
e-mail in order to get things regular.  I'm sorry that I didn't give the
explicit details.  (Thanks, Chris.)

What Chris suggests is useful for atmospheric models or other gridded data
where you may be topologically regular, but geometrically regular in only 1
or 2 dimensions.  The easiest way to do this is at Import time.  It can be
done with the native format but there are also conventions described in the
user's guide for doing it with general array and netCDF import.  There are
some convoluted ways to do this in the VPE...




Chris Pelkie <[EMAIL PROTECTED]>@opendx.watson.ibm.com on 08/23/2000
11:50:34 AM

Please respond to [email protected]

Sent by:  [EMAIL PROTECTED]


To:   [email protected]
cc:
Subject:  Re: [opendx-users] why is data irregular?



>Lloyd,
>
>Thanks for the reply.
>
>The situation I described (using Compute to shift the Z  position) was
just a
>sample test case.
>I'm trying to use your ConvertToCellCentered macro on my data which is
>regular in x and y, but delta z varies. You had suggested in an earlier
>e-mail that I use Slice to create a set of horizontal slices as a series
>group. Then do a ForEachMember loop for each member of the series and use
the
>macro and accumulate the results in a new series. Then, use Stack to
recreate
>the volume.
>
>However, DX doesn't think the slices are regular so ConvertToCellCentered
>doesn't work. I have imported the data from a netCDF file and do not alter
>the data at all before I create the series of Slices.
>
>Am I just out of luck on this, or do you have any suggestions.
>
>Thanks...Betsy


If you say your data is regular in XY but DX thinks it is not, you can use
Inquire to find out the value of X and of Y (check Inquire's contextual
Help for the syntax, "grid counts", I think). Use this as input to
Construct to manufacture a generic grid of XxY. Then Replace your data
array (and any other dependent arrays, using more than one Replace in
serial) onto this grid. NOW, DX will think your XY slice is regular and you
can make the series and Stack.

BTW, you can also investigate making a semi-regular grid using "product
array" but this can only be done by defining a DX input file, not within
the DX visual programming environment to the best of my knowledge. This is
more advanced but might be useful sometime. I've done this for USGS since
both their X and Y and Z were "irregular" but the stacked set was
conceptually "regular" topologically (just not position-wise). So we
multiply a vector of X positions by a vector of Y positions to make a
semi-regular XY mesh, then by Z to make a semi-regular volume mesh (this is
done in a .dx file then imported). Given a separately imported fully
regular data array of size XxYxZ, one can then simply Replace the data onto
this mesh.

Chris Pelkie
Vice President/Scientific Visualization Producer
Conceptual Reality Presentations, Inc.
30 West Meadow Drive
Ithaca, NY 14850
[EMAIL PROTECTED]
(607) 257-8335 or (607) 254-8794




Reply via email to