object NonLinRegression extends ModelFactory
The NonLinRegression
companion object provides factory methods for buidling perceptrons.
Note, 'rescale' is defined in ModelFactory
in Model.scala.
- Alphabetic
- By Inheritance
- NonLinRegression
- ModelFactory
- Error
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Value Members
-
def
allForms(x: MatriD): MatriD
Create all forms/terms for each row/point placing them in a new matrix.
Create all forms/terms for each row/point placing them in a new matrix.
- x
the original un-expanded input/data matrix
- Definition Classes
- ModelFactory
-
def
apply(x: MatriD, y: VectoD, f: FunctionP2S, b_init: VectorD, fname: Strings, hparam: HyperParameter): NonLinRegression
Create a
NonLinRegression
with automatic rescaling from a data matrix and response vector.Create a
NonLinRegression
with automatic rescaling from a data matrix and response vector.- x
the data/input matrix
- y
the response/output vector
- f
the non-linear function f(x, b) to fit
- b_init
the initial guess for the parameter vector b
- fname
the feature/variable names
- hparam
the hyper-parameters (currently has none)
-
def
apply(xy: MatriD, f: FunctionP2S, b_init: VectorD, fname: Strings = null, hparam: HyperParameter = null): NonLinRegression
Create a
NonLinRegression
with automatic rescaling from a combined data matrix.Create a
NonLinRegression
with automatic rescaling from a combined data matrix.- xy
the combined data/input and response/output matrix
- f
the non-linear function f(x, b) to fit
- b_init
the initial guess for the parameter vector b
- fname
the feature/variable names
- hparam
the hyper-parameters (currently has none)
- val drp: (Null, Null)
-
final
def
flaw(method: String, message: String): Unit
- Definition Classes
- Error
-
def
forms(xi: VectoD, k: Int, nt: Int): VectoD
Given a vector/point 'v', compute the values for all of its forms/terms, returning them as a vector (assumes
Regression
with intercept).Given a vector/point 'v', compute the values for all of its forms/terms, returning them as a vector (assumes
Regression
with intercept). Override for expanded columns, e.g.,QuadRegression
.- xi
the vector/point (i-th row of x) for creating forms/terms
- k
the number of features/predictor variables (not counting intercept)
- nt
the number of terms
- Definition Classes
- ModelFactory
-
def
numTerms(k: Int): Int
The number of terms/parameters in the model (assumes
Regression
with intercept.The number of terms/parameters in the model (assumes
Regression
with intercept. Override for expanded columns, e.g.,QuadRegression
.- k
the number of features/predictor variables (not counting intercept)
- Definition Classes
- ModelFactory
-
def
rescaleOff(): Unit
Turn rescaling off.
Turn rescaling off.
- Definition Classes
- ModelFactory
-
def
rescaleOn(): Unit
Turn rescaling on.
Turn rescaling on.
- Definition Classes
- ModelFactory