get.sh.nasa: Retrieve specific humidity data from data-server

Description Usage Arguments Value Examples

View source: R/data_fxns.R

Description

Data is retrieved for the United States, HHS Regions, and States. Attempt to pull CDC data from the CDC server. If that fails, pull from diceData.

Usage

1
2
get.sh.nasa(region = "all", sub_region = 1, start_year = 2000,
  start_week = 1, end_year = 2016, end_week = 10)

Arguments

region

String specifying USA ('national'), CDC Region ('hhs'), US state ('state'), or all mydata regions ('all').

sub_region

For region='hhs': Integer(s) indicating which of the 10 CDC regions are to be retrieved. For region='state': a vector of state names to be returned.

start_year

An integer - start year of the flu season

start_week

An integer - starting CDC week of the flu season (default is 27)

end_year

An integer - end year of the flu season

end_week

An integer - ending CDC week of the flu season (default is 26)

Value

a data frame with columns for $date, $week, $year, and whichever regions were requested.

Examples

1
2
3
require(DICE)
sh = get.sh.nasa(region='hhs',sub_region=c(1,9),start_year=2015,end_year=2016,start_week=27,end_week=26)
sh2 = get.sh.nasa(region='state',sub_region=c('District.of.Columbia','Kansas'),start_year=2015,end_year=2016,start_week=27,end_week=26)

predsci/DICE documentation built on Aug. 9, 2019, 9:41 a.m.