inst/examples/smoothScatter2.R

# ggplot2 绘制 BinormCircle 数据的平滑散点图
data("BinormCircle", package = "MSG")
library(ggplot2)
library(ggpointdensity)
p = ggplot(data = BinormCircle, aes(x = V1, y = V2)) +
  geom_pointdensity(adjust = 0.1) +
  scale_color_gradient(low="lightblue", high="darkblue") +
  theme(legend.position = "")
print(p)

Try the MSG package in your browser

Any scripts or data that you put into this service are public.

MSG documentation built on July 22, 2021, 1:06 a.m.