rgl.bbox                 package:rgl                 R Documentation

_S_e_t _u_p _B_o_u_n_d_i_n_g _B_o_x _d_e_c_o_r_a_t_i_o_n

_D_e_s_c_r_i_p_t_i_o_n:

     Set up the bounding box decoration.

_U_s_a_g_e:

     rgl.bbox( 
       xat=NULL, xlab=NULL, xunit=0, xlen=5, 
       yat=NULL, ylab=NULL, yunit=0, ylen=5,
       zat=NULL, zlab=NULL, zunit=0, zlen=5,
       marklen=15.0, marklen.rel=TRUE, expand=1, ...)
     bbox3d(xat, yat, zat, expand=1.03, nticks=5, ...)  

_A_r_g_u_m_e_n_t_s:

xat,yat,zat: vector specifying the tickmark positions

xlab,ylab,zlab: character vector specifying the tickmark labeling

xunit,yunit,zunit: value specifying the tick mark base for uniform tick
          mark layout

xlen,ylen,zlen: value specifying the number of tickmarks

 marklen: value specifying the length of the tickmarks

marklen.rel: logical, if TRUE tick mark length is calculated using
          1/'marklen' * axis length, otherwise tick mark length is
          'marklen' in coordinate space

  expand: value specifying how much to expand the bounding box around
          the data

  nticks: suggested number of ticks to use on axes

    ... : Material properties (or other 'rgl.bbox' parameters in the
          case of 'bbox3d'). See 'rgl.material' for details.

_D_e_t_a_i_l_s:

     Three different types of tick mark layouts are possible. If 'at'
     is not 'NULL', the ticks are set up at custom positions. If 'unit'
     is not zero, it defines the tick mark base. If 'length' is not
     zero, it specifies the number of ticks that are automatically
     specified. The first colour specifies the bounding box, while the
     second one specifies the tick mark and font colour.

     'bbox3d' defaults to 'pretty' locations for the axis labels and a
     slightly larger box, whereas 'rgl.bbox' covers the exact range.

     'axes3d' offers more flexibility in the specification of the axes,
     but  they are static, unlike those drawn by 'rgl.bbox' and
     'bbox3d'.

_V_a_l_u_e:

     This function is called for the side effect of setting the
     bounding box decoration. A shape ID is returned to allow 'rgl.pop'
     to delete it.

_S_e_e _A_l_s_o:

     'rgl.material', 'axes3d'

_E_x_a_m_p_l_e_s:

       rgl.open()
       rgl.points(rnorm(100), rnorm(100), rnorm(100))
       rgl.bbox(color=c("#333377","white"), emission="#333377", 
                specular="#3333FF", shininess=5, alpha=0.8 )
       
       open3d()
       points3d(rnorm(100), rnorm(100), rnorm(100))
       bbox3d(color=c("#333377","white"), emission="#333377", 
              specular="#3333FF", shininess=5, alpha=0.8)

