Unidata - To provide the data services, tools, and cyberinfrastructure leadership that advance Earth system science, enhance educational opportunities, and broaden participation. Unidata
         
  advanced  
 

Reversing Axes in 2D plots

Hello, all.

I have a 2D data set (pressure versus temperature), which I wish to display with pressure on the Y-Axis. Using the obvious

            myDisplay.addMap(new ScalarMap(myRangeType, Display.XAxis));
myDisplay.addMap(new ScalarMap((RealType), myDomainType.getComponent(0),Display.YAxis));

produces almost what I want: at the origin, the pressure coordinate has the lowest value in the data set, and at the top, it has the highest.

This is certainly the expected behavior for a generic data set, but it is a trifle unphysical in reference to an atmosphere, where the highest pressures occur at the "lowest" point.

Is there any obvious way to invert the scales of a scalar map? I didn't see one in the javadoc, but that doesn't mean it isn't there.

        Edward


 
 
  Contact Us     Site Map     Search     Terms and Conditions     Privacy Policy     Participation Policy
 
National Science Foundation (NSF) UCAR Community Programs   Unidata is a member of the UCAR Community Programs, is managed by the University Corporation for Atmospheric Research, and is sponsored by the National Science Foundation.
P.O. Box 3000     Boulder, CO 80307-3000 USA     Tel: 303-497-8643     Fax: 303-497-8690