Learn R Programming

Momocs (version 0.2-03)

tps.grid: Deformation grids using Thin Plate Splines.

Description

tps.grid calculates and plots deformation grids between two configurations.

Usage

tps.grid(fr, to, amp=1, plot.full=TRUE, grid.outside = 0.2,
         grid.size = 20, grid.col   = "grey40",
         shp = TRUE, shp.col =  rep(NA, 2), shp.border=col.gallus(2),
         shp.lwd = c(2, 2), shp.lty = c(1, 1))

Arguments

fr
The reference $(x; y)$ coordinates.
to
The target $(x; y)$ coordinates.
amp
An amplification factor of differences between fr and to.
plot.full
logical. If FALSE graphical window will encompasses the entire outlines but maybe not the entire grid.
grid.outside
A numeric that indicates how much the grid extends beyond the range of outlines. Expressed as a proportion of the latter.
grid.size
A numeric to specify the number of grid cells on the longer axis on the outlines.
grid.col
A color for drawing the grid.
shp
logical. Whether to draw shapes.
shp.col
Two colors for filling the shapes.
shp.border
Two colors for drawing the borders.
shp.lwd
Two lwd for drawing shapes.
shp.lty
Two lty fro drawing the shapes.

Value

  • No returned value.

Examples

Run this code
data(bot)
botF <- eFourier(bot)
x <- meanShapes(botF, "type", nb.pts=80)
fr <- x$beer
to <- x$whisky
tps.grid(fr, to, amp=3, grid.size=40)

Run the code above in your browser using DataLab