read_daymet: Read Single Pixel Daymet data

View source: R/read_daymet.r

read_daymetR Documentation

Read Single Pixel Daymet data

Description

Reads Single Pixel Daymet data into a nested list or tibble, preserving header data and critical file name information.

Usage

read_daymet(file, site, skip_header = FALSE, simplify = TRUE)

Arguments

file

a Daymet Single Pixel data file

site

a sitename (default = NULL)

skip_header

do not ingest header meta-data, logical FALSE or TRUE (default = FALSE)

simplify

output tidy data (tibble), logical FALSE or TRUE (default = TRUE)

Value

A nested data structure including site meta-data, the full header and the data as a 'data.frame()'.

Examples


## Not run: 
# download the data
download_daymet(
site = "Daymet",
start = 1980,
end = 1980,
internal = FALSE,
silent = TRUE
)

# read in the Daymet file
df <- read_daymet(paste0(tempdir(),"/Daymet_1980_1980.csv"))

# print data structure
print(str(df))

## End(Not run)

daymetr documentation built on Sept. 15, 2023, 5:07 p.m.