LinearRegression`
LinearRegression`

IncludeConstant

As of Version 7.0, IncludeConstant has been renamed to IncludeConstantBasis and is part of the built-in Wolfram Language kernel.

IncludeConstant

is an option for Regress and DesignMatrix that specifies whether a constant term is automatically included in the model.

Details and Options

  • To use IncludeConstant, you first need to load the Linear Regression Package using Needs["LinearRegression`"].
  • The default setting IncludeConstant->True adds a constant term to the set of basis functions if a constant is not already included.
  • The setting IncludeConstant->False leaves the set of basis functions unchanged.
  • In the output of DesignMatrix, the constant term is included as the first column.

Examples

Basic Examples  (1)

Design matrices with and without a constant automatically included:

Wolfram Research (2007), IncludeConstant, Wolfram Language function, https://reference.wolfram.com/language/LinearRegression/ref/IncludeConstant.html.

Text

Wolfram Research (2007), IncludeConstant, Wolfram Language function, https://reference.wolfram.com/language/LinearRegression/ref/IncludeConstant.html.

CMS

Wolfram Language. 2007. "IncludeConstant." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/LinearRegression/ref/IncludeConstant.html.

APA

Wolfram Language. (2007). IncludeConstant. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/LinearRegression/ref/IncludeConstant.html

BibTeX

@misc{reference.wolfram_2024_includeconstant, author="Wolfram Research", title="{IncludeConstant}", year="2007", howpublished="\url{https://reference.wolfram.com/language/LinearRegression/ref/IncludeConstant.html}", note=[Accessed: 23-December-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_includeconstant, organization={Wolfram Research}, title={IncludeConstant}, year={2007}, url={https://reference.wolfram.com/language/LinearRegression/ref/IncludeConstant.html}, note=[Accessed: 23-December-2024 ]}