Folks could you please advice on how I could overcome the error in my code?
mv1 <- glm(laboratory_result ~ sex + agegroup + location + education + vaccination_status + occupation + admitted + symptomatic + abdominal_pain + anorexia + headache + bloody_stool + dark_urine + fatigue + headache + hemorrhagic_syndrome + jaundice + muscle_pain + bleeding_or_bruising + vomiting, family = "binomial", data = YF_cleaned_2021_logistic)
summary(mv1)
Call:
glm(formula = laboratory_result ~ sex + agegroup + location +
education + vaccination_status + occupation + admitted +
symptomatic + abdominal_pain + anorexia + headache + bloody_stool +
dark_urine + fatigue + headache + hemorrhagic_syndrome +
jaundice + muscle_pain + bleeding_or_bruising + vomiting,
family = "binomial", data = YF_cleaned_2021_logistic)
Deviance Residuals:
Min 1Q Median 3Q Max
-1.2457 -0.2021 -0.0837 -0.0401 3.4361
Coefficients:
Estimate Std. Error z value
(Intercept) -23.45778 3623.17149 -0.006
sex 1.41081 0.53602 2.632
agegroup5-9yrs 0.90863 1.19036 0.763
agegroup10-14yrs 0.85535 1.22165 0.700
agegroup15-29yrs 1.59509 1.16696 1.367
agegroup30-44yrs 0.76105 1.36388 0.558
agegroup45-59yrs 0.92042 1.55063 0.594
agegroup60+yrs -16.03900 2418.17136 -0.007
location 3.31592 0.87080 3.808
education -0.42994 0.87358 -0.492
vaccination_status 0.47937 0.54672 0.877
occupation -0.55896 0.67433 -0.829
admitted -1.87301 1.16829 -1.603
symptomatic 15.04496 3623.17132 0.004
abdominal_pain -0.94245 1.06100 -0.888
anorexia -0.02655 0.64168 -0.041
headache -0.95325 0.59575 -1.600
bloody_stool -15.06238 1958.08924 -0.008
dark_urine 0.65611 0.57284 1.145
fatigue 1.00347 0.60432 1.661
hemorrhagic_syndrome -20.26955 4641.93174 -0.004
jaundice 0.88943 1.03283 0.861
muscle_pain -0.25792 0.86257 -0.299
bleeding_or_bruising 5.53316 2.71797 2.036
vomiting 1.33696 0.77418 1.727
Pr(>|z|)
(Intercept) 0.99483
sex 0.00849 **
agegroup5-9yrs 0.44527
agegroup10-14yrs 0.48382
agegroup15-29yrs 0.17166
agegroup30-44yrs 0.57684
agegroup45-59yrs 0.55279
agegroup60+yrs 0.99471
location 0.00014 ***
education 0.62261
vaccination_status 0.38059
occupation 0.40715
admitted 0.10889
symptomatic 0.99669
abdominal_pain 0.37440
anorexia 0.96699
headache 0.10958
bloody_stool 0.99386
dark_urine 0.25206
fatigue 0.09681 .
hemorrhagic_syndrome 0.99652
jaundice 0.38915
muscle_pain 0.76493
bleeding_or_bruising 0.04177 *
vomiting 0.08418 .
Signif. codes:
0 ‘’ 0.001 ‘’ 0.01 ‘’ 0.05 ‘.’ 0.1 ‘ ’ 1
(Dispersion parameter for binomial family taken to be 1)
Null deviance: 219.89 on 759 degrees of freedom
Residual deviance: 147.18 on 735 degrees of freedom
(12256 observations deleted due to missingness)
AIC: 197.18
Number of Fisher Scoring iterations: 18
final_mv <- mv1 %>%
- step(direction = "forward", trace = FALSE)
Error in length(obj) : class name too long in 'length'
mv_tab_base <- final_mv %>%
- broom::tidy(exponentiate = TRUE, conf.int = TRUE) %>% ## get a tidy dataframe of estimates
- mutate(across(where(is.numeric), round, digits = 2)) ## round
Error in broom::tidy(., exponentiate = TRUE, conf.int = TRUE) :
class name too long in 'tidy'
show results table of final regression
mv_tab <- tbl_regression(final_mv, exponentiate = TRUE)
Error in tbl_regression(final_mv, exponentiate = TRUE) :
class name too long in 'tbl_regression'