# Do the statistical testing results of a transformed variable apply to the original variable?

Suppose a variable is transformed, and a statistical test is applied to the transformed variable. Do the results of the test (specifically, p-value) apply to the original variable?

For example, suppose I have a variable which does not appear normal - but it does appear normal after log-transformation. So I apply log to the variable, and perform a statistical test (for example a t-test, or an Anova with a post-hoc test).

If the statistical test gives a pvalue < 0.05 can I declare that the original variable is statistically significant between conditions?

If the answer is yes, then why so? If the answer is no, then what is the use of data transformation?

• What is the use of data transformation? is a good question -- with many answers here. Commented Mar 28, 2021 at 15:32
• Answers here will depend on the context, can you provide some? Commented Mar 30, 2021 at 16:43

If the statistical test gives a $$p$$ value < 0.05 can I declare that the original variable is statistically significant between conditions?

No.

Assuming you are using a linear regression model, and you log-transformed the predictor (although the same applies when you log-transformed the response): the $$p$$ value tests the null hypothesis of no linear association between predictor and response. With a $$p$$ value < 0.05 (assuming an $$\alpha$$ level of 0.05) you would reject the null hypothesis of no linear association. If you have log-transformed the original predictor variable, then you would thus reject the null hypothesis of no linear association between the log-transformed predictor and the response. This tells us little if anything about the statistical significance of a linear association between the original predictor and the response.

The answer to your question would be yes only for linear transformations of the predictor (and/or response). Then you would obtain the exact same $$p$$ value before and after transformations.

Transformation of the predictor(s) can be helpful, for example, if you do not expect a linear association between the original predictor and response, but a different shape of association. This is the underlying idea of generalized additive models. Note that linear regression with normally distributed errors does not assume the response variable to be normally distributed; only the residuals. Transforming the response might complicate interpretability of the resulting model, and might not be necessary.

• This omits an important case. Results based on ranks of original data and on ranks of monotonically transformed data are the same, as the ranks are the same. This may seem trivially obvious, but I've seen questions on CV about whether that is true. Commented Mar 28, 2021 at 15:07
• @NickCox True. That's why I specified 'assuming you are using a linear regression model'. As the question referred to a variable that did not appear to follow a normal distribution, as well as ANOVA and t-tests, I assumed this is not about computing rank correlations. Commented Mar 28, 2021 at 15:14
• Indeed, but the question made no such restriction. And you generalised beyond linear models in your last paragraph, which was fine, but inevitably not comprehensive. Commented Mar 28, 2021 at 15:31
• @nickcox I agree. I am making some assumptions pending further info; will leave it to question asker if this is helpful or not. Commented Mar 28, 2021 at 15:47
• The answer could still need some reservations, for instance for a two groups t-test of null of no difference in means, a log transformation (of both groups) would (at least approximately) preserve that hypothesis. Exactly if the null is identical distributions. Commented Mar 30, 2021 at 16:45