read.xlsx2 ignores headless column, read.xlsx doesn't

64 views
Skip to first unread message

ulrik....@gmail.com

unread,
Mar 17, 2014, 11:14:31 AM3/17/14
to r-packa...@googlegroups.com
Hello list,

Thank you Adrian for making it possible to read Excel data tables into R.

I have noticed that read.xlsx2 ignores a headless column while read.xlsx doesn't. The column is included if column indices are specified.

I find it unexpected that columns are ignored. Is this because the very first row is used to define columns

Attached is a test xlsx file, my comment made clear by
read.xlsx("test.xlsx", sheetIndex=1, colClasses=NA)
read.xlsx2("test.xlsx", sheetIndex=1, colClasses=NA)
read.xlsx2("test.xlsx", sheetIndex=1, colClasses=NA, colIndex=c(1,2,3))

Cheers,
Ulrik
test.xlsx
Reply all
Reply to author
Forward
0 new messages