This function creates an ESRI shapefile from an sp package object. The
function can also accommodate an object created by the grts or irs functions
in spsurvey. The type of shapefile, i.e., point, polyline, or polygon, is
determined by the class of the input object, which must be either
"SpatialDesign", "SpatialPointsDataFrame", "SpatialLinesDataFrame", or
"SpatialPolygonsDataFrame".