Class LinReg.Value

  • Enclosing class:
    LinReg

    static class LinReg.Value
    extends java.lang.Object
    • Field Summary

      Fields 
      Modifier and Type Field Description
      (package private) double intercept
      The intercept for the linear regression model.
      (package private) double rSquared
      the coefficient of determination
      (package private) double slope
      The slope for the linear regression model.
      (package private) double variance
      variance = sum square diff mean / n - 1
    • Constructor Summary

      Constructors 
      Constructor Description
      Value​(double intercept, double slope, java.util.List xs, java.util.List ys)  
    • Field Detail

      • intercept

        double intercept
        The intercept for the linear regression model. Initialized following a call to accuracy.
      • slope

        double slope
        The slope for the linear regression model. Initialized following a call to accuracy.
      • rSquared

        double rSquared
        the coefficient of determination
      • variance

        double variance
        variance = sum square diff mean / n - 1
    • Constructor Detail

      • Value

        Value​(double intercept,
              double slope,
              java.util.List xs,
              java.util.List ys)
    • Method Detail

      • getIntercept

        public double getIntercept()
      • getSlope

        public double getSlope()
      • getRSquared

        public double getRSquared()
      • setRSquared

        public void setRSquared​(double rSquared)
        strength of the correlation
        Parameters:
        rSquared - Strength of the correlation
      • getVariance

        public double getVariance()
      • setVariance

        public void setVariance​(double variance)
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object