[R] textConnection on List

Santosh Srinivas santosh.srinivas at gmail.com
Mon Oct 11 07:34:55 CEST 2010


I'm trying to optimize some code that I have 

I have a list of delimited text in a list (see below). I want to do a
read.table via a text connection so that I can get the delimited values into
a table ... 
Something like ... tmp_MF_Data_F <- read.table(textConnection(tmpTxtList),
sep=';', quote = '') ... but this fails ...

Any idea how to go about it?

Thanks for the help.


head(tmpTxtList)
[[1]]
[1] "\"106270;BIRLA SUN LIFE CAPITAL PROTECTION ORIENTED FUND-3 YRS-
DIVIDEND;10.3287;10.3287;0.0000;01-Apr-2008\""

[[2]]
[1] "\"106269;BIRLA SUN LIFE CAPITAL PROTECTION ORIENTED FUND-3 YRS-
GROWTH;10.3287;10.3287;0.0000;01-Apr-2008\""

[[3]]
[1] "\"102767;Birla Sun Life Dynamic Bond Fund-Retail
Plan-Growth;12.6832;12.6832;12.6832;01-Apr-2008\""

[[4]]
[1] "\"102766;Birla Sun Life Dynamic Bond Fund-Retail Plan-Quarterly
Dividend;10.5396;10.5396;10.5396;01-Apr-2008\""

[[5]]
[1] "\"102855;Birla Sun Life Fixed Maturity Plan - Annual  Series
3-Dividend;9.9830;9.7833;9.9830;01-Apr-2008\""

[[6]]
[1] "\"102856;Birla Sun Life Fixed Maturity Plan - Annual  Series
3-Growth;12.3964;12.1485;12.3964;01-Apr-2008\""



More information about the R-help mailing list