1
當y軸不均勻時,如何製作熱圖(或者如果它被稱爲別的東西)?我也願意插值,但最好沒有它。如何製作Y軸不均勻的熱圖?
當我在均勻的時間間隔層,我可以積以此來獲得以下
ggplot(a, aes(x=time, y=Layer, fill = Value))+
geom_tile()+
scale_fill_gradient2(low="blue",mid="yellow",high="red", midpoint=0.5)+
theme_bw()
圖不過,我不能繼續當層1-10的自然數是沒有的。
dput(droplevels(head(smx,10)))
structure(list(value = c(5.4023420028113e-07, 5.4023420028113e-07,
5.4023420028113e-07, 5.4023420028113e-07, 5.4023420028113e-07,
5.4023420028113e-07, 5.4023420028113e-07, 6.74006442227979e-08,
6.74006442227979e-08, 6.74006442227979e-08),
time = structure(c(17156, 17156, 17156, 17156, 17156, 17156, 17156, 17162,
17162, 17162),
class = "Date"),
layer = c(0.0120349472577243, 0.0177233992991887, 0.00844582491793334,
0.00756873916071316, 0.0437965816456147, 0.0168056962032031,
0.0181395468747096, 0.0120349472577243, 0.0177233992991887,
0.00844582491793334)),
.Names = c("value", "time", "layer"),
row.names = c(NA, 10L),
class = "data.frame")
FULL數據將在此處
當您嘗試繪製數據時出了什麼問題,以及您希望最終情節看起來如何? – Marius
基本上,我得到了水平線和沒有塊。最後的情節應該像我附加的那個,但基本上,不規則大小的塊無處不在... – maximusdooku
因此,瓷磚應該覆蓋整個陰謀區域,或掩蓋下一個瓷磚的底部?您需要考慮數據中的時間和圖層值如何映射到要查看的圖塊。 – Marius