Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

plot.pppmatching

Plot a Point Matching


Description

Plot an object of class "pppmatching" which represents a matching of two planar point patterns.

Usage

## S3 method for class 'pppmatching'
plot(x, addmatch = NULL, main = NULL, ..., adjust = 1)

Arguments

x

Point pattern matching object (class "pppmatching") to be plotted.

addmatch

Optional. A matrix indicating additional pairs of points that should be matched. See Details.

main

Main title for the plot.

...

Additional arguments passed to other plot methods.

adjust

Adjustment factor for the widths of line segments. A positive number.

Details

The object x represents a matching found between two point patterns X and Y. The matching may be incomplete. See pppmatching.object for further description.

This function plots the matching by drawing the two point patterns X and Y as red and blue dots respectively, and drawing line segments between each pair of matched points. The width of the line segments is proportional to the strength of matching. The proportionality constant can be adjusted using the argument adjust.

Additional graphics arguments ... control the plotting of the window (and are passed to plot.owin) and the plotting of the line segments (and are passed to plot.psp, and ultimately to the base graphics function polygon).

The argument addmatch is for use mainly by developers to study algorithms which update the matching. If addmatch is given, it should be a matrix with dimensions npoints(X) * npoints(Y). If addmatch[i,j] > 0 then a light grey line segment will be drawn between X[i] and Y[j.

Value

Null.

Author(s)

Dominic Schuhmacher and Adrian Baddeley Adrian.Baddeley@curtin.edu.au.

See Also

Examples

X <- runifrect(7)
  Y <- runifrect(7)
  am <- r2dtable(1, rep(10,7), rep(10,7))[[1]]/10
  m2 <- pppmatching(X, Y, am)
  plot(m2, adjust=0.3)

spatstat.geom

Geometrical Functionality of the 'spatstat' Family

v2.1-0
GPL (>= 2)
Authors
Adrian Baddeley [aut, cre], Rolf Turner [aut], Ege Rubak [aut], Tilman Davies [ctb], Ute Hahn [ctb], Abdollah Jalilian [ctb], Sebastian Meyer [ctb], Suman Rakshit [ctb], Dominic Schuhmacher [ctb], Rasmus Waagepetersen [ctb]
Initial release
2021-04-15

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.