Re: [R] RODBC: forcing a special column to be read in as character

2011-05-03 Thread Jack T.
I've had the same problem and ended up using the xlsReadWrite package. It takes more time to import a sheet but does have the colClasses command. Following your example: library(xlsReadWrite) read.xls("testtable", sheet = "sheet1", colClasses="character") should worked, it did for me -- View t

Re: [R] 64 bit use of odbcConnectExcel

2010-10-14 Thread Jack T.
Still doesn't work, any ideas? Error in sqlTables(channel1) : first argument is not an open RODBC channel In addition: Warning messages: 1: In odbcDriverConnect(con, tabQuote = c("[", "]"), ...) : [RODBC] ERROR: state IM002, code 0, message [Microsoft][ODBC Driver Manager] Data source name n

[R] densityplot on date objects

2010-07-23 Thread Jack T.
Hi, I'm looking for a way to use densityplot in the lattice package on Date data or manipulate the labels for tick marks. Here's an example: #generate psuedo dates dat.Date <- as.Date('2009-12-31')+as.integer(abs(rnorm(1))*100) #convert to a julian date for densityplot #because it doesn'

[R] 64 bit use of odbcConnectExcel

2010-07-22 Thread Jack T.
Hi All, I'm using R 2.11.1 on 64 bit windows XP. The little function I wrote below I use often to import the first 1001 lines in an excel sheet to R. This works fine on the 32 bit version of R but fails on the 64 bit [both on the same machine, using the same function, importing the same .xls f

Re: [R] read.table understands comment field and ignores text

2010-04-22 Thread Jack T.
Oh man, totally missed that one! Thanks so much for the reminder. -- View this message in context: http://r.789695.n4.nabble.com/read-table-understands-comment-field-and-ignores-text-tp2021036p2021055.html Sent from the R help mailing list archive at Nabble.com. ___

[R] read.table understands comment field and ignores text

2010-04-22 Thread Jack T.
Hi I'm trying to import a large csv file without quotes around each field. This creates some problems when there are "#" characters in certain strings as R understands its comment field and ignores the rest of the line. Here's an example: var1, var2, var3, var4 one, two, three, four Use this