0

I'd like to place some text in my scatterplot, which I made with ggplot like you can see in the top left corner of the plot:

The text is now showing "Text" and "Variable", but should show more "Text" after the "Variable" and should be left aligned:

enter image description here

The requirements are:

  • It must have the format "Text" "Variable" "Text"
  • I need two or three rows
  • The rows should be left-aligned

What I did is using this code, but it might be not adequate for my intentions:

  p1 + annotate(geom="text", x=1, y = 15, col="black",
           label=paste("atop(' Mean diff = '*",bias,",'SD of diff = '*",sd,")"), parse=T) 
zx8754
  • 52,746
  • 12
  • 114
  • 209
EmKau
  • 91
  • 5
  • Please visit [How to make a great R reproducible example](https://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example) – UseR10085 Jul 15 '20 at 07:52
  • Read about [ggtext](https://cran.r-project.org/web/packages/ggtext/vignettes/plotting_text.html). – zx8754 Jul 15 '20 at 07:54

0 Answers0