measure {Momocs}R Documentation

Measures shape descriptors

Description

Calculates shape descriptors on Coo and other objects. Any function that returns a scalar when fed coordinates can be passed and naturally those of Momocs (pick some there apropos("coo_")). Functions without arguments (eg coo_area) have to be passed without brackets but functions with arguments (eg d) have to be passed "entirely". See examples.

Usage

measure(x, ...)

Arguments

x

any Coo object, or a list of shapes, or a shape as a matrix.

...

a list of functions. See examples.

Value

a TraCoe object, or a raw data.frame

See Also

Other premodern: coo_truss()

Examples

bm <- measure(bot, coo_area, coo_perim)
bm
bm$coe

# how to use arguments, eg with the d() function
measure(wings, coo_area, d(1, 3), d(4, 5))

# alternatively, to get a data_frame
measure(bot$coo, coo_area, coo_perim)

# and also, to get a data_frame (one row)
measure(bot[1], coo_area, coo_perim)

[Package Momocs version 1.4.1 Index]