[R] for loops

silvia-montagna at libero.it silvia-montagna at libero.it
Wed Apr 25 09:42:59 CEST 2007


Hello everybody
I'm very new at using R so probably this is a very stupid question.
I have a matrix of "p" columns and I have to calculate for each of them the "two sample t-statistic" and p-value and to save the results into two different vectors.
I have divided my matrix into two submatrices: submatrix A containing the first "n1" rows (p columns) and submatrix B containing the remaining "n2" (total rows=n1+n2).
How can I do this with for loop construction?
Friendly regards
Silvia


------------------------------------------------------
Passa a Infostrada. ADSL e Telefono senza limiti e senza canone Telecom
http://click.libero.it/infostrada



More information about the R-help mailing list