[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

20040323: Creating a vertical profile



>From: "Paul Gifford" <address@hidden>
>Organization: 
>Keywords: 200403230727.i2N7RdrV029998  IDV height profile

Hi Paul-
>
>  Thanks for the prompt reply.  After I wrote my initial e-mail I realized
>the IDV was probably expecting a grid.  I tinkered around a little bit but
>it's late so I won't finish tonight.  Here's where I'm headed, though (code
>snippet below).  Profile is the data type I have to work with that contains
>a lat/lon pair, parameter information, and a series of values mapped to
>heights. In getting a time series to plot (using a similar data structure) I
>mocked up a grid around the point of interest (you can see that commented
>out - the Linear2DSet).  

I thought I remembered that was what you did and suggest the same
thing here.

>I was hoping to do the same thing here but  I
>stopped for now at making a Gridded3DSet.  It's too late to think about
>"manifold dimensions" :)  

It's always too late for that. ;-)

>I was thinking, though, of using the constructor
>that states, "a 3-D set whose topology is a lengthX x lengthY x lengthZ
>grid".  Does it look like I'm on the right path to you?

That is the way I'd go.    What you have below looks good to me.
If you altitude points are linear, you could then use the Linear3DSet.

>***********************
>                FlatField grid = null;
>                Profile profile = (Profile)gran;
>
>                RealType val = RealType.getRealType("value");
>
>                RealTupleType xyz = RealTupleType.LatitudeLongitudeAltitude;
>                FunctionType xyz_val = new FunctionType(xyz, val);
>
>                int size = 9;
>                LatLonPoint llp = profile.getLatLonPoint();
>
>                double lat = llp.getLat();
>                double lon = llp.getLon();
>                if (lon > 180d)
>                    lon -= 360d;
>
>                float[] data =
>GeneralUtilities.getGranuleData(_serverAddrStr, gran.getFdrID(),
>gran.getID());
>
>        /*     Linear2DSet spatialSet = new
>Linear2DSet(RealTupleType.LatitudeLongitudeTuple,
>                lat-.1, lat+.1, 3,  // three so the middle is the data point
>                lon-.1, lon+.1, 3); */
>
>Gridded3DSet spatialSet = new Gridded3DSet(xyz,...etc


Don
NOTE: All email exchanges with Unidata User Support are recorded in the
Unidata inquiry tracking system and then made publically available
through the web.  If you do not want to have your interactions made
available in this way, you must let us know in each email you send to us.