STATLOG
Sections
NAME
statlog - Surface meteogram plotting program
SYNOPSIS
statlog [parameters...] filename
PARAMETERS
Command Line | Resource | Default | Description |
-h | help | No | Lists basic help information. |
-df=filename | default | .wxpdef | Sets the name of the resource file. |
-na=name | name | statlog | Specifies the name used in resource file parsing. |
-ba | batch | No | Run program in batch mode |
-me=level | message | out2 | Specifies level of messages to be displayed
|
-fp=filepath | file_path | current directory | Specifies location of database files. |
-dp=datapath | data_path | current directory | Specifies the location (path) of the input raw data files. This may be modified in the name convention file. |
-cp=conpath | con_path | current directory | Specifies the location (path) of the input surface converted data files. This may be modified in the name convention file. |
-rp=rawpath | raw_path | current directory | Specifies the location of the output raw files generated by the program. These files will not be generated unless the out_file resource is specified and the output is plotted data. |
-gp=gridpath | grid_path | current directory | Specifies the location of the output grid files generated by the program. These files are not generated unless the out_file resource is specified and the output is a gridded field. |
-ip=imagepath | image_path | current directory | Specifies the default location of the output GIF images generated by the program. |
-nc=name_conv | name_conv | name_conv | The name convention file specifies how files are named in WXP. This sets which name convention file to use. |
-if=in_file | in_file | sfc_cvt (for sfc data) mos_dat (for MOS data) |
Specifies the input file name tag. The default is sfc_cvt, but it can be modified to any value in the filename convention file. A full name convention can be specified as well. |
-mo=model | model | sfc | The type of data to use in the plot:
|
-cu=[hour|la] | current | None | This specifies to use current data files. The current filename is based on the name convention. An optional hour can be specified for older data. If la is specified, the program will search back to find the most recent available file. |
-ho=hour | hour | None | This resource specifies the exact hour that a data file is valid for. This locks in the start hour for a multi-file sequence. |
-nh=num_hour | num_hour | -12 | This specifies the number of hours that will be used in the plot. If this is not specified, 12 hours of data will plot. This is ignored for MOS data. |
-id=identifier | identifier | None User prompt |
Specifies the station to use in plotting data. |
-va=variable | variable | User prompt Batch: first variable listed in the statlog.var file |
This specifies the variable to plot along with its formatting attributes. Multiple variables can be specified separated by commas for overlay plots. A list of valid variables is given below. |
-sc=scale_factor | plot_scale | 1.0 | Specifies a scaling factor for all plotted text, symbols, vectors, etc. |
-fm=format | plot_format | None | Specifies the output format of the plots. This is generally used to specify how many decimal places get displayed on the plot and in the output raw files. |
-pp=param[,param...] | plot_param | None | Specifies additional plotting parameters. See the plot_param resource for more details. |
-dr=drawable[,...] | draw | all | Specifies which part of the plot is to be drawn. |
-la=label[,...] | label | Program defaults | Specifies the labels to be plotted around the plot. By default, labels are generated by the program and plotted above and below the plot. This resource overrides these labels. |
-fl=font_list | font_list | modern.fnt | Specifies a list of fonts to use in the plots. |
-ct=color_table | color_table | wxp.clr | Specifies the color table to use in the plot. This maps color names to actual RGB color values. |
-cot=color[:attr] | color_text | white black for inverse plots. |
Specifies the text color for labels above and below the plot. |
-cod=color[:attr] | color_data | green | Specifies the color for plotted data. |
-cogr=color[:attr] | color_grid | red | Specifies the color for background grids. |
-cowd=color[:attr] | color_wind | white black for inverse plots. |
Specifies the color for wind barbs. |
-cocd=color[:attr] | color_cloud | white black for inverse plots. |
Specifies the color for cloud cover symbols. |
-cowx=color[:attr] | color_wx | yellow brown for inverse plots |
Specifies the color for weather symbols |
-de=device[,...] | device | User prompt Batch: display |
Specifies the output device. |
-ti=title | title | Program name | Specifies the window title. |
-ic | icon | Off | Specifies whether to open window in iconified mode. |
-bg=color | background | black white for inverse plots |
Specifies the background color of the window. |
-ge=geometry | geometry | 640x480 | Specifies the window and paper geometry. |
filename[#seq] | filename | None User Pompt Batch: current=la |
The name of the surface converted data file to be plotted. An optional sequence number can be added to designate the time for non-WXP files. |
DESCRIPTION
This program plots a time series of surface data on a meteogram. The input to the program is either a surface converted file produced by either the sacvt or smcvt programs or NGM MOS data. Then, based on a variable selected by the user, a plot is generated.
Surface Data Meteogram
The surface data meteogram will plot a time series of data. The number of hours is based on the num_hour resource. The default is 12 hours but often 24 hours is used.
The programs starts off by prompting the user for input converted file name. The user may specify the input file either via the command line of through the current resource. The input naming convention is specified by the sfc_cvt tag but this can be changed with the in_file resource.
Next, the program prompts the user for the station identifier to use in the plot.
The program will now prompt the user for the particular output variable to plot. Even though a meteogram is considered to be a set of plots, there is the ability to plot individual variables versus time. The program will show a menu of commonly used variables but many more are defined internally by the program and in the statlog.var file. The internal variables are:
Variable | Description and units | Plots |
temp | Temperature (F) | value |
dewp | Dewpoint (F) | value |
dewd | Dewpoint depression (F) | value |
wdir | Wind direction (deg) | value |
wspd | Wind speed (knt) | value |
wgst | Wind gust (knt) (not in MOS) | value |
wbrbc wbrb wind |
Wind speed and direction (knt) | value0=dir, value1=spd |
uwnd | U wind component - EW relative (m/s) | value |
vwnd | V wind component - NS relative (m/s) | value |
uwndg | U wind component - grid relative (m/s) | value |
vwndg | V wind component - grid relative (m/s) | value |
alt | Altimeter setting (in_Hg) (not in MOS) | value |
pres | Sea level pressure (mb) use level parameter to get station/surface pressure | value |
pralt | Sea level pressure or altimeter setting if sea level pressure is missing (mb) | value |
elev | Station elevation (m) | value |
wx | Present weather (SAO string) | string |
vis | Visibility (mi) | value, formatted string |
cldcl | Cloud ceiling (100 ft) | value, formatted string |
cldclc | Cloud ceiling code (from synoptic code 0-9) | value |
cldcv | Cloud cover (cloud string) | value=%, string |
ptend | Pressure tendency (mb, trend is a string) (not in MOS) | value, string=trend code |
prec | Precipitation (in) use time parameter to specify which type (3,6,12,24 hour) | value |
extt | Extreme temperature (F) uses maximum if available, else minimum. Use time parameter to specify which type (6,24 hour) |
value |
maxt | Maxmium temperature (F) use time parameter to specify which type (6,24 hour) | value |
mint | Minimum temperature (F) use time parameter to specify which type (6,24 hour) | value |
snwdp | Snow depth (in) | value |
nlcld | Amount of low clouds (code string) | value=%, string=code |
lcld | Low cloud type (not in MOS) | string |
mcld | Middle cloud type (not in MOS) | string |
hcld | High cloud type (not in MOS) | string |
solar | Equivalent solar radiation (min) (not in MOS) | value |
sst | Sea surface temperature (C) (not in MOS) | value |
wavper | Wave period (sec) (not in MOS) | value |
wavhgt | Wave height (m) (not in MOS) | value |
vpres | Vapor pressure (mb) (not in MOS) | value |
svpres | Saturation vapor pressure (mb) (not in MOS) | value |
wchilt | Wind chill temperature (K) | value |
wchilf | Wind chill factor (W/m^2) | value |
heat | Heat index (K) | value |
humit | Humiture (F) | value |
mrat | Mixing ratio (g/kg) | value |
smrat | Saturation mixing ration (g/kg) | value |
shum | Specific humidity (g/kg) | value |
rhum | Relative humidity (%) | value |
wetblb | Wetbulb temperature (K) | value |
thetaw | Wetbulb potential temperature (K) | value |
thetae | Equivalent potential temperature (K) | value |
thetav | Virtual potential temperature (K) | value |
theta | Potential temperature (K) | value |
vtemp | Virtual temperature (K) | value |
fr | Flight rules (number and string: 0=VFR, 1=MVFR, 2=IFR) | value=0, string=VFR value=1, string=MVFR value=2, string=IFR |
These parameters can be accessed by name if they have not been redefined in the statlog.var file. Otherwise, prepending a "+" to the variable name will guarantee these variables will appear.
There are several derived variables from this list which are defined in the statlog.var file. These include composite plots, overlay plots and computed grids.
Variable | Description | Plots |
all | All data, a composite plot of temperature, dewpoint, sea level pressure, cloud cover, winds and present weather. | comp |
allc | Same as all except temperatures in celcius. | comp |
Once the variable is selected, the program will open and search through the set of hourly files to get all the data for the time series plot. A table of information for the station over the requested hours will print:
Data for KIND from 1200Z 3 OCT 97 to 0000Z 4 OCT 97 ID TIME T TD RH DIR SPD GST ALT SLP VIS CIL COV WX MAX MIN PR6 PR24 SC KIND 1156 55 51 87 180 6 993 133 10 180 SCT 58 55 KIND 1256 59 53 81 200 8 993 134 10 210 SCT KIND 1356 64 54 70 220 13 994 135 10 230 FEW KIND 1456 69 55 61 210 12 993 131 10 230 FEW KIND 1556 73 56 55 210 13 991 125 10 230 FEW KIND 1656 76 57 52 220 11 991 123 10 230 FEW KIND 1756 78 58 50 210 10 989 118 10 CLR 79 55 KIND 1856 81 59 47 210 11 21 987 109 10 CLR KIND 1956 82 60 48 210 14 20 985 104 10 CLR KIND 2056 82 60 48 210 14 985 101 10 CLR KIND 2156 81 60 49 220 13 985 102 10 250 FEW KIND 2256 77 60 56 220 8 986 106 10 85 FEW KIND 2356 74 61 64 180 8 987 111 10 85 FEW 82 74
The program will now open the graphics window and start processing the data. The user will be prompted for the output device. Then the meteogram will be plotted. For the all data plot, this is a composite of various plots:
- TEMP - temperature and dewpoint chart: This shows temperature as the top line and dewpoint as the bottom line.
- EXTT - extreme temperature: The maximum or minimum temperatures are plotted below the chart at specific reporting times. 12Z and 18Z are generally low temperatures and 0Z and 6Z are high temperatures.
- WX - present weather data: This shows the present weather plotted as a weather symbol.
- SNOW - snow cover: This shows reported snow cover in inches.
- PREC - precipitation: This shows precipitation totals in inches. The values are 24 hour totals generally at 12Z, 6 hour totals at 0Z, 6Z and 18Z, 3 hour totals elsewhere.
- VIS - visibility: This shows the horizontal visibility in miles.
- WGST - wind gusts: This reports wind gusts in knots if reported.
- WIND - winds and cloud cover: This plots the standard wind barb and cloud cover symbol. Up is north.
- CLD - Cloud chart: This chart gives cloud layer information. The vertical axis is a logarithmic scale of the cloud base height in feet ranging from the 100 to 50,000 feet. Each cloud layer base is plotted as horizontal lines. Clear skies are plotted as a 'C'. Scattered cloud layers (1/8th to 3/8th coverage) are plotted as a single short dash "-". Broken cloud layers (4/8th to 7/8th coverage) are plotted as two short dashes "- -". Overcast layers are plotted as a single long dash "---". The actual cloud ceiling is displayed below the chart in 100s of feet if the ceiling is below 10,000 feet.
- PRALT - Pressure chart: This chart plots sea level pressure (or altimeter setting if pressure not reported) in millibars.
- Time: This is the report hour in universal time. The actual time range is displayed above the plot.
When the plot is complete, output can be saved to a GIF image file, spooled to the printer or the plot can be zoomed. When the user is finished with the plot, the enter key can be hit which closes the window and returns the user to the variable prompt.
Meteogram PlottingThe default for each variable selected is a time series plot/chart. The chart has a range from just above the maximum to just below the minimum. The Y axis is labeled with the variable name and the units. The label is rotated counterclockwise. If the plot type is not plot, the data are printed (type=value) or plotted in the case of weather symbols (type=wx), cloud cover (type=cloud) or wind barbs (type=cbarb). If the variable is cldcl, the cloud ceilings are plotted using a logarithmic scale of the cloud base height in feet ranging from the 100 to 50,000 feet. Each cloud layer base is plotted as horizontal lines. Clear skies are plotted as a 'C'. Scattered cloud layers (1/8th to 3/8th coverage) are plotted as a single short dash "-". Broken cloud layers (4/8th to 7/8th coverage) are plotted as two short dashes "- -". Overcast layers are plotted as a single long dash "---".
If more than one variable is listed, the program stacks up the time series plots from top to bottom. If the variable is a group {var1,var2}, the program plots those on top of each other or on the same chart. The size of these plots can be set with the "sz=size" attribute. The size is the fraction of the largest side of the window. For most plots, the maximum size is about .8. Here is an example of the composite plot listed above:
all All_Data 1 temp {temp,dewp} [F :plot:sz=.18],\ extt [F :value],\ wx [ :wx],\ snwdp [in :value],\ prec [in :value:%.2f],\ vis [mi :value],\ wgst [knt:value],\ wind { \ wind [knt:cbarb],\ cldcv [% :cloud] },\ cld [ft :plot:sz=.14],\ cldcl [100_ft:data],\ pres [mb :plot:sz=.14]
MOS Data Meteogram
The MOS data meteogram will plot a time series of forecast data. The NGM MOS data lists forecast data up to 60 hours. In this mode, a meteogram of forecast data will be produced. To trigger this mode, the model resource must be set to "ngm".
The programs starts off by prompting the user for input MOS file name. The user may specify the input file either via the command line of through the current resource. The input naming convention is specified by the mos_dat tag but this can be changed with the in_file resource.
Next, the program prompts the user for the station identifier to use in the plot. Remember that MOS data is stored by the 3 letter identifier in most cases.
The program will now prompt the user for the particular output variable to plot. Since the MOS data is close to regular surface data, most of the above variables are available. The program attempts to get sea level pressure data from the NGM_UA data. If that is available, most parameters can be computed. The program now lists the forecast data in a table:
NGM MOS data for IND from 1800Z 3 OCT 97 to 0000Z 6 OCT 97 ID TIME T TD RH DIR SPD GST ALT SLP VIS CIL COV WX MAX MIN PR6 PR24 SC IND 1800 76 60 58 220 15 120 10 250 SCT IND 2100 78 60 54 220 13 115 10 250 SCT IND 0000 72 61 68 210 7 110 10 250 SCT IND 0300 67 61 81 200 6 115 10 CLR IND 0600 65 60 84 190 7 120 10 CLR IND 0900 63 60 90 220 9 130 10 250 SCT IND 1200 63 60 90 230 10 140 10 250 BKN 61 IND 1500 72 62 71 230 12 140 10 250 BKN IND 1800 78 62 58 240 15 140 10 250 BKN IND 2100 79 61 54 240 13 145 10 250 BKN IND 0000 73 60 64 230 8 150 10 250 SCT 82 IND 0300 66 58 75 240 5 155 CLR IND 0600 61 56 84 250 4 160 10 CLR IND 0900 59 55 87 210 4 170 CLR IND 1200 58 55 90 200 3 180 10 CLR 56 IND 1500 69 58 68 210 8 CLR IND 1800 77 57 50 220 11 CLR IND 2100 78 57 48 220 10 CLR IND 0000 71 57 61 200 6 SCT 80
The program prompts the user for the output device and then produces the MOS meteogram.
EXAMPLES
statlog -cu=la -id=KIND -va=all -de=d
This plots a composite 12 hour meteogram for KIND.
statlog -cu=la -id=KIND -nh=-24 -va=all -de=d
This creates a 24 hour meteogram.
statlog -mo=ngm -cu=la -id=IND -va=all -de=d
This plots a 60 hour forecast meteogram for IND.
statlog -cu=la -id=KPHL -va=Temp{temp,dewp},wspd -de=d
This plots temperature, dewpoint on the same chart and wind speed on a different chart.
FILES
- sao.cty - the surface station location database file
- statlog.var - variable menu and definitions
SEE ALSO
Last updated July 30, 1998