get_upstream: Get upstream stations

Description Usage Arguments Value Examples

Description

return a list of stations that are upstream of a target station

Usage

1
get_upstream(station, table)

Arguments

station

target station for which a list of upstream stations is desired

table

a data.table describing upstream / downstream relationships between stations.

Value

Does not return a value, the table is modified in-place.

Examples

1
2
3
r <- initialize_matrix_from_stations(c('stn1', 'stn2', 'stn3'))
set_upstream('stn1', r, 'stn2')
get_upstream('stn1', r)

ECCC-MSC/Basin-Delineation documentation built on June 9, 2019, 7:29 p.m.