DesignMatrix
DesignMatrix[{{x11,x12,…,y1},{x21,x22,…,y2},…},{f1,f2,…},{x1,x2,…}]
constructs the design matrix for the linear model β0+β1 f1+β2 f2+….
Details and Options
- DesignMatrix[{y1,y2,…},{f1,f2,…},x] assumes data of the form {{1,y1},{2,y2},…}. »
- With data in the form , the number of coordinates xi1, xi2, … should equal the number of variables xi.
- The design matrix m is formed from the values of basis functions fi at data points in the form
- DesignMatrix takes the following options:
-
IncludeConstantBasis True whether to include a constant basis function NominalVariables None variables considered as nominal or categorical WorkingPrecision Automatic precision used in internal computations - With the setting IncludeConstantBasis->False, the design matrix for a model of form β1 f1+β2 f2+⋯ is constructed. »
Examples
open allclose allBasic Examples (3)
Scope (2)
Options (3)
Properties & Relations (1)
DesignMatrix constructs the design matrix used by LinearModelFit:
The matrix is the same for GeneralizedLinearModelFit:
Wolfram Research (2008), DesignMatrix, Wolfram Language function, https://reference.wolfram.com/language/ref/DesignMatrix.html.
Text
Wolfram Research (2008), DesignMatrix, Wolfram Language function, https://reference.wolfram.com/language/ref/DesignMatrix.html.
CMS
Wolfram Language. 2008. "DesignMatrix." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/DesignMatrix.html.
APA
Wolfram Language. (2008). DesignMatrix. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/DesignMatrix.html