billycorg napsal(a): > thanks for the answer..but i don't find what i'm looking for! > > now i'm trying to expose better my problem: > i have: > > ht= a 1096rows x 3 columns matrix > > i'd like a function like this: > > d[i]=rbind(ht[i,]) for (i in 1:length(ht)) > > but this don't work :( > can anyone seriously help me?
The problem is that people actually are trying to seriously help you, but it is really difficult from your queries... Please specify what you expect to be your output - a vector where you just paste the rows of of the original matrix one by one? If so, you can do d <- t(ht) dim(d) <- NULL or (a 'dirty' way) d <- c(t(ht)) It is not at all clear what your statement should do. For example, what is length(ht) with ht being a matrix? For R it is the total number of elements, but did you mean this or the number of rows/columns?? The suggestion to read R-Intro is the best advice you got here. Petr -- Petr Klasterecky Dept. of Probability and Statistics Charles University in Prague Czech Republic ______________________________________________ R-help@stat.math.ethz.ch 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.