Hi all
I want to conditionally operate on certain elements of a matrix, let me
explain it with a simple vector example
> z<- c(1, 2, 3)
> zz <- c(0,0,0)
> null <- (z > 2) & ( zz <- z)
> zz
[1] 1 2 3
why zz is not (0, 0, 3) ?????
the null <- assignment is to keep the console silent
in the other hand, it curious that null has reasonable values
> null
[1] FALSE FALSE TRUE
Thanks in advance
Ulisses
Debian GNU/Linux: a dream come true
-----------------------------------------------------------------------------
"Computers are useless. They can only give answers." Pablo Picasso
Humans are slow, innaccurate, and brilliant.
Computers are fast, acurrate, and dumb.
Together they are unbeatable
---> Visita http://www.valux.org/ para saber acerca de la <---
---> Asociaci�n Valenciana de Usuarios de Linux <---
______________________________________________
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html