Box-Cox Transformation for Regression
Box-Cox transformation for regression chooses the power lambda for transforming a positive outcome by maximising the profile likelihood of the linear model, with a likelihood-ratio interval.
회귀의 Box-Cox 변환은 선형모형의 프로파일 우도를 최대로 하는 거듭제곱 λ를 골라 양수 결과변수를 변환하고, 우도비로 λ의 신뢰구간을 구하는 방법입니다.
My regression residuals are right-skewed; should I log-transform the outcome or use some other power?
회귀 잔차가 오른쪽으로 치우쳐 있는데, 결과변수를 로그 변환해야 할까요, 다른 변환을 써야 할까요?
The Box-Cox procedure fits the regression for a range of power transformations of the outcome and picks the lambda that maximises the profile log-likelihood. Its confidence interval shows which convenient transformations, such as the logarithm or square root, are consistent with the data.
When to use Box-Cox Transformation for Regression
- A positive continuous outcome has skewed or heteroskedastic residuals.
- A choice between the log, square-root or no transformation needs evidence.
- A variance-stabilising transformation is wanted before a linear model.
When to use something else
- The outcome has zero or negative values; use the Yeo-Johnson transformation or a generalized linear model.
- Effects must be interpreted on the original scale; use a gamma or log-link generalized linear model.
Assumptions and requirements
- The outcome is strictly positive.
- Some power transformation makes the errors approximately normal and homoskedastic.
- The linear predictor is correctly specified.
What the analysis reports
- Maximum-likelihood lambda with likelihood-ratio confidence interval
- Suggested convenient lambda inside the interval
- Likelihood-ratio tests of lambda = 1 and lambda = 0
- Regression refitted on the transformed outcome; residual normality before and after
How to report it
The Box-Cox profile likelihood gave lambda = [value], 95% CI [[value], [value]]; the model was refitted with lambda = [value] (chi2(1) = [value] for no transformation, p = [value]).
Related methods
- Multiple Linear Regression
- Gamma Regression
- Yeo-Johnson Transformation
Run Box-Cox Transformation for Regression on Quorant
- Data you need
- a table (CSV or Excel) with an outcome variable and predictor (feature) columns
- Price
- 250 credits for one analysis up to 10,000 rows (complexity level 2); larger or wider data costs more. Optional methodologist review: 1200 credits.
- Checking
- Checked by property tests in every deployment
- Before you pay
- A free pre-analysis diagnosis checks your data and gives an exact quote; nothing is deducted until you approve it.