Given a list:
alist = list( list(name=\"Foo\",age=22), list(name=\"Bar\"), list(name=\"Baz\",age=NULL) )
what\'s the best way to con
A comment mentioned wanting only a single loop, which can be achieved with @flodel's answer just by putting the body of the two loops together:
rbind.fill(lapply(alist, function(f) { as.data.frame(Filter(Negate(is.null), f)) }))
giving
name age 1 Foo 22 2 Bar NA 3 Baz NA