Description Usage Arguments Details Author(s)
Produce a proto_graph
object that can be laid as a network, map, or geocoded network on a map.
1 | get_proto_graph(edges, nodes, directed = FALSE, centroid = TRUE)
|
edges |
A |
nodes |
A |
directed |
Logical, whether or not to create a directed graph. |
centroid |
Logical, whether or not to calculate the centroid for each geometry in the |
nodes
must be a data.frame
with vertex metadata. The first column of the table is assume to contain the symbolic vertex names, this will be added to the graphs as the 'name' vertex attribute. Additionally, as an object of class sf
it must include the intended geometry for each vertex.
centroid
is used to calculate the geographic position of each node when the network is represented on a map. As a default, the argument is set to TRUE
and will calculate the centroid for the provided geometry. If FALSE
the user will have to provide a node latitude and longitude for graphing.
Christopher Callaghan, cjcallag@nps.edu
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.