Abstract
Expressions, the kind you create using the quote function, come in four flavors: a primitive value, a name, a function call or a control structure, and a pairlist. Function calls include operators such as the arithmetic or logical operators because these are function calls as well in R, and control structures can be considered just a special kind of function calls—they only really differ from function calls in the syntax you use to invoke them.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Notes
- 1.
In the package pryr, which you will return to at the end of this chapter, there are functions, written in C, that do provide access to the internals of promises. Using pryr, you can get hold of both the expression and the associated environment of a promise in case you need it.
Author information
Authors and Affiliations
Rights and permissions
Copyright information
© 2017 Thomas Mailund
About this chapter
Cite this chapter
Mailund, T. (2017). Working with Substitutions. In: Metaprogramming in R. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4842-2881-4_5
Download citation
DOI: https://doi.org/10.1007/978-1-4842-2881-4_5
Published:
Publisher Name: Apress, Berkeley, CA
Print ISBN: 978-1-4842-2880-7
Online ISBN: 978-1-4842-2881-4
eBook Packages: Professional and Applied ComputingApress Access BooksProfessional and Applied Computing (R0)