Quantcast
Channel: Active questions tagged r - Stack Overflow
Viewing all articles
Browse latest Browse all 202012

Add text in between multiple plots

$
0
0

I am plotting 5 rasters side by side. The figure represents a linear regression model, and so the plot should represent r1 ~ r2 + r3 + r4 + r5. I am using par() to line up the 5 rasters and would like to now add the text signs ~,+,+,+ on top in the white gaps.

Example of a multiplot:

par(mfrow = c(1,5))
plot(1, type="n", xlab="", ylab="", xlim=c(0, 10), ylim=c(0, 10))
plot(1, type="n", xlab="", ylab="", xlim=c(0, 10), ylim=c(0, 10))
plot(1, type="n", xlab="", ylab="", xlim=c(0, 10), ylim=c(0, 10))
plot(1, type="n", xlab="", ylab="", xlim=c(0, 10), ylim=c(0, 10))
plot(1, type="n", xlab="", ylab="", xlim=c(0, 10), ylim=c(0, 10))

Example with empty plots

Desired outcome (example created in MS Paint): Desired example


Viewing all articles
Browse latest Browse all 202012

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>