scikits.statsmodels.regression.RegressionResults

class scikits.statsmodels.regression.RegressionResults(model, params, normalized_cov_params=None, scale=1.0)

This class summarizes the fit of a linear regression model.

It handles the output of contrasts, estimates of covariance, etc.

Returns :

**Attributes** :

aic :

Aikake’s information criteria

System Message: WARNING/2 (-2llf + 2(df_model+1))

latex exited with error: [stderr] [stdout] This is pdfTeXk, Version 3.1415926-1.40.9 (Web2C 7.5.7) %&-line parsing enabled. entering extended mode (./math.tex LaTeX2e <2005/12/01> Babel <v3.8l> and hyphenation patterns for english, usenglishmax, dumylang, noh yphenation, loaded. (/usr/share/texmf-texlive/tex/latex/base/article.cls Document Class: article 2005/09/16 v1.4f Standard LaTeX document class (/usr/share/texmf-texlive/tex/latex/base/size12.clo)) (/usr/share/texmf-texlive/tex/latex/base/inputenc.sty ! LaTeX Error: File `utf8x.def’ not found. Type X to quit or <RETURN> to proceed, or enter new name. (Default extension: def) Enter file name: ! Emergency stop. <read *> l.128 \endinput ^^M No pages of output. Transcript written on math.log.

bic :

Bayes’ information criteria

System Message: WARNING/2 (-2llf + \log(n)(df_model+1))

latex exited with error: [stderr] [stdout] This is pdfTeXk, Version 3.1415926-1.40.9 (Web2C 7.5.7) %&-line parsing enabled. entering extended mode (./math.tex LaTeX2e <2005/12/01> Babel <v3.8l> and hyphenation patterns for english, usenglishmax, dumylang, noh yphenation, loaded. (/usr/share/texmf-texlive/tex/latex/base/article.cls Document Class: article 2005/09/16 v1.4f Standard LaTeX document class (/usr/share/texmf-texlive/tex/latex/base/size12.clo)) (/usr/share/texmf-texlive/tex/latex/base/inputenc.sty ! LaTeX Error: File `utf8x.def’ not found. Type X to quit or <RETURN> to proceed, or enter new name. (Default extension: def) Enter file name: ! Emergency stop. <read *> l.128 \endinput ^^M No pages of output. Transcript written on math.log.

pinv_wexog :

See specific model class docstring

centered_tss :

The total sum of squares centered about the mean

cov_HC0 :

See HC0_se below. Only available after calling HC0_se.

cov_HC1 :

See HC1_se below. Only available after calling HC1_se.

cov_HC2 :

See HC2_se below. Only available after calling HC2_se.

cov_HC3 :

See HC3_se below. Only available after calling HC3_se.

df_model : :

Model degress of freedom. The number of regressors p - 1 for the constant Note that df_model does not include the constant even though the design does. The design is always assumed to have a constant in calculating results for now.

df_resid :

Residual degrees of freedom. n - p. Note that the constant is included in calculating the residual degrees of freedom.

ess :

Explained sum of squares. The centered total sum of squares minus the sum of squared residuals.

fvalue :

F-statistic of the fully specified model. Calculated as the mean squared error of the model divided by the mean squared error of the residuals.

f_pvalue :

p-value of the F-statistic

fittedvalues :

The predicted the values for the original (unwhitened) design.

het_scale :

Only available if HC#_se is called. See HC#_se for more information.

HC0_se :

White’s (1980) heteroskedasticity robust standard errors. Defined as sqrt(diag(X.T X)^(-1)X.T diag(e_i^(2)) X(X.T X)^(-1) where e_i = resid[i] HC0_se is a property. It is not evaluated until it is called. When it is called the RegressionResults instance will then have another attribute cov_HC0, which is the full heteroskedasticity consistent covariance matrix and also het_scale, which is in this case just resid**2. HCCM matrices are only appropriate for OLS.

HC1_se :

MacKinnon and White’s (1985) alternative heteroskedasticity robust standard errors. Defined as sqrt(diag(n/(n-p)*HC_0) HC1_se is a property. It is not evaluated until it is called. When it is called the RegressionResults instance will then have another attribute cov_HC1, which is the full HCCM and also het_scale, which is in this case n/(n-p)*resid**2. HCCM matrices are only appropriate for OLS.

HC2_se :

MacKinnon and White’s (1985) alternative heteroskedasticity robust standard errors. Defined as (X.T X)^(-1)X.T diag(e_i^(2)/(1-h_ii)) X(X.T X)^(-1) where h_ii = x_i(X.T X)^(-1)x_i.T HC2_se is a property. It is not evaluated until it is called. When it is called the RegressionResults instance will then have another attribute cov_HC2, which is the full HCCM and also het_scale, which is in this case is resid^(2)/(1-h_ii). HCCM matrices are only appropriate for OLS.

HC3_se :

MacKinnon and White’s (1985) alternative heteroskedasticity robust standard errors. Defined as (X.T X)^(-1)X.T diag(e_i^(2)/(1-h_ii)^(2)) X(X.T X)^(-1) where h_ii = x_i(X.T X)^(-1)x_i.T HC3_se is a property. It is not evaluated until it is called. When it is called the RegressionResults instance will then have another attribute cov_HC3, which is the full HCCM and also het_scale, which is in this case is resid^(2)/(1-h_ii)^(2). HCCM matrices are only appropriate for OLS.

model :

A pointer to the model instance that called fit() or results.

mse_model :

Mean squared error the model. This is the explained sum of squares divided by the model degrees of freedom.

mse_resid :

Mean squared error of the residuals. The sum of squared residuals divided by the residual degrees of freedom.

mse_total :

Total mean squared error. Defined as the uncentered total sum of squares divided by n the number of observations.

nobs :

Number of observations n.

normalized_cov_params :

See specific model class docstring

params :

The linear coefficients that minimize the least squares criterion. This is usually called Beta for the classical linear model.

pvalues :

The two-tailed p values for the t-stats of the params.

resid :

The residuals of the model.

rsquared :

R-squared of a model with an intercept. This is defined here as 1 - ssr/centered_tss

rsquared_adj :

Adjusted R-squared. This is defined here as 1 - (n-1)/(n-p)*(1-rsquared)

scale :

A scale factor for the covariance matrix. Default value is ssr/(n-p). Note that the square root of scale is often called the standard error of the regression.

ssr :

Sum of squared (whitened) residuals.

stand_errors :

The standard errors of the parameter estimates.

uncentered_tss :

Uncentered sum of squares. Sum of the squared values of the (whitened) endogenous response variable.

wresid :

The residuals of the transformed/whitened regressand and regressor(s)

Methods

cov_params([r_matrix, column, scale, other]) Returns the variance/covariance matrix.
conf_int([alpha, cols]) Returns the confidence interval of the fitted parameters.
f_test(r_matrix[, scale, invcov]) Compute an Fcontrast/F-test for a contrast matrix.
norm_resid() Residuals, normalized to have unit length and unit variance.
summary([yname, xname]) returns a string that summarizes the regression results
t([column]) Return the t-statistic for a given parameter estimate.
t_test(r_matrix[, scale]) Compute a tcontrast/t-test for a row vector array.

Previous topic

scikits.statsmodels.regression.yule_walker

Next topic

scikits.statsmodels.regression.RegressionResults.cov_params

This Page