**Navigation**

manual:linear_regression

Power calculation / sample size planning for linear regression based on F test.

Among sample size, number of predictors, effect size, significance level, and power, one and only one can be left blank.

Provide the number of observations per group. Multiple sample sizes can be provided in two ways. First, multiple sample sizes can be supplied separated by white spaces, e.g., `100 150 200`

will calculate power for the three sample sizes. A sequence of sample sizes can be generated using the method `s:e:i`

with `s`

denoting the starting sample size, `e`

as ending sample size, and `i`

as the interval. For example, `100:150:10`

will generate a sequence `100 110 120 130 140 150`

.

By default, the sample size is `100`

.

The effect size to be used. Multiple effect sizes or a sequence of effect sizes can be supplied using the same method for sample size. By default, the value is `0.15`

.

f2 is the effect size measure as in Cohen (1988) that evaluates the impact of a set of predictors on an outcome. \[ f^{2}=\frac{R^{2}}{1-R^{2}} \] where $R^{2}$ is population $R^{2}$ of regression analysis.

When we are evaluating the impact of one set of predictors above and beyond a second set of predictors (or covariates). \[ f^{2}=\frac{R_{AB}^{2}-R_{A}^{2}}{1-R_{AB}^{2}} \] where

- $R_{A}^{2}$ is variance accounted for by variable set A
- $R_{AB}^{2}$ is variance accounted for by variable set A and variable set B together.

Cohen suggests $f^{2}$ values of 0.02, 0.15, and 0.35 represent small, medium, and large effect sizes.

For a regression model with $p$ predictor, the numerator df $u=p$ and the denominator df $v=n-p-1$. If we compare two regression models, first with $p1$ predictors (smaller model) and the second with $p2$ predictors (larger model), then u=$p2-p1$ and $v=n-p2-1$. Note that $f^{2}$ is often calculated from R-squared. For example, if $R^{2}$ is .4, then $f^{2}$=.67.

By clicking the show button, a table is show to calculate the effect size and number of predictors based on the $R^2$.

The number of predictors for the reduced model (0 if for testing all predictors in a model) and full model.

The significance level (Type I error rate) for power calculation withe the default `0.05`

.

The power of the test.

Whether to generate the power curve.

A note (less than 200 characters) can be provided to provide basic information on the analysis.

manual/linear_regression.txt · Last modified: 2017/01/17 16:15 by 10.45.80.140