2012-06-23 31 views
0

我有一個數據框(X,Y,a,b,c,d,e) 是否有一個包可以同時預測X和Y? 感謝您的幫助。R有兩個預測變量的多元迴歸

+0

你可以嘗試這個答案交叉驗證。 http://stats.stackexchange.com/questions/11127/multivariate-multiple-regression-in-r – John

+0

是的,嘗試結構方程建模包'sem' – Andrie

+0

非常感謝。我會試試這個。 –

回答

1

嘗試包的車,?linearHypothesis,例如

a multivariate linear model for repeated-measures data 
see ?OBrienKaiser for a description of the data set used in this example. 

但是,它可能不適合你有真正的X Y。

+0

謝謝,我會試試這個。結果是否比做兩次獨立迴歸更好? –