quarks.analytics.math3.stat
Enum Regression
- java.lang.Object
-
- java.lang.Enum<Regression>
-
- quarks.analytics.math3.stat.Regression
-
- All Implemented Interfaces:
- java.io.Serializable, java.lang.Comparable<Regression>, JsonUnivariateAggregate, Supplier<JsonUnivariateAggregator>
public enum Regression extends java.lang.Enum<Regression> implements JsonUnivariateAggregate
Univariate regression aggregates.
-
-
Enum Constant Summary
Enum Constants Enum Constant and Description SLOPE
Calculate the slope of a single variable.
-
Field Summary
-
Fields inherited from interface quarks.analytics.math3.json.JsonUnivariateAggregate
N
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method and Description static Regression
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static Regression[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.-
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
-
Methods inherited from interface quarks.analytics.math3.json.JsonUnivariateAggregate
name
-
-
-
-
Enum Constant Detail
-
SLOPE
public static final Regression SLOPE
Calculate the slope of a single variable. The slope is calculated using the first order of a ordinary least squares linear regression. The list of values for the single single variable are processed as Y-values that are evenly spaced on the X-axis.
This is useful as a simple determination if the variable is increasing or decreasing.
The slope value is represented as adouble
with the keySLOPE
in the aggregate result.
If the window to be aggregated contains less than two values then no regression is performed.
-
-
Method Detail
-
values
public static Regression[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (Regression c : Regression.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Regression valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-