R save table as image

后端 未结 3 1297
时光取名叫无心
时光取名叫无心 2020-12-10 01:36

I would like to export a data frame as a (png) image. I\'ve tried with this code, but the table get clipped vertically.

library(ggplot2)
library(gridExtra)

         


        
3条回答
  •  执念已碎
    2020-12-10 02:12

    You can do like this:

    library(gridExtra)
    png("test.png", height = 50*nrow(df), width = 200*ncol(df))
    grid.table(df)
    dev.off()
    

提交回复
热议问题