search for: iftelse

Displaying 1 result from an estimated 1 matches for "iftelse".

Did you mean: ifelse
2010 Mar 04
0
ifthen() question -- whoops--ifelse()
OK, I got it figured out. I was not keying into a length greater than 1, so: # I added this object and placed it into the iftelse statement: lid <- sum(match(id, st[i], nomatch = 0)) out$var.g[i]<-ifelse(lid ==1, meta$var.g[id==st[i]], aggs(g=g[id==st[i]], n.1= n.1[id==st[i]], n.2 = n.2[id==st[i]], cor)[2]) #full function: agg_g <- function...