
Composite Hydrograph
Single_basin.RmdBasin and Range basin-fill aquifers
Get Data
First step, create a _targets.R file using
create_targets_script:
library(HASP)
library(targets)
aquifer_long_name <- "Basin and Range basin-fill aquifers"
aquiferCd <- summary_aquifers$nat_aqfr_cd[summary_aquifers$long_name == aquifer_long_name]
create_targets_script(national_aquifer_cd = aquiferCd,
parameter_cd = "72019",
statistic_cd = "00003",
start_date = "1988-10-01",
end_date = "2021-01-01",
file_name = "_targets.R")Once the _targets.R file is created, run:
A long-running pipeline will begin.
If everything DIDN’T go well, perhaps you exceeded your allotted requests to the API, perhaps there was a timeout, re-run the pipeline:
tar_make()If everything DOES goes well, you will see this at the end:
✔ dv_measurements completed [2m 40.2s, 2.98 MB]
+ dv_levels dispatched
✔ dv_levels completed [10ms, 1.59 MB]
+ aquifer_data dispatched
✔ aquifer_data completed [10.3s, 3.58 MB]
+ site_info dispatched
✔ site_info completed [50ms, 474.56 kB]
✔ ended pipeline [3m 12.5s, 165 completed, 305 skipped]
Once the pipeline completes, load the aquifer_data and
site_info into your workspace using
tar_load:
Map It
map <- map_hydro_data(aquifer_data, site_info, 30)
map
