Interface MeltCurvature
public interface MeltCurvature
How the curvature should be determined.
-
Field Summary
Modifier and TypeFieldDescriptionstatic final MeltCurvature
Implementation of "Finding a Kneedle in a Haystack: Detecting Knee Points in System Behavior" by Ville Satopaa; Jeannie Albrecht; David Irwin; Barath Raghavan.static final MeltCurvature
Implementation of the L method from: S.static final MeltCurvature
Implementation of the L method from: S.static final MeltCurvature
static final MeltCurvature
static final MeltCurvature
static final MeltCurvature
static final MeltCurvature
Compute the y value of the elbow point (the point with the maximum absolute second derivative).static final MeltCurvature
Computes the y values where the maximum slope is detected (the highest difference of y values).static final MeltCurvature
Compute the median value (e.g.static final MeltCurvature
Menger curvature to detect elbow points.static final MeltCurvature
Menger curvature to detect knee points.static final MeltCurvature
Compute the y value where the second derivative has the smallest value.static final MeltCurvature
Computes the y values where the minimum slope is detected (the lowest difference of y values). -
Method Summary
Modifier and TypeMethodDescriptiondefault double
computeCurvature
(double[] yVals) double
computeCurvature
(double[] xVals, double[] yVals) Computes the y value where the curvature changes.static MeltCurvature
configureLongestDistanceToStraightLine
(boolean knee, double percentageDiff) static Map<String,
MeltCurvature> static double
mengerDC
(double[] x, double[] y, int i)
-
Field Details
-
MAX_SLOPE
Computes the y values where the maximum slope is detected (the highest difference of y values). Does not work well for large data. -
MIN_SLOPE
Computes the y values where the minimum slope is detected (the lowest difference of y values). Does not work well for large data. -
MAX_SECOND_DERIVATIVE
Compute the y value of the elbow point (the point with the maximum absolute second derivative). https://stackoverflow.com/a/4473065/11951900 Does not work well for large data. -
MIN_SECOND_DERIVATIVE
Compute the y value where the second derivative has the smallest value. -
MEDIAN
Compute the median value (e.g. taking the value which lies in the middle). -
MENGER_ELBOW
Menger curvature to detect elbow points. Implementation details also available at MengerCurvature.java. Paper from X. Tolsa, “Principal Values for the Cauchy Integral and Rectifiability,” in American Mathematical Society, 2000. -
MENGER_KNEE
Menger curvature to detect knee points. Implementation details also available at MengerCurvature.java. Paper from X. Tolsa, “Principal Values for the Cauchy Integral and Rectifiability,” in American Mathematical Society, 2000. -
LONGEST_DISTANCE_TO_STRAIT_LINE_KNEE
-
LONGEST_DISTANCE_TO_STRAIT_LINE_ELBOW
-
LONGEST_DISTANCE_TO_ADJUSTED_STRAIT_LINE_KNEE
-
LONGEST_DISTANCE_TO_ADJUSTED_STRAIT_LINE_ELBOW
-
L_METHOD_KNEE
Implementation of the L method from: S. Salvador and P. Chan, “Determining the Number of Clusters/Segments in Hierarchical Clustering/Segmentation Algorithms,” in ICTAI, 2004. Two regression lines which should fit best to the data. The intersection point is the knee. Implementation details from Lmethod.java. -
L_METHOD_ELBOW
Implementation of the L method from: S. Salvador and P. Chan, “Determining the Number of Clusters/Segments in Hierarchical Clustering/Segmentation Algorithms,” in ICTAI, 2004. Two regression lines which should fit best to the data. The intersection point is the elbow. The data is just reversed. Implementation details from Lmethod.java. -
KNEEDLE_ELBOW
Implementation of "Finding a Kneedle in a Haystack: Detecting Knee Points in System Behavior" by Ville Satopaa; Jeannie Albrecht; David Irwin; Barath Raghavan. Partially used from library 137-stopmove.
-
-
Method Details
-
computeCurvature
double computeCurvature(double[] xVals, double[] yVals) Computes the y value where the curvature changes. It returns the y value and not the x value. IMPORTANT: in case the values are sorted, it has to be ascending.- Parameters:
xVals
- the x valuesyVals
- the y values- Returns:
- the y value where the curvature changes
-
computeCurvature
default double computeCurvature(double[] yVals) -
mengerDC
static double mengerDC(double[] x, double[] y, int i) -
configureLongestDistanceToStraightLine
-
getAllPossibleCurvatureMethods
-