Removes the specified predictors from the model, and recalculates the model parameters.

Namespace:  CenterSpace.NMath.Stats
Assembly:  NMathStats (in NMathStats.dll) Version: 3.4.0.0

Syntax

C#
public void RemovePredictors(
	int startIndex,
	int numberToRemove
)
Visual Basic (Declaration)
Public Sub RemovePredictors ( _
	startIndex As Integer, _
	numberToRemove As Integer _
)
Visual C++
public:
void RemovePredictors(
	int startIndex, 
	int numberToRemove
)

Parameters

startIndex
Type: System..::.Int32
The first predictor to remove.
numberToRemove
Type: System..::.Int32
The total number of predictors to remove.

Remarks

Indexing starts at 0. If the model has an intercept parameter, removing the 0th predictor will not remove the intercept parameter. Instead, use the RemoveInterceptParameter() method to remove the intercept parameter.

Examples

If startIndex = 1 and numberToRemove = 3, then the second, third, and fourth predictors are removed.

Exceptions

ExceptionCondition
CenterSpace.NMath.Core..::.IndexOutOfRangeExceptionThrown if the specified index range is invalid.

See Also