Weather and Climate Prediction
Basic Suggestions For Everyone

0. Editing

To edit a file, use pico, emacs, gedit, vi, etc. Do not use microsoft word. If you are unfamiliar with how to do this, go to a Shell-Konsole window and type, emacs &  and a window will open where you can open files and edit them.

1. Look at your data in matlab quickly

You can have a quick look at your output at any time after the model produces at least one history file (filename with cam2.h0 in it). Get into your run directory and open matlab and use roughly these commands (but use your actual casename):


2. To see what variables are available to view

On the unix command line from your run directory (fill in with your actual casename):

ncdump -h | more
ncdump -h > header

The first one will echo the results to the screen where you will have to hit return or space bar to move through the file. The second will put the information in a file named header, which will you subsequently need to open with a text editor to view.

3. Make a zillion figures at once and post them on the web

First make a directory to copy the script to it:

mkdir /home/disk/p/atms380/$LOGNAME/camruns/camdiags
/home/disk/p/atms380/scripts/diags.csh .

You will have to customize the script using a text editor. Open the script and it will guide you. You must have the history files in the correct directories and for the years that you specify in the script, otherwise it will die quickly with an error message. You can run it ON THE UNIX COMMAND LINE by typing (or whatever you named it)

If running it returns permission denied. You can fix this by typing (or whatever you named it):
chmod 744 diag.csh

If all goes well, it should take ~10 min to run. If it takes 30 sec, something went wrong. It should say things like "ALL ---- FILES FOUND" and "COMPUTING CNTL CASE ANNUAL AVERAGES". If can't find files, it will die without getting anywhere. Ask Cecilia for help.

After getting through the phase of computing the climatologies, it will echo a lot of text to the terminal. This will include "fatal" errors that are not actually fatal at all. If it is still spewing text, it is still running. This is good, even if the text seems bad.

When it finishes correctly, the last thing it echos is:


Move the tarfile and make the plots viewable with:
ls *.tar  
mv myfilename.tar ~/public_html
cd ~/public_html
tar xvf myfilename.tar

The figures will be available shortly at the web address below where the filename is your tarfile name minus the ".tar".

4. Unix command line tool to operate on netcdf files. These are part of the NCO package

ncrcat -v TS b30.004.cam2.h0.*
ncra -v TS b30.004.cam2.h0.*

Return to Homepage