From aa3e9f25491a76ec33d949a9a4874fdb85efa3bd Mon Sep 17 00:00:00 2001 From: Yongfu Liao Date: Wed, 24 Jul 2024 18:42:07 +0800 Subject: [PATCH] fix bug --- R/plot_forest.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/R/plot_forest.R b/R/plot_forest.R index 54190ba..df41cb3 100644 --- a/R/plot_forest.R +++ b/R/plot_forest.R @@ -86,7 +86,7 @@ plot_forest = function(dat, labels, shade_inv=c(.25,.75), } if (is.null(center_pos)) { - mx = mean(dat[[i]]) + mx = mean(dat[[i]], na.rm=T) x_err = abs(x - mx) center_pos = which(x_err == min(x_err))[1] my = y[center_pos]