Specify Width and Height of Plot

前端 未结 3 462
感动是毒
感动是毒 2020-12-24 02:44

I have a panel containing three plots. How can I use par to specify the width and height of the main panel so it is always at a fixed size?

3条回答
  •  失恋的感觉
    2020-12-24 03:25

    You do that in the device, e.g.

    x11(width=4, height=6)
    

    and similarly for the file-based ones

    pdf("/tmp/foo.pdf", width=4, height=6)
    

    You can read the physical size via par("cin") etc but not set it.

提交回复
热议问题