write_netpreds: Write river network predictions

Description Usage Arguments Details Value

Description

Make model predictions for global river network and write out csv table.

Usage

1
2
3
4
5
6
7
8
9
write_netpreds(
  in_network,
  in_rftuned,
  in_predvars,
  predcol,
  discharge_interval = c(-Inf, Inf),
  interthresh = 0.5,
  outp_riveratlaspred
)

Arguments

in_network

data.table of formatted global river network with all predictor hydro-environmental variables. Output from rformat_network.

in_rftuned

trained random forest model. Output from selecttrain_rf; list containing inner resampling results.

in_predvars

data.table of predictor variable codes, names and attributes. Output from selectformat_predvars.

predcol

(character) name of the column to which the predicted probability of flow intermittence for each reach be written.

discharge_interval

(vector of two numeric values) discharge criterion to subset global river network. Range of long-term mean annual discharge values for which to produce model predictions.

interthresh

(numeric) between 0 and 1 (inclusive), probability threshold above which to classify river and stream reaches as non-perennial (e.g., 0.50).

outp_riveratlaspred

(character) ull path to which the output csv file will be written, including the file name and extension.

Details

the date is added to the output file name in the format outp_riveratlaspred_YYYYMMDD.

Value

path to output csv file.


messamat/globalIRmap documentation built on July 4, 2021, 10:48 a.m.