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

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


if (FALSE) {
# 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())
}