Title: | Tools for Plotting Skew-T Diagrams and Wind Profiles |
---|---|
Description: | A collection of programs for plotting SKEW-T,log p diagrams and wind profiles for data collected by radiosondes (the typical weather balloon-borne instrument). The format of this plot with companion lines to assess atmospheric stability are both standard in meteorology and difficult to create from basic graphics functions. Hence this package. One novel feature is being able add several profiles to the same plot for comparison. Use "help(ExampleSonde)" for an explanation of the variables needed and how they should be named in a data frame. See <https://github.com/dnychka/Radiosonde> for the package home page. |
Authors: | Doug Nychka, Eric Gilleland, Liangying Zhang, Tim Hoar, Kate Young |
Maintainer: | Doug Nychka <[email protected]> |
License: | GPL (>= 2) |
Version: | 4.2 |
Built: | 2025-01-25 02:32:12 UTC |
Source: | https://github.com/cran/RadioSonde |
The R data frames sonde1
and sonde2
are examples of high
resolution (vertical) soundings of the atmosphere. The balloons were launched
on July 4, 2015 02:59:33 and 04:59:23 (UTC) as part of the PECAN field study
lead by the National Center for Atmospheric Research
( see https://www.eol.ucar.edu/field_projects/pecan. Refer to the Data Access
tab on the PECAN home page to download the data collected during this study where "upper air"
indexes radiosonde observations. The interest in this
close spacing was to compare how the vertical structure of the atmosphere
changed at this location in the Northwest corner of Kansas
(-101.370712,39.357468) over a short amount of time.
These data frames contain the following named components:
time | Time in seconds from the ballon's release, a numeric vector. |
press | Pressure (mb), a numeric vector |
temp | Dry-bulb Temperature (deg. C), a numeric vector |
dewpt | Dew point temperaure (deg. C), a numeric vector |
rh | Relative humidity (%), a numeric vector |
uwind | East-West component of the wind, a numeric vector |
vwind | North-South component of the wind, a numeric vector |
wspd | wind speed (m/s), a numeric vector |
dir | Wind direction, a numeric vector |
dz | rate of ascent in m/s |
lon | Longitude, a numeric vector |
lat | Latitude, a numeric vector |
az | azimuth (angle along horizon), a numeric vector |
alt | altitude (m), a numeric vector |
qp | QC flag for pressure, a numeric vector |
qt | QC flag for temperature, a numeric vector |
qh | QC flag for humidity, a numeric vector |
qu | QC flag for U component, a numeric vector |
qv | QC flag for V component, a numeric vector |
quv | QC flag for ascension rate, a numeric vector |
Raw ( ascii/text) data files are in the github RadioSonde R package repository
https://github.com/dnychka/Radiosonde.
along with the
R script that converts to a data frame useful in R.
The NCAR/PECAN original
data
files are those ending in the extention .eol
and are the standard format
for radiosonde profiles collected by this lab. Note that in this proccess the
original variable names were converted to those used in this package. E.g.
Press
changes to press
. Also the metadata units that are in
the header of the original file is included as an attribute in the R versions.
data(sonde1) # look at the metadata cat( attributes( sonde1)$metaData, fill=TRUE) # and the units cat( attributes( sonde1)$units, fill=TRUE) skewtPlot( sonde1, winds=TRUE) data(sonde2) # skewt with wind barbs. skewtPlot( sonde1, sonde2, winds=TRUE)
data(sonde1) # look at the metadata cat( attributes( sonde1)$metaData, fill=TRUE) # and the units cat( attributes( sonde1)$units, fill=TRUE) skewtPlot( sonde1, winds=TRUE) data(sonde2) # skewt with wind barbs. skewtPlot( sonde1, sonde2, winds=TRUE)
Creates a wind profile in the standard atmospheric notation. Each full barb = 10 m/s, half barb = 5 m/s, and a filled triangle for 50 m/s. The maximum wind speed that can be plotted without amending the program is 65 m/s.
plotWind(sondeData, sizeBarb = NULL, ylim = c(1050, 100), thin=NULL, legend = FALSE, lwd=1, col="green4", axis=TRUE)
plotWind(sondeData, sizeBarb = NULL, ylim = c(1050, 100), thin=NULL, legend = FALSE, lwd=1, col="green4", axis=TRUE)
sondeData |
Data frame for sounding data, must have components for
wind speed |
sizeBarb |
change the thickness of the plotted lines |
thin |
Max number of wind barbs to draw. |
axis |
If TRUE add an axis in pressure. |
col |
Color of barbs |
lwd |
Line width for barbs |
ylim |
Plot extent, in units of pressure. Note this is a reversed axis. |
legend |
explains wind barb convention |
the dataframe must have components for wind speed wspd
,
wind direction dir
, and pressure press
.
Missing values may be coded as either NA or 999. and are
not plotted.
The standard atmospheric wind sybmol is a vector of fixed length
with barbs proportional to wind speed. A full barb for each 10 m/s,
half barbs for 5 m/s and a triangular barb for 50 m/s.
None – creates a plot.
Doug Nychka, Eric Gilleland
# Example 1: data(sonde1) plotWind(sonde1, sizeBarb =1.0, legend=TRUE )
# Example 1: data(sonde1) plotWind(sonde1, sizeBarb =1.0, legend=TRUE )
Overlays observations as lines on a SKEW-T, log p axis
(as created by skewt.axis
).
skewt.lines(temp, pressure, ...)
skewt.lines(temp, pressure, ...)
temp |
Temperature in degrees C. |
pressure |
Pressure in millibars |
... |
Any graphical arguments |
skewt.lines
overlays observations on a SKEW-T, log p axis
Creates a SKEW-T, log p diagram with dry-bulb temperature and dewpoint temperature traces versus (log) pressure. Optionally plots the vertical wind profile using wind barbs.
skewtPlot( ..., winds = FALSE, colTemp = c("grey40", "blue2"), colDew = colTemp, lty = c(1, 1), lwd = 1.5, windplot = NULL, windAxis = FALSE, sizeBarb = NULL, thin = NULL, magicRatio = 13, skewplot = NULL, mar.skewt = c(3.1, 5.1, 4.1, 2.1) )
skewtPlot( ..., winds = FALSE, colTemp = c("grey40", "blue2"), colDew = colTemp, lty = c(1, 1), lwd = 1.5, windplot = NULL, windAxis = FALSE, sizeBarb = NULL, thin = NULL, magicRatio = 13, skewplot = NULL, mar.skewt = c(3.1, 5.1, 4.1, 2.1) )
... |
One or more data frames where rows indexes the time ( or height) and the columns are the variables measured.
The variables must be names as: |
winds |
If TRUE will add wind barbs to the side of the skewt plot. |
colTemp |
Colors(s) to plot temperature. |
colDew |
Colors(s) to plot dew point temperature. |
lty |
Line type for the plotted curves. |
lwd |
Line width for the curves. |
skewplot |
Vector of 4 figure coordinates that define the skewt plot portion of figure.
By default |
windplot |
A matrix of the 4 figure coodinates where each row defines the figure region for the wind barbs. |
windAxis |
If TRUE include a height axis alongside the wind barbs. |
sizeBarb |
Controls relative size of the wind barbs. |
thin |
Total number of equally select3ed wind barbs to plots. This avoids too much overplotting. |
mar.skewt |
Margins for the labels of the skewt plot. |
magicRatio |
Relative space in horizontal for the skewt plot and the panel with vertical wind barbs. |
We recommend that the plots be drawn using the the pdf output devide with a 8 by 6 inch size.
Doug Nychka, Eric Gilleland, Tim Hoar, Kate Young
1. Department of Defense, 1969, "USAF SKEW-T, log p DIAGRAM," DOD-WPC-9-16-1, Aeronautical Chart and Information Center, United States Air Force, St. Louis, Missouri 63118.
2. List, R.J. (editor), 1958, Smithsonian Meteorological Tables, Smithsonian Institute, Washington, D.C.
3. Nordquist, W.S., 1973, "Numerical Approximations of Selected Meteorological Parameters for Cloud Physics Problems," ECOM-5475, Atmospheric Sciences Laboratory, US Army Electronics Command, White Sands Missile Range, New Mexico 88002.
4. Stipanuk, G.S., 1973, "Algorithms for Generating a SKEW-T, log p Diagram and Computing Selected Meteorological Quantities," American Sciences Laboratory, US Army Electronics Command, White Sands Missile Range, New Mexico 88002.
data(sonde1) # skewt with wind barbs. skewtPlot( sonde1, winds=TRUE) # mulitple profiles data(sonde2) skewtPlot( sonde1, sonde2)
data(sonde1) # skewt with wind barbs. skewtPlot( sonde1, winds=TRUE) # mulitple profiles data(sonde2) skewtPlot( sonde1, sonde2)
Adds a meteorological surface station annotation at the given coordinates. The annotation includes speed and direction of the wind, temperature, pressure, dewpoint ... to a given plot.
station.symbol( cx, cy, direction = 0, speed = NA, fill = rep(0, length(cx)), temp = NA, press = NA, dewpt = NA, circle = TRUE, cex = 1, spdcolor = "green", lwd = 2 )
station.symbol( cx, cy, direction = 0, speed = NA, fill = rep(0, length(cx)), temp = NA, press = NA, dewpt = NA, circle = TRUE, cex = 1, spdcolor = "green", lwd = 2 )
cx |
x coordinate for location of the annotation. |
cy |
y coordinate for the annotation. |
direction |
Wind direction. |
speed |
Wind speed. |
fill |
Fill for visibility: 0 = clear skies, 1 = 25% obscured, 2 = 50% obscured, 3 = 75% obscured, 4 = no visibility |
temp |
Temperature value to plot symbol (must be a scalar). If NULL then no temperature value will be annotated. |
press |
Pressure value to plot symbol (must be a scalar). If NULL then no pressure value will be annotated. |
dewpt |
Dewpoint Temperature value to plot symbol (must be a scalar). If NULL then no dewpoint value will be annotated. |
circle |
If TRUE, will plot the usual station symbol with a circle at its base. |
cex |
Usual plotting parameter. |
spdcolor |
Glyph color |
lwd |
barb line width |
Doug Nychka, Eric Gilleland
plot(0:1, 0:1, type="n") station.symbol(0.5, 0.5, direction=130, speed=30, fill=3, temp=31, press=987, dewpt=26, cex=5) title("Wind Barb")
plot(0:1, 0:1, type="n") station.symbol(0.5, 0.5, direction=130, speed=30, fill=3, temp=31, press=987, dewpt=26, cex=5) title("Wind Barb")