This chapter describes several approaches to drawing 3D images in R. Drawing in 3D requires several new concepts compared to drawing in 2D, so there is a brief introduction to those concepts. The core R graphics system only provides a 2D graphics engine, but several functions are described that provide limited 3D support based on that. Graphics based on a genuine 3D graphics engine is provided by the rgl package.
The core R graphics system provides a 2D graphics engine. All drawing occurs on a two-dimensional plane, usually based on simple (x, y) cartesian coordinates. This chapter looks at packages and functions that allow drawing in three dimensions, where locations are in terms of (x, y, z) triplets, ...