0

So I built my logistic regression model using glm(). When I display the summary I get this with values for each variable.

Coefficients:
            Estimate Std. Error z value Pr(>|z|) 

After I have set a restriction using linearHypotheses but I only get results for chisquared, residuals df, and df. Am I able to see what the coefficients are for the model with the restriction?

library(car)
library(tidyverse)
library(dplyr)

logitmodel <- glm(x~ratio+x+y, family=binomial(link="logit"))

nullhypothese <- "x=0"
restrictedmodel <- linearHypothesis(logitmodel, nullhypothesis)
StupidWolf
  • 45,075
  • 17
  • 40
  • 72
  • 1
    It's easier to help you if you include a simple [reproducible example](https://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example) with sample input and desired output that can be used to test and verify possible solutions. List all non-base R packages you are using. – MrFlick May 02 '21 at 17:57
  • While building the model why is the dependent variable `x` also considered as independent variable? `glm(x~ratio+x+y, family=binomial(link="logit"))` – Isa Dec 05 '21 at 13:57

0 Answers0