Can anyone help me how to read xls file into R. I have tried following

library(gdata)
xlsfile <- file.path(.path.package('gdata'),'xls','iris.xls')
read.xls(xlsfile)

I got following error:
Converting xls file to csv file... Error in system(cmd, intern = !verbose) :
perl not found
Error in file.exists(tfn) : invalid 'file' argument

Question *1) What is the way to get it working?*


2nd approach I done was with RODBC package:

library(RODBC)
odbcConnectExcel(xlsfile)

Here I got following report:

RODBC Connection 4
Details:
  case=nochange
  DBQ=C:\PROGRA~1\R\R-211~1.1\library\gdata\xls\iris.xls
  DefaultDir=C:\PROGRA~1\R\R-211~1.1\library\gdata\xls
  Driver={Microsoft Excel Driver (*.xls)}
  DriverId=790
  MaxBufferSize=2048
  PageTimeout=5

My question is *2) How I retrieve data here?*
*
*
Thanks for your time.

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to