Learn R Programming

Momocs (version 1.4.1)

coo_circularity: Calculates the Haralick's circularity of a shape

Description

coo_circularity calculates the 'circularity measure'. Also called 'compactness' and 'shape factor' sometimes. coo_circularityharalick calculates Haralick's circularity which is less sensible to digitalization noise than coo_circularity. coo_circularitynorm calculates 'circularity', also called compactness and shape factor, but normalized to the unit circle.

Usage

coo_circularity(coo)

# S3 method for default coo_circularity(coo)

# S3 method for Coo coo_circularity(coo)

coo_circularityharalick(coo)

# S3 method for default coo_circularityharalick(coo)

# S3 method for Coo coo_circularityharalick(coo)

coo_circularitynorm(coo)

# S3 method for default coo_circularitynorm(coo)

# S3 method for Coo coo_circularitynorm(coo)

Value

numeric for single shapes, list for Coo of the corresponding circularity measurement.

Arguments

coo

a matrix of (x; y) coordinates or any Coo

See Also

Other coo_ descriptors: coo_angle_edges(), coo_angle_tangent(), coo_area(), coo_boundingbox(), coo_chull(), coo_convexity(), coo_eccentricity, coo_elongation(), coo_length(), coo_lw(), coo_rectangularity(), coo_rectilinearity(), coo_scalars(), coo_solidity(), coo_tac(), coo_width()

Examples

Run this code

# coo_circularity
bot[1] %>% coo_circularity()
bot %>%
    slice(1:5) %>% # for speed sake only
    coo_circularity

# coo_circularityharalick
bot[1] %>% coo_circularityharalick()
bot %>%
    slice(1:5) %>% # for speed sake only
    coo_circularityharalick

# coo_circularitynorm
bot[1] %>% coo_circularitynorm()
bot %>%
    slice(1:5) %>% # for speed sake only
    coo_circularitynorm

Run the code above in your browser using DataLab