I'm trying to change the default panel background colour in the ggplot2 package install on my computer. The current default is 'grey90', and I want to change it to '#E8EDFB'.
I tried to do this by changing the default theme ggplot2 uses, theme_grey.
Using either
fixInNamespace("theme_grey", pos="package:ggplot2")
or
fixInNamespace("theme_grey", ns="ggplot2")
as suggested here, gives me a nice editor where I can change the relevant bit of code:
panel.background = element_rect(fill = "grey90", colour = NA)
I changed "grey90" to '#E8EDFB' and saved. Whenever I re-run one of the commands above, I now again get the editor which indeed shows my edited code instead of the original. However, when I run theme_grey, I just get the original code outputed to my console, not my changed code, and the panel backgrounds on my plots are also still grey.
How do I get my plot panel backgrounds to default to #E8EDFB instead of grey?
NOTE: I want to change the default permanently, not just change the color for one plot or for the session.