This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
> Full Name: Stefan Cecelski > Email Address: address@hidden > Organization: University of Maryland > Package Version: 2.9u4 build date:2011-06-08 16:06 UTC > Operating System: Mac OS X > Hardware: Java: home: > /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home version: > 1.6.0_24 j3d:1.5.2 fcs (build4) > Description of problem: Hi All, > > Just trying to do a simple Layer Average of Relative Humidity between 600hPa > and 900hPa but keep getting this error: > > Creating display: Color-Shaded Plan View > TypeError: createLayerAverage(): 2nd arg can't be coerced to String, double > org.python.core.PyException > > Not sure what I am doing wrong; I have tried doing it between model pressure > levels as well as model heights. Thanks in advance! > > V/R, > > Stefan > Hi Stefan, I am not clear how you did the layer average. There is a system function named layerAverage(grid, top, bottom), to call this function, you can select, Formula > Grids > Define a grid diagnostic, and select color-shaded plan view, and click create display, a window popup, enter layerAverage(grid, 600, 900), and then another window popup, select the relative humidity. It should work. Otherwise, let me know. Yuan > ****************** > Stack trace: > Traceback (most recent call last): > File "<string>", line 1, in <module> > File "<string>", line 89, in layerAverage > TypeError: createLayerAverage(): 2nd arg can't be coerced to String, double > > > Ticket Details =================== Ticket ID: CHA-486849 Department: Support IDV Priority: Normal Status: Closed