我想在我的森林图中区分统计显着性(OR = 1.0)和临床显着性(OR = 1.5)。我使用 forestplot 包创建了这个图,示例代码如下。是否可以添加垂直线(同时保持没有差异的线)?
library(forestplot)
test_data <- structure(list(
mean = c(NA, NA, 1, 0.5, 2),
lower = c(NA, NA, .5, .25, 1.5),
upper = c(NA, NA, 1.5, .75, 2.5)),
.Names = c("mean", "lower", "upper"),
row.names = c(NA, -5L),
class = "data.frame")
tabletext <- cbind(
c("", "Outcome", "Outcome 1", "Outcome 2", "Outcome 3"),
c("", "OR", "1 (0.5 - 1.5)", "0.5 (0.25 - 0.75)", "2.0 (1.5 - 2.5)"))
forestplot(tabletext,
test_data,
new_page = TRUE,
xlog = TRUE,
boxsize = .25
)