ich vergleiche Koeffizienten von Regressionen mit Hilfe des Wald-Tests. Dazu nutze ich linearHypothesis() aus {car}. Nun will ich aber eigentlich nicht testen, ob die Koeffizienten gleich sind, sondern ob z.B. ein Koeffizient größer oder kleiner als ein anderer ist – also einseitige Tests machen. Das geht aber nicht. Ich weiß bloß nicht wieso!
Z.B. bei den folgenden Daten aus dem stats-Package:
Code: Alles auswählen
model = lm(Fertility ~ ., data = swiss)
summary(model)
linearHypothesis(model, "Agriculture = Catholic")
linearHypothesis(model, "Agriculture < Catholic")
linearHypothesis(model, "Agriculture <= Catholic")
Hat da jemand eine Idee?Alternatively, the hypothesis can be specified symbolically as a character vector with one or more elements, each of which gives either a linear combination of coefficients, or a linear equation in the coefficients (i.e., with both a left and right side separated by an equals sign). Components of a linear expression or linear equation can consist of numeric constants, or numeric constants multiplying coefficient names (in which case the number precedes the coefficient, and may be separated from it by spaces or an asterisk); constants of 1 or -1 may be omitted. Spaces are always optional. Components are separated by plus or minus signs.
Beste Grüße