How to compare a coefficient from two regression

25 visualizzazioni (ultimi 30 giorni)
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

Risposte (1)

Adam Danz
Adam Danz il 12 Set 2019
Modificato: Adam Danz il 23 Set 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)

Categorie

Scopri di più su Descriptive Statistics in Help Center e File Exchange

Prodotti

Community Treasure Hunt

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

Start Hunting!

Translated by