--- Begin Message ---
Doesn´t work neither!
head(coeficientes)
caedois b1 b2 b3
1 1 0,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 14 0,007288399 40,06560548 -0,081828338
6 15 0,027530346 0,969969409 0,102775555
I’ve done
coeficientes$b1<-as.numeric(as.character(coeficientes$b1))
And b1 was substituted by NA’s
Then I’ve done
coeficientes$b1<-as.numeric(coeficientes$b1)
And b1 was transformed in other numbers
caedois b1 b2 b3
1 1 38 -20,29478338 -0,274638864
2 2 7 74,54239889 -0,069958424
3 5 2 35,2398622 0,214327185
4 10 48
5 14 15 40,06560548 -0,081828338
6 15 31 0,969969409 0,102775555
Thanks anyway,
Cecília
Em Mon, 01 Jun 2009 13:11:48 -0500 (CDT)
markle...@verizon.net escreveu:
hi: when I sent you my solution, I didn't realize that
you had factors. if you change the
factors to characters as described in that email, and
then use my approach , i think it should still work.
On Jun 1, 2009, markle...@verizon.net wrote: Hi:
coeficientes[,(coeficientes[,"b1"] > 0)]
will i think give you all the rows of the object where
b1 is greater than zero.
I can't tell if coeficients is a data frame or a matrix
but the above should work in either case.
On Jun 1, 2009, Cecilia Carmo <cecilia.ca...@ua.pt>
wrote: Hi R-helpers!
I have the following object:
head(coeficientes)
caedois b1 b2 b3
1 1 0,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 14 0,007288399 40,06560548 -0,081828338
6 15 0,027530346 0,969969409 0,102775555
I´ve tried to subset it like this:
coefSelected<-subset(coeficientes,"b1">0)
but it does nothing
Then Ive tried:
coefSelected<-subset(coeficientes,b1>0)
But I´ve got the following
Warning message:
In Ops.factor(b1, 0) : > not meaningful for factors
So Ive tried:
coefSelected<-subset(coeficientes,coeficientes$b1>0)
Warning message:
In Ops.factor(coeficientes$b1, 0) : > not meaningful for
factors
I´ve done
mode(coeficientes)
[1] "list"
But I don´t know how to handle it!
Coul anyone help me?
Thanks,
Cecília Carmo (Universidade de Aveiro Portugal
______________________________________________
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.
--- End Message ---