The hardware and bandwidth for this mirror is donated by dogado GmbH, the Webhosting and Full Service-Cloud Provider. Check out our Wordpress Tutorial.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]dogado.de.

Package {weatherStats}


Title: Airport Weather Station Statistics
Version: 0.1
Description: Download daily weather data recorded at airport weather stations using the National Centers for Environmental Information (NCEI) API https://www.ncei.noaa.gov/support/access-search-service-api-user-documentation.
Depends: R (≥ 3.5.0)
License: GPL (≥ 3)
RoxygenNote: 7.3.3
LazyData: true
NeedsCompilation: no
Packaged: 2026-04-23 12:50:54 UTC; pdh10
Author: Peter Hoff [aut, cre]
Maintainer: Peter Hoff <peter.hoff@duke.edu>
Repository: CRAN
Date/Publication: 2026-04-28 18:10:09 UTC

Airport Weather Station Statistics

Description

Download daily weather data recorded at airport weather stations using the National Centers for Environmental Information (NCEI) API <https://www.ncei.noaa.gov/support/access-search-service-api-user-documentation>.

Author(s)

Peter Hoff <peter.hoff@duke.edu>

Examples


RDU<-weatherStats("RDU",startDate="2024-01-01",endDate="2025-12-31") 
SEA<-weatherStats("SEA",year=2025)   

W<-tpdata(RDU,SEA) 
 
colnames(W) 
dim(W) 
tpplot(W) 


RDU weather dataset

Description

Two years of weather data at RDU.

Usage

RDU

Format

A data frame with dates along the rows, variables along the columns.

Source

Derived from original data at https://example.org


SEA weather dataset

Description

One year of weather data at SEA.

Usage

SEA

Format

A data frame with dates along the rows, variables along the columns.

Source

Downloaded via the NCEI API <https://www.ncei.noaa.gov/support/access-search-service-api-user-documentation>.


C to F temperature conversion

Description

Celsius to Fahrenheit temperature coversion

Usage

c2f(x)

Arguments

x

temperature in Celsius

Value

temperature in Fahrenheit

Author(s)

Peter Hoff


F to C temperature conversion

Description

Fahrenheit to Celsius temperature coversion

Usage

f2c(y)

Arguments

y

temperature in Fahrenheit

Value

temperature in Celsius

Author(s)

Peter Hoff


Month-specific date extraction

Description

Extract indices of a particular month from ISO 8601 format

Usage

isMonth(dates, month)

Arguments

dates

a vector of character dates in IS( 8601 format

month

an integer from 1 to 12

Value

a vector of matching indices

Author(s)

Peter Hoff


Temperature and precipitation data

Description

Extract and combine temperature and precipitation data

Usage

tpdata(...)

Arguments

...

either a list or sequence of data matrices obtained from 'weatherStats'

Value

a data frame

Author(s)

Peter Hoff

Examples

W<-tpdata(RDU,SEA) 
 
colnames(W) 
dim(W) 

tpplot(W) 


Temperature and precipitation plot

Description

Plot temperature and precipitation data

Usage

tpplot(TPDATA, units = "F", rc = "col")

Arguments

TPDATA

A data frame with temperature and precipitation data

units

"F" or "C"

rc

make multiple plots along columns ("col") or rows ("row")

Value

Invisibly returns NULL.

Author(s)

Peter Hoff

Examples

W<-tpdata(RDU,SEA) 
 
colnames(W) 
dim(W) 

tpplot(W) 


Weather Station Statistics

Description

Download weather data from the National Centers for Environmental Information (NCEI) using their API.

Usage

weatherStats(
  FAAID,
  year = NULL,
  startDate = NULL,
  endDate = NULL,
  trimNA = TRUE,
  maxTries = 5,
  tpause = 3,
  verbose = TRUE
)

Arguments

FAAID

Federal Aviation Administration (FAA) station ID

year

year for which data are to be downloaded

startDate

start date in YY-MM-DD format

endDate

end date in YY-MM-DD format

trimNA

remove days with no data

maxTries

maximum number of query attempts to the NCEI server

tpause

time in seconds to pause between API requests

verbose

a logical value indicating whether to report download progress

Value

a data frame with daily weather data

Author(s)

Peter Hoff

Examples

  

RDU<-weatherStats("RDU",startDate="2024-01-01",endDate="2025-12-31") 
SEA<-weatherStats("SEA",year=2025)   

 
dim(RDU) 
dim(SEA) 
colnames(SEA)
 

These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.
Health stats visible at Monitor.