2022-11-30

data=data.frame(
  name=c("CLNS1A","DUSP3","FANCA","FANCC","HIST1H3B"),
  score=c("3.5390512","-0.922516","2.4478881","2.5756102","0.6622481"),
  class=c("Risk","Protective","Risk","Risk","Risk")
)


data$score=as.numeric(data$score)


ggbarplot(data, x = "name", y = "score",
          ylab = "LASSO coefficient",
          fill = "class",
          color = "white",
          palette=c("#5d5699","#9d0625"),
          sort.val = "asc",
          sort.by.groups = FALSE,
          x.text.angle = 90,          # Rotate vertically x axis texts
          rotate = TRUE,
          ggtheme = theme_pubr())



你可能感兴趣的:(2022-11-30)