R suppressing rownames in grid table

梦想与她 提交于 2020-01-03 07:09:08

问题


I can produce a table with gridExtra:

eg:

    library(gridExtra)
    grid.table(head(iris))

But this produces a rownames column 1:6. Is there a way to be able to suppress the rownames column so that it does not appear in the table?

Thank you for your help.


回答1:


Just add rows = NULL:

grid.table(head(iris), rows = NULL)

Another solution could be setting show.rownames = FALSE

grid.table(head(iris), show.rownames = FALSE)



来源:https://stackoverflow.com/questions/15045396/r-suppressing-rownames-in-grid-table

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!