On Tue, 16 Mar 2010, Matt Fitzpatrick wrote:
Hello - Can anyone refer me to the function that replaced map2poly?
(note - Map2poly(), please refer to functions by their correct names -
the function discarded attribute data from an imported shapefile (S3
class "Map") to make a list of polygons. The data representation is not
robust nor supported in further development).
That function was long deprecated (a warning was shown that the underlying
representation would be withdrawn from the user namespace). See otherwise
many replies to questions about this over the last three months, for
example:
https://stat.ethz.ch/pipermail/r-help/2010-March/231949.html
https://stat.ethz.ch/pipermail/r-sig-geo/2010-February/007610.html
https://stat.ethz.ch/pipermail/r-sig-geo/2010-February/007611.html
https://stat.ethz.ch/pipermail/r-sig-geo/2009-December/007253.html
etc. As you will see, many of the questioners also use HTML mail, not text
mail, so perhaps both reading the posting guide and searching the
archives, as well as reading warning messages, might be a good idea.
The sp package has been in place for five years now, so removing direct
access to its inadequate antecedents in maptools isn't unexpected. Legacy
scripts can be adapted as shown in the replies; replacing read.shape()
with readShapeSpatial() should be sufficient for most uses as the plot()
method for the deprecated S3 "polylist" class has similar arguments to the
plot() method in the sp package for objects inheriting from the S4
"SpatialPolygons" class. If need be, use the ::: operator to access
commands in maptools no longer in the user namespace.
Alternatively, stay with an antiquated version of maptools, your choice.
Roger
Thanks,
Matt
<http://www.al.umces.edu/people/faculty/mattfitzpatrick.htm>
[[alternative HTML version deleted]]
_______________________________________________
R-sig-Geo mailing list
[email protected]
https://stat.ethz.ch/mailman/listinfo/r-sig-geo
--
Roger Bivand
Economic Geography Section, Department of Economics, Norwegian School of
Economics and Business Administration, Helleveien 30, N-5045 Bergen,
Norway. voice: +47 55 95 93 55; fax +47 55 95 95 43
e-mail: [email protected]
_______________________________________________
R-sig-Geo mailing list
[email protected]
https://stat.ethz.ch/mailman/listinfo/r-sig-geo