Márcio, Think matrix!
Do you really want b to be 100 copies of the same numbers? You are asking for a strange crossproduct with the main diagonal zeroed out. a2 <- crossprod(a) a2[cbind(1:1000, 1:1000)] <- 0 all.equal(a, a2) Rich [[alternative HTML version deleted]]
______________________________________________ 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.