jhpro.stat
Class EEcentricity
- java.lang.Object
-
- jhpro.stat.EEcentricity
-
public class EEcentricity extends java.lang.ObjectA class for eccentricity calculations using a principle component analysis. It calculates variances alone the principal axis and the eccentricity.
-
-
Constructor Summary
Constructors Constructor and Description EEcentricity(double[] x, double[] y, double[] w)Initialize 2D PCA analysisEEcentricity(P1D p1d)Perform PCA analysis using P1D object (in 2D).
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voiddoc()Show online documentation.doublegetAngle()Returns angle of ellipse rotation (angle of the principial axis)doublegetEccentricity()Get eccentricity, defined as 1-VarianceMin / VarianceMax.doublegetVarianceMax()Get variance alone the major axis (longest component)doublegetVarianceMin()Get variance alone the minor (shortest component)
-
-
-
Constructor Detail
-
EEcentricity
public EEcentricity(double[] x, double[] y, double[] w)Initialize 2D PCA analysis- Parameters:
x- array in Xy- array in Y (the same size as for X)w- points weights (can be set to 1 if all points are treated with the same weight)
-
EEcentricity
public EEcentricity(P1D p1d)
Perform PCA analysis using P1D object (in 2D). All weights for points are set to 1. X and Y component of P1D are used for the PCA.- Parameters:
p1d- P1D input objects
-
-
Method Detail
-
getAngle
public double getAngle()
Returns angle of ellipse rotation (angle of the principial axis)- Returns:
- rotation angle (in rad)
-
getVarianceMin
public double getVarianceMin()
Get variance alone the minor (shortest component)- Returns:
- minimum variance
-
getVarianceMax
public double getVarianceMax()
Get variance alone the major axis (longest component)- Returns:
- minimum variance
-
getEccentricity
public double getEccentricity()
Get eccentricity, defined as 1-VarianceMin / VarianceMax. The value 0 corresponds to perfectly circular distribution, while 1 is for max. allongated- Returns:
- eccentricity
-
doc
public void doc()
Show online documentation.
-
-
DMelt 3.0 © DataMelt by jWork.ORG