Hi there,
I'm writing a function which involves a loop. What to write in the ?
place would allow it skips the for loop and goes to a[i]-0.
a-b[s3,]
if (nrow(a)==0) ?
for (i in 1:nrow(a)){
a[i]-1
}
a[i]-0
Lisa Wang
Cancer
Lisa Wang lisawang at uhnres.utoronto.ca writes:
:
: Hi there,
:
: I'm writing a function which involves a loop. What to write in the ?
: place would allow it skips the for loop and goes to a[i]-0.
:
: a-b[s3,]
:
: if (nrow(a)==0) ?
:
: for (i in 1:nrow(a)){
:
Well, there ain't no such thing in R And your code doesn't
really make sense anyway. You talk about ``a[i]'' where a is
apparently a ***matrix*** (with the same number of columns as the
matrix b, but with fewer --- possibly 0 --- rows). And in such as
setting a[i] has a meaning, but