代码之家  ›  专栏  ›  技术社区  ›  Cina

图例的大小太大,cex没有用处

  •  0
  • Cina  · 技术社区  · 7 年前

    legend('topleft',adj = c(0, 0.6), pch=c(4,1), c("non smokers", "smokers"), cex=.75,horiz = TRUE,pt.cex = 1)
    

    我怎样才能解决这个问题?谢谢

    enter image description here

    1 回复  |  直到 7 年前
        1
  •  1
  •   d.b    7 年前

    首先使用指定打印大小 windows pdf png 一切都会好起来的。下面是一个使用 巴布亚新几内亚

    graphics.off()
    png(filename = "test.png", width = 7, height = 7, units = "in", res = 75)
    plot(1:10, 1:10)
    legend('topleft', pch=c(4,1), c("non smokers", "smokers"), horiz = TRUE)
    dev.off()
    

    enter image description here