在附加的热图中,我想通过在相应的图块上显示悬停气泡(或多个构面的图块)来了解整个构面中相同坐标的值。 Tableau可以很好地显示跨图表的数据值。 plot.ly也可以这样做吗?
library(plotly)
library(dplyr)
heat2 <- structure(list(row = c(10L, 10L, 10L, 10L, 10L, 10L, 11L, 11L, 11L, 11L, 11L, 11L, 12L, 12L, 12L, 12L, 12L, 12L, 13L, 13L, 13L, 13L, 13L, 13L, 14L, 14L, 14L, 14L, 14L, 14L, 15L, 15L, 15L, 15L, 15L, 15L, 16L, 16L, 16L, 16L, 16L, 16L, 17L, 17L, 17L, 17L, 17L, 17L, 18L, 18L, 18L, 18L, 18L, 18L, 10L, 10L, 10L, 10L, 10L, 10L, 11L, 11L, 11L, 11L, 11L, 11L, 12L, 12L, 12L, 12L, 12L, 12L, 13L, 13L, 13L, 13L, 13L, 13L, 14L, 14L, 14L, 14L, 14L, 14L, 15L, 15L, 15L, 15L, 15L, 15L, 16L, 16L, 16L, 16L, 16L, 16L, 17L, 17L, 17L, 17L, 17L, 17L, 18L, 18L, 18L, 18L, 18L, 18L), col = c(10L, 11L, 12L, 13L, 14L, 15L, 10L, 11L, 12L, 13L, 14L, 15L, 10L, 11L, 12L,13L, 14L, 15L, 10L, 11L, 12L, 13L, 14L, 15L, 10L, 11L, 12L, 13L,14L, 15L, 10L, 11L, 12L, 13L, 14L, 15L, 10L, 11L, 12L, 13L, 14L,15L, 10L, 11L, 12L, 13L, 14L, 15L, 10L, 11L, 12L, 13L, 14L, 15L,10L, 11L, 12L, 13L, 14L, 15L, 10L, 11L, 12L, 13L, 14L, 15L, 10L,11L, 12L, 13L, 14L, 15L, 10L, 11L, 12L, 13L, 14L, 15L, 10L, 11L,12L, 13L, 14L, 15L, 10L, 11L, 12L, 13L, 14L, 15L, 10L, 11L, 12L,13L, 14L, 15L, 10L, 11L, 12L, 13L, 14L, 15L, 10L, 11L, 12L, 13L,14L, 15L), height = c(0, 0, 0, 0, 0, 0, 1.8, 1.6, 0.6, 1.6, 2.8,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, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L), coord = c("10:10", "10:11", "10:12","10:13", "10:14", "10:15", "11:10", "11:11", "11:12", "11:13", "11:14", "11:15", "12:10", "12:11", "12:12", "12:13", "12:14", "12:15", "13:10", "13:11", "13:12", "13:13", "13:14", "13:15", "14:10", "14:11", "14:12", "14:13", "14:14", "14:15", "15:10", "15:11", "15:12", "15:13", "15:14", "15:15", "16:10", "16:11", "16:12", "16:13", "16:14", "16:15", "17:10", "17:11", "17:12", "17:13", "17:14", "17:15", "18:10", "18:11", "18:12", "18:13", "18:14", "18:15", "10:10", "10:11", "10:12", "10:13", "10:14", "10:15", "11:10", "11:11", "11:12", "11:13", "11:14", "11:15", "12:10", "12:11", "12:12", "12:13", "12:14", "12:15", "13:10", "13:11", "13:12", "13:13", "13:14", "13:15", "14:10", "14:11", "14:12", "14:13", "14:14", "14:15", "15:10", "15:11", "15:12", "15:13", "15:14", "15:15", "16:10", "16:11", "16:12", "16:13", "16:14", "16:15", "17:10", "17:11", "17:12", "17:13", "17:14", "17:15", "18:10", "18:11", "18:12", "18:13", "18:14", "18:15")), class = "data.frame", .Names = c("row", "col", "height", "marker", "bin", "coord"), row.names = c(NA, -108L))
p <- ggplot(heat2, aes(x=col, y=row, fill=height))+
geom_tile()+
geom_point(data = filter(heat2, marker != 0), aes(color = factor(marker)), size = 0.75)+
facet_grid(.~bin)
ggplotly(p)