Description Usage Arguments Details Value Note Author(s) See Also Examples
Computes the midpoints for a table of sample points with coordinates.
1 |
samples |
Table with coordinates for each sample point. |
x |
Column index or name of longitudes (x) in samples table (default is first column). |
y |
Column index or name of latitudes (y) in samples table (default is second column). |
sp.name |
Name for each sample point (defaults to row names of samples). |
all |
If TRUE computes midpoints between all sample points. If FALSE (default) computes a Delaunay triangulation and the midpoints of the resulting connected samples. |
This function computes the coordinates of the middle points between samples. The connecting network can be between all points or between neighbours with non-overlaping edges after a Delaunay triangulation.
Returns a data frame with 4 columns referring the source and target samples (ss and ts, respectively) and the coordinates of the midpoints.
Depends on package 'geometry' for Delaunay triangulation.
Pedro Tarroso <ptarroso@cibio.up.pt>
1 2 3 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.