getStreamDistMatInOrder: Retrieve stream distance matrices by network (in order of...

Description Usage Arguments Details Value

View source: R/getStreamDistMatsInOrder.R

Description

This function retrieves the distance matrices that have been created for a SpatialStreamNetwork and orders them by network name.

Usage

1
getStreamDistMatInOrder(x, Name = "obs")

Arguments

x

An object of class SpatialStreamNetwork. The folder where the data for the SpatialStreamNetwork are stored must contain the distance matrix files generated by createDistMat from the package SSN.

Name

A string indicating whether the distance matrices for the observed or prediction sites should be extracted. This defaults to "obs" for the observed sites. Replacing this with "preds" will yield the matrices for the prediction sites.

Details

This function addresses the problem that the function getStreamDistMat returns a list of distance matrices but not in order of network ID. It orders the network IDs in alphanumeric order, meaning that, if a SpatialStreamNetwork has 10 networks, the order will appear as 1, 10, 2, 3, 4, ..., etc.

Value

A list of the distance matrices for the SpatialStreamNetwork, ordered numerically by the network ID.


apear9/SSNdesign documentation built on Feb. 19, 2020, 4:29 a.m.