R: function to scale ggplot2, lattice or base R graph proportionally
问题 In R I always find it annoying that base R, lattice and ggplot2 plots all work with absolute point sizes for the size of text and plot symbols. This means that if you increase say the size of your plot window to get a page-filling graph from windows(width=5,height=5);qplot(Sepal.Length, Petal.Length, data = iris, color = Species, size = Petal.Width, alpha = I(0.7)) to windows(width=10,height=10);qplot(Sepal.Length, Petal.Length, data = iris, color = Species, size = Petal.Width, alpha = I(0.7)