Reputation: 1243
I have a following "beeswarm" (a single-dimensional scatterplot)
library(beeswarm)
data(breast)
beeswarm(breast$time_survival,horizontal=TRUE)
Here is the resulting plot:
How can I get rid of the axes and the box around the plot, so that I can reintroduce only the X axis and nothing else around it?
Upvotes: 0
Views: 312
Reputation: 71
You can use the "axes" argument (described in ?plot.default
).
beeswarm(breast$time_survival, horizontal=TRUE, axes = FALSE)
Upvotes: 2
Reputation: 60472
If you create an empty plot first
plot(rnorm(10), type="n", axes=FALSE, xlim=c(0, 200), ylim=c(0.4, 1.6),
xlab="", ylab="")
Then you can use the add
argument to get what you want
beeswarm(breast$time_survival,horizontal=TRUE, add=TRUE)
Upvotes: 2