Rogue Wave banner
Previous fileTop of DocumentContentsIndex pageNext file
Business Analysis Module Reference Guide
Rogue Wave web site:  Home Page  |  Main Documentation Page

RWLinearRegressionFTest


Does not inherit

Local Index

Members

Synopsis

#include <rw/math/genmat.h>
#include <rw/math/mathvec.h>
#include <rw/analytics/linregress.h>
#include <rw/analytics/lrftest.h>

RWGenMat<double> predictorMatrix;
RWMathVec<double> observationVector;
RWLinearRegression lr(predictorMatrix, observationVector);
RWLinearRegressionFTest ftest(lr);

Description

Class RWLinearRegressionFTest can be used to test that the estimated parameters in a linear regression model are equal to a hypothesized vector of values. For example, it can test the hypothesis that all parameters are equal to 0. To be completely precise, the class tests the hypothesis that the estimated parameters are the solution to some specified system of linear equations. The test is based on the F statistic described in Section 3.2, "Multiple Linear Regression," in the Business Analysis Module User's Guide.

Example

The following example creates a linear regression object and tests the hypothesis that all parameters are equal to 0 at a confidence level of 99 percent.

Public Constructors

RWLinearRegressionFTest();
RWLinearRegressionFTest(const RWLinearRegressionFTest<T>& t);
RWLinearRegressionFTest(const RWLinearRegression<T>& lr);
RWLinearRegressionFTest(const RWLinearRegression& lr,
                        const RWGenMat<double>& A, 
                        const RWMathVec<double>& c);

Public Member Functions

double 
criticalValue(double alpha) const;
double
FStatisticPValue() const;
double 
FStatisticValue() const;
bool 
reject(double alpha=.05);
void 
setHypothesis(const RWGenMat<double>& A,
              const RWMathVec<double>& c);
void 
setLinearRegression(const RWLinearRegression& lr);

Public Member Operator

RWLinearRegressionFTest& 
operator=(const RWLinearRegressionFTest& ft);


Previous fileTop of DocumentContentsIndex pageNext file

© Copyright Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.