structure                package:base                R Documentation

_A_t_t_r_i_b_u_t_e _S_p_e_c_i_f_i_c_a_t_i_o_n

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

     'structure' returns the given object with further  attributes set.

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

     structure(.Data, ...)

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

   .Data: an object which will have various attributes attached to it.

     ...: attributes, specified in 'tag=value' form, which will be
          attached to data.

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

     Adding a  class '"factor"' will ensure that numeric codes are
     given integer storage mode.

     For historical reasons (these names are used when deparsing),
     attributes '".Dim"', '".Dimnames"', '".Names"', '".Tsp"' and
     '".Label"' are renamed to '"dim"', '"dimnames"', '"names"',
     '"tsp"' and '"levels"'.

     It is possible to give the same tag more than once, in which case
     the last value assigned wins.  As with other ways of assigning
     attributes, using 'tag=NULL' removes attribute 'tag' from '.Data'
     if it is present.

_R_e_f_e_r_e_n_c_e_s:

     Becker, R. A., Chambers, J. M. and Wilks, A. R. (1988) _The New S
     Language_. Wadsworth & Brooks/Cole.

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

     'attributes', 'attr'.

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

     structure(1:6, dim = 2:3)

