View source: R/river_network.R
state | R Documentation |
Setter and getter methods for river network state variables
## S3 method for class 'river_network'
state(x, var, history = FALSE)
## S3 replacement method for class 'river_network'
state(x, var) <- value
## S3 method for class 'river_network'
boundary(x, var)
## S3 replacement method for class 'river_network'
boundary(x, var) <- value
## S3 method for class 'river_network'
boundary_species(x)
## S3 replacement method for class 'river_network'
boundary_species(x) <- value
## S3 replacement method for class 'river_network'
site_by_species(x) <- value
## S3 method for class 'river_network'
site_by_species(x, history = FALSE)
reset_state(x, value)
reset_species(x, value)
x |
A river network |
var |
The state variable to extract/modify; must be one of |
history |
Logical; if TRUE, entire state history is returned |
value |
The value to update the variable with |
By default, setting state will save the current state in the state history, then update
current state to value
. Setting state to NULL erases the state variable.
boundary()
returns the boundary condition of the river network, as a site by resources
or site by species matrix.
boundary() <-
sets the boundary; it must be a site by var matrix in the same format as
state.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.