Skip to content
Prev 343425 / 398506 Next

How to do t.test to rows of a dataframe using apply family function?

Hi
That is because do.call is one function and rbind another. For both functions you can find its help page and read:
rbind
vectors or matrices. These can be given as named arguments. Other R objects will be coerced as appropriate: see sections ?Details? and ?Value?.

The type of a matrix result determined from the highest type of any of the inputs in the hierarchy raw < logical < integer < double < complex < character < list .
do.call
what

either a function or a non-empty character string naming the function to be called.

args

a list of arguments to the function call. The names attribute of args gives the argument names.

Actually inner lapply was not necessary and simple
do.call("rbind", lll)
gives the same result.