1

I have a plot in R using the 'plot()' function.

My current plot

I would like to add a square backing to the plot (so that it looks like it is drawn on square paper), to help with readability. How can I do this? An example of what I mean would be the light gray lines seen is this desmos plot:

What I would like to see

Any suggestions? Thanks

James Ashwood
  • 469
  • 6
  • 13
  • 3
    Call [grid](https://stat.ethz.ch/R-manual/R-devel/library/graphics/html/grid.html) function after plot, e.g. `grid(nx=NULL,ny=NULL,col="lightgray",lty="dotted",lwd=par("lwd"),equilogs=TRUE)` – digEmAll Jul 10 '22 at 11:09
  • @digEmAll thanks! Worked a treat. Add it as an answer if you want. :) – James Ashwood Jul 10 '22 at 11:39

0 Answers0