dataFrame.column.stat — elbow()
Description
The elbow() method of the stat object returns the index of the elbow point in the values of the selected column.
Signature
dataFrame.column(columnName).stat.elbow({ sorted: false })Arguments
columnName(string)- The name of the column from which to calculate the differences.
options(object)- Elbow detection options.
Option
sorted(boolean)- Indicates whether the values are already sorted in ascending order.
- Sorted:
true - Not sorted:
false(default)
- Sorted:
Returns
elbowIndex(number)- The index of the detected elbow point.
Example
// get the elbow index from values of a column of the dataFrame
var elbowIndex = dataFrame.column('revenue').stat.elbow();
// log the elbow index
notebook.log(elbowIndex);