mstlines {fossil}R Documentation

Display a Minimum Spanning Tree or Network

Description

a method of displaying a Minimum Spanning Tree/Network over a given set of points

Usage

mstlines(mst, x, y = NULL, pts.names = NULL, ...)

Arguments

mst

a minimum spanning tree or network object

x

either a table with the first two columns that of the x and y coordinates respectively, or simply that of the x coordinate

y

an optional argument if the y coordinates were not given in argument x

pts.names

If there is more than one shortest possible branch, should one be chosen randomly

...

arguments to be passed to lines()

Details

A function to plot the lines of a minimum spanning tree/forest on a plot; works as a frontend for lines.

Author(s)

Matthew Vavrek

See Also

dino.dist

Examples

#plot with overlain MST for fdata dataset
data(fdata.lats)
data(fdata.mat)
fdata.dist<-dino.dist(fdata.mat)
fdata.mst<-dino.mst(fdata.dist)
plot(coordinates(fdata.lats))
mstlines(fdata.mst, coordinates(fdata.lats))

[Package fossil version 0.4.0 Index]