Packages

class Fit extends AnyRef

The Fit class provides methods to determine basic quality of fit measures.

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Fit
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Fit(y: VectoD, n: Int, df: (Double, Double) = (0.0, 0.0))

    y

    the values in the m-dimensional response vector

    n

    the number of parameters (b.dim)

    df

    the degrees of freedom (df._1, df._2) for (regression, error)

Value Members

  1. val df: (Double, Double)
  2. def diagnose(e: VectoD, w: VectoD = null, yp: VectoD = null): Unit

    Given the error/residual vector, compute the quality of fit measures.

    Given the error/residual vector, compute the quality of fit measures.

    e

    the corresponding m-dimensional error vector (y - yp)

    w

    the weights on the instances

    yp

    the predicted response vector (x * b)

  3. def f_(z: Double): String

    Format a double value.

    Format a double value.

    z

    the double value to format

  4. def fit: VectoD

    Return the quality of fit including 'sst', 'sse', 'mse0', rmse', 'mae', 'rSq', 'df._2', 'rBarSq', 'fStat', 'aic', 'bic'.

    Return the quality of fit including 'sst', 'sse', 'mse0', rmse', 'mae', 'rSq', 'df._2', 'rBarSq', 'fStat', 'aic', 'bic'. Note, if 'sse > sst', the model introduces errors and the 'rSq' may be negative, otherwise, R^2 ('rSq') ranges from 0 (weak) to 1 (strong). Note that 'rSq' is the number 5 measure. Override to add more quality of fit measures.

  5. def fitLabel: Seq[String]

    Return the labels for the quality of fit measures.

    Return the labels for the quality of fit measures. Override to add more quality of fit measures.

  6. def fitMap: Map[String, String]

    Build a map of quality of fit measures (use of LinedHashMap makes it ordered).

    Build a map of quality of fit measures (use of LinedHashMap makes it ordered). Override to add more quality of fit measures.

  7. val index_rSq: Int
  8. def mse_: Double

    Return the mean of squares for error (sse / df._2).

    Return the mean of squares for error (sse / df._2). Must call diagnose first.

  9. def sumCoeff(b: VectoD, stdErr: VectoD = null): String

    Produce the summary report portion for the cofficients.

    Produce the summary report portion for the cofficients.

    b

    the parameters/coefficients for the model

  10. def summary(b: VectoD, stdErr: VectoD = null): String

    Produce a summary report with diagnostics for each predictor 'x_j' and the overall quality of fit.

    Produce a summary report with diagnostics for each predictor 'x_j' and the overall quality of fit.

    b

    the parameters/coefficients for the model