seasonalShift: Plot seasonal shifts in GSOD temperature data

Description Usage Arguments Value Author(s) Examples

View source: R/seasonalShift.R

Description

This function aims at visualizing seasonal shifts in GSOD data aggregated on a monthly level. The seasonal shifts are derived from a harmonic trend model fitted to the desired start and end range of a measurement series.

Usage

1
2
seasonalShift(fls, start = c("1973-01-01", "1977-12-31"),
  end = c("2008-01-01", "2012-12-31"), prm = "TEMP", stations, ...)

Arguments

fls

Character vector containing filepath(s) to the GSOD data set(s) to visualize, or list containing data.frame objects holding the data, or a single data.frame in case only one GSOD station shall be visualized.

start

Character. A vector containing the temporal range of the start interval to fit a harmonic trend model to.

end

Character. A vector containing the temporal range of the end interval to fit a harmonic trend model to.

prm

Character, default is "TEMP". Determines which parameter to visualize.

stations

Character. Name(s) of the station(s) corresponding to fls that will be displayed above each facet.

...

Additional arguments passed to element_text.

Value

An object of class ggplot.

Author(s)

Florian Detsch

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
# Load outlier-adjusted (*gsod*) and gap-filled (*ssa*) data sets from Nairobi
# and Kilimanjaro Airport, 1980-2000
data("data_nairobi_kilimanjaro")

# Visualize seasonal shifts in monthly averaged air temperature
seasonalShift(fls = list(df_gsod_nairobi, df_gsod_kilimanjaro),
              start = c("1980-01-01", "1983-12-31"),
              end = c("1998-01-01", "2000-12-31"),
              stations = c("Jomo Kenyatta Intl.", "Kilimanjaro Intl. Airport"),
              prm = "MAX")

environmentalinformatics-marburg/GSODTools documentation built on May 13, 2017, 6:09 p.m.