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

[IDV #EKY-504245]: Jython script for 2D plot movie

> Name: Roman Kowch
> E-mail: address@hidden
> Organization: MIT PAOC
> Software Package: IDV 2.7u2
> Operating System: Linux Ubuntu
> Subject: Jython script for 2D plot movie
> Hi,
> I am trying to write a simple script in Jython that commands
> IDV to make a 2D display of potential temperature from a Netcdf
> file and write a movie file. So far, the following code below only seems
> to make the display as if I just selected the potential temperature
> field and hit "Create
> Display" in the interactive mode:
> setOffScreen(1)
> idv.getStateManager().setViewSize(java.awt.Dimension(400,400))
> ds = 
> makeDataSource("/disk7/rkowch/IDV/mitfluids/netcdf/IDVmitmodel2.nc","netcdf.grid")
> a = getData(ds.getName(),"Temp")
> dc = createDisplay('planviewcontourfilled',a)
> pause()

 Hi Roman, 
    please upload this IDVmitmodel2.nc file here:

> dc.setDisplayListTemplate("Potential Temperature 2D plot");
> dc.setColorTableName("default")
> dc.range.set(-50.0,25.0)
> dc.setContourInfoParams("interval=2.0;min=-90.0;max=45.0;base=-230.0")
> dc.applyPreferences();
> writeMovie("2DThetaLoop.mov")
> How could this script be modified to correctly set the display unit
> (e.g. degC, K), color range on the color table, contouring parameters,
> height level, and what times to use (which is specified before you hit
> "Create Display")?
> Could you modify the script above to give an example of how this could
> be done? What commands are commonly used in scripts like this? Also,
> is there a certain order that must be followed when writing the
> commands in the text file?
> I've been looking at the IDV documentation at this website, but
> there's quite a bit
> of info to sort through:
> http://www.unidata.ucar.edu/software/idv/docs/javadoc/
> Thanks for your help,
> Roman

Ticket Details
Ticket ID: EKY-504245
Department: Support IDV
Priority: Normal
Status: Open

NOTE: All email exchanges with Unidata User Support are recorded in the Unidata inquiry tracking system and then made publicly 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.