This webpage contains the Matlab code written by members of the GFDex project team. Some of the code is designed for basic visualisation of limited area model output from the UM 6.1. Thanks to Ian Renfrew, Jeff Chagnon, Nina Petersen, Dave Sproson and Stephen Outten for help. The code may be updated from time to time. If you have any interesting comments, then please get in touch. Do not expect to use this code without making personal adjustments. Note: some utility and bulk flux matlab code is available on Ian's website. Have fun!
Code |
Description |
|
Comments |
| flighttrack.m |
Allows you to colour any variable from the FAAM core netcdf data file along the flighttrack, and/or vector any two variables along the flighttrack. In addition AVHRR data can be coloured if available. (example)
|
|
This code requires arrow.m available from the Mathworks website.
Written by Dave Sproson.
|
| gfd_ds_read_grid.m |
Reads in dropsondes in netcdf format and interpolates them vertically and horizontally to create gridded variables in height and distance coordinates.
|
|
Written by Stephen Outten and Ian Renfrew |
| gfd_ds_slice_plot |
Reads in matlab files from gfd_ds_read_grid and contours a cross-section of a variable against distance and height. Locations of dropsondes added to top. |
|
Written by Stephen Outten and Ian Renfrew |
| gfd_core_read.m |
Reads core flight-level data in netCDF format using snctools nc_varget reads cloud-physics flight-level data in netCDF format saves a 1Hz data set and a smaller 32 Hz data set in Matlab format Note: variables have dimension: n x 1 (or n x 32, for 32 Hz). |
|
The gfd_core_read script should be run first to generate a 1Hz and 32Hz
data set. These can then be easily and quickly loaded as mat files. The
variable names don't have a suffix if 1Hz (default) and have a suffix
*_32hz if 32Hz.
Note: This code requires snctools and mexnc to be installed. It also requires naninterp.m from the Mathworks website. |
| gfd_flightlevel_diagnostics.m |
Calculates number of diagnostics for matlab-formatted core data use after gfd_core_read or load relevant .mat file. |
|
The gfd_flightlevel_diagnostics script should then be run to calculate a
load of extra diagnostics (thermodynamic variables, surface fluxes,
etc). Note: these two scripts don't need to be re-run (unless you find
you want to add other variables). |
| gfd_run_plot.m |
plots variables versus distance for a flight-level run calls gfd_flightlevel_set_variables.m. |
|
The gfd_run_plot script can then be used to read in the .mat file and
plot runs of flight-level data. Several lines can be plotted in each
panel, and either one or two axes can be set on each panel. Default is 4
panels per page. Default is to plot variable against distance. Note:
variables you will commonly want to change are highlighted via ***. |
| gfd_profile_plot.m |
Plots variables versus height for a profile calls gfd_flightlevel_set_variables.m. |
|
The gfd_profile_plot script is similar to the above, but plots variable
versus height for a flight-level profile. Several lines can be plotted
but only against one x-axis (at the moment). Note: variables you will commonly want to change are highlighted via ***. |
| gfd_flightlevel_set_variables.m |
Sets variables, names and axes limits for plotting called from: gfd_run_plot or gfd_profile_plot. |
|
The gfd_flightlevel_set_variables script simply sets the variable, its
name and axes and tick limits, via the index i. As this code is long and
common to both gfd_run_plot and gfd_profile_plot, I put it in a separate
file. |
| egm96_correct.m |
This code corrects the GPS altitude when the radar altitude is unavailable. |
|
This code requires the egm96_na.mat data file. |
| egm96_na.mat |
The .mat is generated from the WGS 84 EGM96 15-Minute Geoid (tide free) -- http://earth-info.nga.mil/GandG/wgs84/gravitymod/egm96/egm96.html and covers all of the flight tracks. |
|
This is required by the egm96_correct.m code above. |
| gc_dist.mat |
Returns the cumulative great circle distance from a series of ([lon] [lat]). Units will be in units of R (currently km) |
|
|
| qscat_daily_m_plot.m |
Code to read and plot QuikSCAT gridded data in matlab format |
|
Written by Ian Renfrew |
| |
|
|
|