79074047

Date: 2024-10-10 10:58:15
Score: 2
Natty:
Report link

I have been scouring the internet for ways to make a ggplot graph on R include the text 0.30 rather than 0.3. After about 2 hours (and not managing to get anything to work), I tried something very simple and it did what I wanted it to... I simply put '' around the 0.30 as such:

 annotate("text", x = 50, y = 44, 
       label="italic(R^2)=='0.30'", parse=TRUE, size = 6, colour="#56B4E9") 

Worked a treat! Hope this is helpful for others :)

Reasons:
  • Blacklisted phrase (1): Worked a treat
  • Has code block (-0.5):
  • Unregistered user (0.5):
  • Low reputation (1):
Posted by: JamieS