4 ms·
Thanks for clearing that up, now it does make sense. In R most functions handle vectors as well as scalars without distinction, so normally one would use the f
by lottin 10y ago
Thanks for clearing that up, now it does make sense. In R most functions handle vectors as well as scalars without distinction, so normally one would use the function directly. Whereas if you wanted to process each element of a vector individually then you'd use apply(). It works the other way around.
- _Wintermute 10y agoWell that's because R doesn't have scalars, just vectors containing a single value.