Learn R Programming

cassowaryr (version 2.0.2)

sc_striped: Measure of Discreteness

Description

This metric computes the 1-(ratio between the number of unique values to total data values) on number of rotations of the data, and returns the smallest value. If this value is large it means that there are only a few unique data values, and hence the distribution is discrete

Usage

sc_striped(x, y)

Value

double

Arguments

x

numeric vector

y

numeric vector

Examples

Run this code
data("datasaurus_dozen_wide")
sc_striped(datasaurus_dozen_wide$v_lines_x,
           datasaurus_dozen_wide$v_lines_y)
sc_striped(datasaurus_dozen_wide$dino_x,
           datasaurus_dozen_wide$dino_y)

Run the code above in your browser using DataLab