0

I used ggplot to output two pictures. They share the same x-scale.

enter image description here

The problem is that the two x-scales don't align accurately. I wonder which argument should I use to get the horizontal alignment of the two x-scales.

scoa
  • 19,359
  • 5
  • 65
  • 80
mcxmcx
  • 13
  • 1
  • 3
  • I used ggplot2 to output two pictures in one paper. Both of them share the same x-scale. The problem is that the two x-scales don't align accurately. I wonder which argument should I use to get the horizontal alignment of the two x-scales. Attached below is the plot. Many thanks for the kind help! Best Cheers Chenxi – mcxmcx May 03 '17 at 08:04
  • please share the data and code you used to produce the plot : http://stackoverflow.com/a/5963610/4132844 – scoa May 03 '17 at 08:22
  • you need to use `+ facet_grid()` for generating the plot with more than one panel in one figure. the option `scale = "free_y"` allows you to use separate scales for y-axis. – amatsuo_net May 03 '17 at 08:25

0 Answers0