Dear all,

I am trying to plot a model using sjPlot. however when doing it, error bars
are non-centered.    I  wanted  to  know  if somebody knows how to plot it.

Many thanks!!

###Script

Copy data from here
https://docs.google.com/spreadsheets/d/1VixfgDWql7BOOPxqw2ElOLmfVcXP1soKR8-FmLlkgOU/edit?usp=sharing


dat <- read.delim("clipboard", dec=","); attach(dat)# Copy data before
library(sjPlot)
library(geepack)
library(ggplot2)

m1 <- geeglm(
  formula = Consumo~Presa+Sexo,
  family = binomial,
  data = dat,
  id = Id1,
  corstr = "exchangeable"
)

plot_model(m1, type = "pred", terms = c("Presa","Sexo"),
           colors = c("blue", "magenta3","red"),) +
  geom_bar (position=position_dodge(), stat = "identity", width=0.5, alpha
= 0.3) +
  coord_cartesian(ylim=c(0,2))

        [[alternative HTML version deleted]]

_______________________________________________
R-sig-ecology mailing list
R-sig-ecology@r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-ecology

Reply via email to