SpatialPolygons              package:sp              R Documentation

_c_r_e_a_t_e _o_b_j_e_c_t_s _o_f _c_l_a_s_s _S_p_a_t_i_a_l_P_o_l_y_g_o_n_s _o_r _S_p_a_t_i_a_l_P_o_l_y_g_o_n_s_D_a_t_a_F_r_a_m_e

_D_e_s_c_r_i_p_t_i_o_n:

     create objects of class 'SpatialPolygons' or
     'SpatialPolygonsDataFrame' from lists of 'Polygons' objects and
     'data.frame's

_U_s_a_g_e:

      
     Polygon(coords, hole=as.logical(NA))
     Polygons(srl, ID)
     SpatialPolygons(Srl, pO = 1:length(Srl), proj4string=CRS(as.character(NA)))
     SpatialPolygonsDataFrame(Sr, data, match.ID = TRUE)

_A_r_g_u_m_e_n_t_s:

  coords: 2-column numeric matrix with coordinates; first point (row)
          should equal last coordinates (row) 

proj4string: projection string of class CRS-class

    hole: logical value for setting ring as hole or not

     srl: list with Polygon-class objects

      ID: character vector of length one with identifier

     Srl: list with objects of class Polygons-class

      pO: integer vector; plotting order 

      Sr: object of class SpatialPolygons-class

    data: object of class 'data.frame'; the number of rows in 'data'
          should equal the number of Polygons-class objects in 'Sr'

match.ID: logical: (default TRUE): match SpatialPolygons member
          Polygons ID slot values with data frame row names, and
          re-order the data frame rows if necessary

_V_a_l_u_e:

     'Polygon' returns an object of class 'Polygon'; 'Polygons' returns
     an object of class 'Polygons'; 'SpatialPolygons' returns object of
     class 'SpatialPolygons'; 'SpatialPolygonsDataFrame' returns object
     of class 'SpatialPolygonsDataFrame'

_S_e_e _A_l_s_o:

     SpatialPolygons-class, SpatialPolygonsDataFrame-class

