-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path1_crosswalk_fetch.yml
58 lines (48 loc) · 2.41 KB
/
1_crosswalk_fetch.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
target_default: 1_crosswalk_fetch
packages:
- dplyr
- scipiper
- dataRetrieval
- stringr
- sf
- httr
- sbtools
- smoothr
sources:
- 1_crosswalk_fetch/src/fetch_nhdhr.R
- 1_crosswalk_fetch/src/fetch_wqp_sites.R
- 1_crosswalk_fetch/src/file_utils.R
targets:
1_crosswalk_fetch:
depends:
- 1_crosswalk_fetch/out/canonical_lakes_sf.rds.ind
- 1_crosswalk_fetch/out/wqp_lake_temperature_sites_sf.rds.ind
wqp_temperature_charnames:
command: c(I(c(
"Temperature",
"Temperature, sample",
"Temperature, water",
"Temperature, water, deg F")))
#https://www.waterqualitydata.us/portal/#siteType=Lake%2C%20Reservoir%2C%20Impoundment&characteristicName=Depth%2C%20Secchi%20disk%20depth&characteristicName=Water%20transparency%2C%20Secchi%20disc&characteristicName=Depth%2C%20Secchi%20disk%20depth%20(choice%20list)&characteristicName=Secchi%20Reading%20Condition%20(choice%20list)&mimeType=tsv
#
nhd_HR_download_plan:
command: create_nhd_HR_download_plan(I(c("Alabama", "Arizona", "Arkansas", "California", "Colorado", "Connecticut",
"District_of_Columbia", "Florida", "Georgia", "Hawaii", "Illinois", "Iowa", "Kansas", "Kentucky",
"Louisiana", "Maine", "Maryland", "Massachusetts", "Michigan", "Minnesota", "Mississippi", "Missouri", "Montana", "Nebraska",
"Nevada", "New_Hampshire", "New_Jersey", "New_Mexico", "New_York", "North_Carolina", "North_Dakota", "Ohio", "Oklahoma",
"Pennsylvania", "Rhode_Island", "South_Carolina", "South_Dakota", "Tennessee", "Utah", "Vermont", "Virginia",
"Texas", "Indiana", "Oregon", "Idaho",
"Washington", "West_Virginia", "Wisconsin", "Wyoming")),
min_size = 40000, d_tolerance = I(0.0001))
1_crosswalk_fetch_nhd_tasks.yml:
command: create_nhd_HR_download_makefile(target_name, nhd_HR_download_plan,
final_targets = I(c('1_crosswalk_fetch/out/canonical_lakes_sf.rds.ind',
'2_crosswalk_munge/out/gnisname_nhdhr_xwalk.rds.ind')))
1_crosswalk_fetch/out/canonical_lakes_sf.rds.ind:
command: loop_tasks(nhd_HR_download_plan, '1_crosswalk_fetch_nhd_tasks.yml')
# LOCKED THIS IN!!!
1_crosswalk_fetch/out/wqp_lake_temperature_sites_sf.rds.ind:
command: fetch_wqp_sites(target_name, characteristicName = wqp_temperature_charnames,
sf_ind = '1_crosswalk_fetch/out/canonical_lakes_sf.rds.ind',
box_res = 5, dummy = I('2021-04-05'),
'1_crosswalk_fetch/src/fetch_wqp_sites.R')