Description Usage Arguments Details Value Author(s) Examples
A function to read a spatial network from a “SpatialLines” or “SpatialLinesDataFrame” object, and resolve it into a “nodelist” and “edgelist” for the following conversion.
1 |
ntdata |
A “SpatialLinesDataFrame” or “SpatialLines” object |
ELComputed |
If TRUE, the length of each edge will be calculated and returned |
longlat |
If TRUE, distances on an ellipse with WGS84 parameters will be returned |
Detailed |
If TRUE, all the vertices within the polylines of a spatial network will be recognised as nodes; if FALSE, only two endpoints of each polyline are treated as nodes |
ea.prop |
A vector (of the length equalling to the number of edge attributes in in the network “ntdata”) with values of 1 or 0: 1: the corresponding column in the data frame will be kept for the new network; 0: the corresponding column in the data frame will not be kept. |
This function plays the first step to convert a spatial network (in a “SpatialLines” or “SpatialLinesDataFrame” object) into an “igraph” object by returning a “nodelist” and “edgelist”.
A list consisted of:
Detailed |
TRUE if the output is under a “Detailed” mode; |
nodelist |
A “nodelist” object |
edgelist |
An “edgelist” object |
Edgelength |
If “ELComputed” is TRUE, lengths of all the edges will be returned as a numeric vector; otherwise it will be NULL. |
Eadf |
A data frame of attributes of the returned edges, of which the structure is a data frame with [EdgeID,(attributes inherited from the input network data)] |
nodexlist |
A vector contains X-coordinates of all the nodes |
nodeylist |
A vector contains Y-coordinates of all the nodes |
Binbin Lu lubinbin220@gmail.com
1 2 3 4 5 6 7 8 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.