texts {rgl} | R Documentation |
Adds text to the scene. The text is positioned in 3D space. A bitmap font which is always oriented towards the camera is used.
rgl.texts(x, y, z, text, adj = 0.5, justify, ...) text3d(x, y, z, texts, adj = 0.5, justify, ...) texts3d(x, y, z, texts, adj = 0.5, justify, ...)
x, y, z |
point coordinates |
text |
text character vector to draw |
texts |
text character vector to draw |
adj |
one value specifying the horizontal adjustment |
justify |
(deprecated, please use adj instead) character string
specifying the horizontal adjustment; options are "left" , "right" ,
"center" .
|
... |
Material properties. See rgl.material for details. |
The adj
parameter determines the position of the text relative to the
specified coordinate. Use adj = 0
to place the left bottom corner at
(x,y,z)
, adj = 0.5
to center the text there, and adj = 1
to put the right bottom corner there.
text3d
and texts3d
draw text using the r3d
conventions. These are synonyms; the former is singular to be
consistent with the classic 2-D graphics functions, and the latter is
plural to be consistent with all the other graphics primitives. Take
your choice!
text3d(rnorm(10)*100,rnorm(10)*100,rnorm(10)*100,text=1:10,adj = 0.5, color=heat.colors(10))