How to compare a coefficient from two regression

22 vues (au cours des 30 derniers jours)
woraphon wattanatorn
woraphon wattanatorn le 12 Sep 2019
Modifié(e) : Adam Danz le 23 Sep 2019
Dear Folk,
I would like to compare a coefficient between two regression (from difference group but same model)
For example,
I would like to compare
Y=a0+B1X1+B2X2+B3X3+B4X4 for Sample group A
Y=a0+B1X1+B2X2+B3X3+B4X4 for Sample group B
I want to test whether B3 group A is significantly different from B3 group B or not
Please kindly suggest
Worapho

Réponses (1)

Adam Danz
Adam Danz le 12 Sep 2019
Modifié(e) : Adam Danz le 23 Sep 2019
One way would be to compute the 95% confidence interval of the regression coefficients and determine whether they overlap (which would confirm the null hypothesis). If and only if your data do not have significant outliers, you can use the coefCI function which assumes an approximately normal distribution of error.
% mdl is the linear regression model
% CI is an nx2 matrix of [low,high] CI endpoints for each n coefficient
ci = coefCI(mdl)

Catégories

En savoir plus sur Descriptive Statistics dans Help Center et File Exchange

Produits

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by