Log In | Users | Register
Edit | Attach | New | Raw | Diff | Print | | Tools
You are here: Data » DocTools » ncview

NCVIEW - The quickest way to your model output

NCVIEW is a very handy tool to get a quick look at your model output. While most other products such as MATLAB or IDL require that you perform rather costly read-in routines for your NETCDF-data before plotting, NCVIEW shows you plots for 2D- and 3D-fields almost immediately. In accordance with the speed at which you get a look of your results with NCVIEW, this guide through the application is kept as short as possible.

If available on your machine or network, all you need to do is enter

ncview >path of your netcdf-file<, e.g. ncview /home/johnny/whattheheckisthatsupposedtosay.nc

on the command line. It's as simple as that. Nonetheless, let's make a little example. Once the ncview command has been executed, the grafic interface appears. It will most probably look kinda like this:


Now, select the variable you want to look at from the pop-up menus (e.g. 2d vars). The number behind >2d vars< tells you how many variables with 2 dimensions there are. The result may look as follows:


In this case, large-scale rainfall from a 12 km COSMO-CLM simulation is shown as you can see in the title of the NCVIEW main window. The next lines provide you with time range of the displayed field and the data range with units. The fourth line shows information (coordinates and data) on a current data point. Moving your cursor over the displayed field allows you to see the exact values at a the point of the cursor. At the bottom of the main window you find information on the output grid (longitude and latitudes) as well as the time step. Depending on the definition of time in the netcdf-file, you may find a huge number representing "seconds since 1900-01-01 00:00:00" or something a bit more handsome.

The problem with precipitation is that it's usually a very non-linear field, meaning that you may have a lot of spots or larger areas with very little precipitation and a few rare grid points that received a lot of water at that point in time. As all the places with little precipitation are hidden in the blue, you can make them more accessible by changing the color scale from Linear to High (emphasizing high values) or Low (highlighting low values). Here, it makes sense to switch to "Low":


such that the new plot is as follows:


The given plot is smoothed with a bi-linear interpolation. If you want to see the rough grid structure, switch from "Bi-Lin" to "Repl". If you want a bigger or a larger picture, change from "MX2" to "MX1" for a smaller picture (right mouse button) or to "MX3" or 4 or 5 for a larger picture (left mouse button). If you want, you can also change the color table (first button from the left on main window) and inverse it ("Inv C") or the whole plot ("Inv P").

Under "Opts", you may add or remove coastlines. Under "Print", you can print the figure as a postscript.

Animations with ncview. Yes, even that can be done. If you have a time series, click the ">",">>" or "<","<<" buttons to see all the time frames in a row. There is a lever that determines the animation speed (right of "Delay:").

That's about it. Please note that you can click through 3d-fields easily from level to level or through time if your netcdf-file contains more than one timestep. Oh, no. I almost forgot that despite all the doxology, I should mention caveats or short-comings, too. There is mainly one of the latter. When changing the data range (button "Range"), your mouse cursor needs to be within the text field in which you want to make changes.

Well, then. Have fun, earthling!

ncv1.png (17.15K)
version 1 uploaded by EliasZubler on 11 Aug 2011 - 13:45
ncv2.png (167.89K)
version 1 uploaded by EliasZubler on 11 Aug 2011 - 13:50
ncv3.png (1.08K)
version 1 uploaded by EliasZubler on 11 Aug 2011 - 14:03
ncv4.png (278.80K)
version 1 uploaded by EliasZubler on 11 Aug 2011 - 14:03
This site is managed by the Center for Climate Systems Modeling (C2SM).
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors. Ideas, requests, problems? Send feedback!