From de861f5324dc3c382b43b303b9c3bec838fd92fb Mon Sep 17 00:00:00 2001 From: Ben Varick Date: Mon, 14 Oct 2024 17:08:09 -0500 Subject: [PATCH] added a project file. and the salmon river --- .gitignore | 1 + USGS_NWIS.R | 3 ++- USGS_NWIS.Rproj | 13 +++++++++++++ river_IDs.csv | 11 ++++++----- 4 files changed, 22 insertions(+), 6 deletions(-) create mode 100644 USGS_NWIS.Rproj diff --git a/.gitignore b/.gitignore index 9382c6b..5c967e3 100644 --- a/.gitignore +++ b/.gitignore @@ -6,3 +6,4 @@ data/* #ignore the figure files figures/* +.Rproj.user diff --git a/USGS_NWIS.R b/USGS_NWIS.R index 2015086..a74280c 100644 --- a/USGS_NWIS.R +++ b/USGS_NWIS.R @@ -9,7 +9,8 @@ rivers <- read_csv(file = "river_IDs.csv", col_types = c("c", "c")) #rivers <- rivers %>% filter(names %in% c("Elwha")) #rivers <- rivers %>% filter(names %in% c("Duckabush")) -#rivers <- rivers %>% filter(names %in% c("Hoh")) +rivers <- rivers %>% filter(names %in% c("Salmon")) + ifelse(!dir.exists(file.path(getwd(), "figures")), dir.create(file.path(getwd(), "figures")), FALSE) ifelse(!dir.exists(file.path(getwd(), "data")), dir.create(file.path(getwd(), "data")), FALSE) diff --git a/USGS_NWIS.Rproj b/USGS_NWIS.Rproj new file mode 100644 index 0000000..8e3c2eb --- /dev/null +++ b/USGS_NWIS.Rproj @@ -0,0 +1,13 @@ +Version: 1.0 + +RestoreWorkspace: Default +SaveWorkspace: Default +AlwaysSaveHistory: Default + +EnableCodeIndexing: Yes +UseSpacesForTab: Yes +NumSpacesForTab: 2 +Encoding: UTF-8 + +RnwWeave: Sweave +LaTeX: pdfLaTeX diff --git a/river_IDs.csv b/river_IDs.csv index bda154f..5f61f83 100644 --- a/river_IDs.csv +++ b/river_IDs.csv @@ -1,10 +1,11 @@ names,siteNumber -Yahara,05428500 -Des Plaines,05533600 -North Branch Chicago,05534500 +Yahara,5428500 +Des Plaines,5533600 +North Branch Chicago,5534500 Elwha,12045500 Wenatchee,12462500 Snake,13013650 -Wisconsin,05407000 +Wisconsin,5407000 Cedar,12119000 -Colorado,09380000 +Colorado,9380000 +Salmon,13317000