[R] a dot "." can be assigned as object's name

September 8, 2023 by Kinh Nguyen

Finding something to name a short object in #R, you can use . to do things like:

  • Defining a square function
    . = \(.) .^2

    and evaluate it like normal

    . = .(.5)

    Note that the above function is R 4’s syntax.


comments powered by Disqus