# NOT RUN {
set.seed(153)
x <- rnorm(10000)
y <- rnorm(10000)
bin <- hexbin(x,y)
smbin <- smooth.hexbin(bin)
erodebin <- erode.hexbin(smbin, cdfcut=.5)
plot(erodebin)
## bivariate boxplot
hboxplot(erodebin, main = "hboxplot(erodebin)")
# }
# NOT RUN {
<!-- %% MM: This looks wrong -- both the graphic and the logic in "par" here : -->
# }
# NOT RUN {
# show erosion order
plot(bin,style= "lat", minarea=1, maxarea=1,
legend=FALSE, border=gray(.7))
# }
# NOT RUN {
<!-- %% FIXME: {compare with example in "hexbin0"} -->
# }
# NOT RUN {
grid.hexagons(erodebin,style= "lat", minarea=1, maxarea=1,pen="green")
xy <- hcell2xy(erodebin)
library("grid")
grid.text(lab = as.character(erodebin@erode), xy$x, xy$y,
gp = gpar(col="white", cex=0.65))
# }
Run the code above in your browser using DataLab