In order to save space, I prefer to avoid coordinates in the plot
generated by ggRGB. Is there any way? I've tried:
ggplot() +
ggRGB(rlogo, r=1, g=2, b=3,ggLayer=TRUE) +
theme(
axis.text = element_blank(),
axis.ticks = element_blank(),
axis.title = element_blank())
but get an empty plot.
I can circumvent the problem as follows, but it is kind of ugly and complicated,
there must be another way:
a <- as(extent(rlogo), 'SpatialPolygons')
y <- fortify(a,region=id)
ggplot(data=y,aes(y=lat, x=long)) +
ggRGB(rlogo, r=1, g=2, b=3,ggLayer=TRUE) +
geom_polygon(colour="yellow", fill=NA) +
guides(fill=FALSE) +
coord_fixed(ratio=1) +
theme(
axis.text = element_blank(),
axis.ticks = element_blank(),
axis.title = element_blank())
Agus
_______________________________________________
R-sig-Geo mailing list
[email protected]
https://stat.ethz.ch/mailman/listinfo/r-sig-geo