title: [[base R]] Have two graphic devices open at the same time, and flip between the two
body: <p>I have a double for loop, as such:</p>
  <pre><code>for (alphabet in c(&quot;A&quot;,&quot;B&quot;)) {
     for (number in c(1,6)) {
        plot(......)
     }
  }
  </code></pre>
  <p>What I wish to do is to have the total of 12 plots arranged in such a way that in the end there are two pngs exported, each one containing {{A1~3,B1~3}} and {{A4~6,B4~6}} respectively.</p>
  <p>I'm not sure where the call to png() should be to achieve this.</p>
  <p>My lab insists that I use base R only..</p>
  <p>Thank you.</p>