-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #13 from NEONScience/master-merge
Subtree push from int1.3.1 update on FIU-algorithm repo
- Loading branch information
Showing
88 changed files
with
4,833 additions
and
1,430 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
############################################################################################## | ||
#' @title Workflow for downloading dp0p data from S3 | ||
|
||
#' @author | ||
#' David Durden \email{eddy4R.info@gmail.com} | ||
|
||
#' @description | ||
#' Workflow. Downloading dp0p data from S3. | ||
|
||
#' @param Currently none | ||
|
||
#' @return Currently none | ||
|
||
#' @references | ||
|
||
#' @keywords eddy-covariance, NEON | ||
|
||
#' @examples Currently none | ||
|
||
#' @seealso Currently none | ||
|
||
# changelog and author contributions / copyrights | ||
# David (2020-01-25) | ||
# original creation | ||
############################################################################################## | ||
|
||
#site to download data for | ||
site <- "STEI" | ||
#domain | ||
dom <- "D05" | ||
#SAE system (ecte vs. ecse) | ||
sys <- "ecte" | ||
|
||
#Create download folder, create if it doesn't exist | ||
DirDnld <- paste0("~/eddy/data/turbTow/inpRefe/",site) | ||
if(!dir.exists(DirDnld)) dir.create(DirDnld, recursive = TRUE) | ||
|
||
#Create data download string | ||
DateBgn <- as.Date("2019-09-11") | ||
DateEnd <- as.Date("2019-09-21") | ||
DateSeq <- seq.Date(from = DateBgn,to = DateEnd, by = "day") | ||
PrdWndwDnld <- base::as.character(DateSeq) | ||
|
||
|
||
|
||
#Filename base | ||
fileInBase <- paste0("NEON.",dom,".",site,".IP0.00200.001.",sys,".") | ||
|
||
#Create URL for data files | ||
urlDnld <- paste0("https://storage.cloud.google.com/neon-sae-files/ods/dataproducts/IP0/",PrdWndwDnld,"/",site,"/",fileInBase,PrdWndwDnld,".l0p.h5") | ||
|
||
#Download filename (full path) | ||
fileDnld <- paste0(DirDnld,"/",base::toupper(sys),"_dp0p_",site,"_",PrdWndwDnld,".h5") | ||
|
||
#Download files | ||
sapply(seq_along(urlDnld), function(x){ | ||
download.file(url = urlDnld[x], destfile = fileDnld[x]) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.