Re: [R] R: subset dataframe/list

2009-06-02 Thread David Winsemius
Also look at the documentation for read.csv2(). -- David. On Jun 2, 2009, at 5:43 AM, Cecilia Carmo wrote: Thank you all!!! The problem was the decimal symbol! My data was saved in a txt file, so I’ve introduced the dec="," in «read.table» and it worked. What I’ve done was coeficient

[R] R: subset dataframe/list

2009-06-02 Thread Cecilia Carmo
Thank you all!!! The problem was the decimal symbol! My data was saved in a txt file, so I’ve introduced the dec="," in «read.table» and it worked. What I’ve done was coeficientes<-read.table("coeficientes.txt",sep="\t",header=T,dec=",") Then, subset worked fine coeficientesWanted<-subset(coe

Re: [R] subset dataframe/list

2009-06-01 Thread Jorge Ivan Velez
Dear Cecilia, I have followed the replies you got and I found that, perhaps, what you are experiencing has something to do with the decimal symbol in your data. Consider the following: # Reading the data as you sent it to the list x <- read.table(textConnection("caedois b1 b2

Re: [R] subset dataframe/list

2009-06-01 Thread David Winsemius
So now is the time to back up to the beginning and demonstrate how you created the coeficientes object. Ideally you would also provide the results of: dput(coeficientes) or str(coeficientes) Subset will only work with dataframes, so if coeficientes is not a dataframe, then you will need

Re: [R] subset dataframe/list

2009-06-01 Thread Cecilia Carmo
It doesn't work. b1 was substituted by NA's with this message: Warning message: NAs introduced by coercion I will see in the webpage that you mentioned. Thanks, Cecília Em Mon, 1 Jun 2009 13:23:12 -0400 David Winsemius escreveu: On Jun 1, 2009, at 1:01 PM, Cecilia Carmo wrote: Hi R-help

Re: [R] subset dataframe/list

2009-06-01 Thread David Winsemius
On Jun 1, 2009, at 1:01 PM, Cecilia Carmo wrote: Hi R-helpers! I have the following object: head(coeficientes) caedois b1 b2 b3 1 10,033120395 -20,29478338 -0,274638864 2 2 -0,040629634 74,54239889 -0,069958424 3 5 -0,001116816 35

[R] subset dataframe/list

2009-06-01 Thread Cecilia Carmo
Hi R-helpers! I have the following object: head(coeficientes) caedois b1 b2 b3 1 10,033120395 -20,29478338 -0,274638864 2 2 -0,040629634 74,54239889 -0,069958424 3 5 -0,001116816 35,2398622 0,214327185 4 10 0,171875 5