write_phenocam: Write a phenocamr data structure to file

View source: R/write_phenocam.r

write_phenocamR Documentation

Write a phenocamr data structure to file

Description

Writes a nested data structure of class phenocamr to file, reconstructing the original data structure from included headers and data components.

Usage

write_phenocam(df = NULL, out_dir = tempdir())

Arguments

df

a nested data structure of class phenocamr

out_dir

output directory where to store data

Value

writes PhenoCam data structure to file, retains proper header info and inserts a processing time stamp.

Examples


## Not run: 
# download demo data (do not smooth)
download_phenocam(site = "harvard$",
                  veg_type = "DB",
                  roi_id = "1000",
                  frequency = "3",
                  smooth = FALSE)

# read the phenocamo data file
df = read_phenocam(file.paste(tempdir(),"harvard_DB_1000_3day.csv"))

# print data structure
print(summary(df))
 
# write the phenocamo data file
write_phenocam(df, out_dir = tempdir())

## End(Not run)

bluegreen-labs/phenocamr documentation built on Feb. 6, 2024, 10:42 p.m.