3

I'm currently studying R. In particular I need to remember the functions in the apply-function family (e.g. lapply, sapply, mapply, etc.). I know what each function in the apply-function family does (especially this answer helps a lot), but mixes the names up from time to time.

Is there a natural meaning for the prefix of each apply function (like lapply = 'list'-apply)?

mischva11
  • 2,811
  • 3
  • 18
  • 34
Herickson
  • 133
  • 4

1 Answers1

4

Yes, you got following apply r-basic functions:

I think you can interprete some prefix differently, like m was mentioned in the commentary as multivariate (commentary got removed). I tried to use the wording of the documentation, so it's more likely to be understood.

Also lapply, sapply and vapply are in the same documentation site, since the sapply and vapply are wrapper for lapply

mischva11
  • 2,811
  • 3
  • 18
  • 34
  • i hope i did not forget any apply function. Tell me if i missed something. – mischva11 Feb 28 '20 at 13:36
  • 1
    Thank you! This makes so much sense and will definitely help me memorising. If I encounter even more apply variants, I'll get back to this answer! – Herickson Feb 28 '20 at 14:01