Stacks Image 20108

For Academics

Plotting with panels and labelling

It is easy to produce figures with multiple panels in R.

For example for four panels:

par(mfrow=c(2,2))

Every new plot call, will add a plot to the next panel in the 2 by 2 table generated. Once all panels are filled, they are erased and the plots are added from the beginning.

It is not easy to label each panel.

One way is to add text in a specific non-standard place:

mtext("A", side=3, line=1, adj=0, font=2, cex=2)

This is nice as the text is added automatically and is always in the same relative location in the different panels.

A more flexible way is to add text after clicking on the graph. However this is a manual process:

par(mfrow=c(1,2)) 
plot(x~y) 
text(locator(1),"A") 
plot(x~z) 
text(locator(1),"B")
Previous Post 25 / 50 Post

Tag:

Sex chromosome papers RSS


Investigating the evolution of large meiotic rings of multiple X and Y sex chromosomes in two Leptodactylus frog species (Anura, Leptodactylidae)
Link

A chromosome level genome assembly of the marine flowering plant, Torrey's surfgrass (Phyllospadix torreyi) reveals an exceptionally large Y-chromosome
Link

The genome sequence of the Knapweed Pearl, Paratalanta hyalinalis (Hübner, 1796) (Lepidoptera: Crambidae)
Link