[R-gregmisc-users] SF.net SVN: r-gregmisc: [1269] trunk/gdata/R/read.xls.R
Brought to you by:
warnes
|
From: <wa...@us...> - 2008-05-13 03:09:35
|
Revision: 1269
http://r-gregmisc.svn.sourceforge.net/r-gregmisc/?rev=1269&view=rev
Author: warnes
Date: 2008-05-12 20:09:32 -0700 (Mon, 12 May 2008)
Log Message:
-----------
Use path.expand() to give proper full path to xls file to be translated by read.xls()
Modified Paths:
--------------
trunk/gdata/R/read.xls.R
Modified: trunk/gdata/R/read.xls.R
===================================================================
--- trunk/gdata/R/read.xls.R 2008-05-13 02:55:45 UTC (rev 1268)
+++ trunk/gdata/R/read.xls.R 2008-05-13 03:09:32 UTC (rev 1269)
@@ -1,4 +1,4 @@
-## $Id$
+## s$Id$
## Creating a temporary function to quote the string
dQuote.ascii <- function(x) paste('"',x,'"',sep='')
@@ -86,7 +86,15 @@
if (inherits(con, "connection") && isOpen(con)) close(con)
if (file.exists(tfn)) file.remove(tfn)
})
+
+ ## expand file path, translating ~ to user's home directory, etc.
+ xls <- path.expand(xls)
+
+
+ ## translate from xls to csv format (returns csv file name)
con <- xls2csv(xls, sheet, verbose=verbose, ..., perl = perl)
+
+ ## load the csv file
open(con)
tfn <- summary(con)$description
if (missing(pattern))
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|