[Rspatial-devel] SpatialPointsNULL??

Edzer Pebesma edzer.pebesma at uni-muenster.de
Sat Dec 17 21:57:56 CET 2011


On 12/17/2011 08:31 PM, Roger Bivand wrote:
> Hi:
> 
> getClass("SpatialPoints")
> getClass("SpatialPixels")
> getClass("SpatialGrid")
> 
> extend "SpatialPointsNULL", and
> 
> getClass("SpatialPolygons")
> getClass("SpatialLines")
> 
> extend "SpatialPolygonsNULL" and "SpatialLinesNULL" respectively. Any
> ideas where the "*NULL" come from? None of them are declared by us, so
> are they coming from methods?
> 
> Roger
> 
I guess so; can't reproduce it on 2.14 release:

> getClass("SpatialPoints")
Class "SpatialPoints" [package "sp"]

Slots:

Name:       coords        bbox proj4string
Class:      matrix      matrix         CRS

Extends: "Spatial"

Known Subclasses:
Class "SpatialPointsDataFrame", directly
Class "SpatialPixels", directly
Class "SpatialGrid", directly, with explicit coerce
Class "SpatialPixelsDataFrame", by class "SpatialPixels", distance 2
Class "SpatialGridDataFrame", by class "SpatialGrid", distance 2, with
explicit coerce
> getClass("SpatialPixels")
Class "SpatialPixels" [package "sp"]

Slots:

Name:          grid   grid.index       coords         bbox  proj4string
Class: GridTopology      integer       matrix       matrix          CRS

Extends:
Class "SpatialPoints", directly
Class "Spatial", by class "SpatialPoints", distance 2

Known Subclasses:
Class "SpatialGrid", directly, with explicit coerce
Class "SpatialPixelsDataFrame", directly
Class "SpatialGridDataFrame", by class "SpatialGrid", distance 2, with
explicit coerce
> getClass("SpatialGrid")
Class "SpatialGrid" [package "sp"]

Slots:

Name:        coords         grid   grid.index         bbox  proj4string
Class:       matrix GridTopology      integer       matrix          CRS

Extends:
Class "SpatialPixels", directly, with explicit coerce
Class "SpatialPoints", directly, with explicit coerce
Class "Spatial", directly

Known Subclasses: "SpatialGridDataFrame"
>
> getClass("SpatialPolygons")
Class "SpatialPolygons" [package "sp"]

Slots:

getClass("SpatialPolygons")
getClass("SpatialLines")

Name:     polygons   plotOrder        bbox proj4string
Class:        list     integer      matrix         CRS

Extends: "Spatial"

Known Subclasses: "SpatialPolygonsDataFrame"
> getClass("SpatialLines")
Class "SpatialLines" [package "sp"]

Slots:

Name:        lines        bbox proj4string
Class:        list      matrix         CRS

Extends: "Spatial"

Known Subclasses: "SpatialLinesDataFrame"
>
> getClass("SpatialPolygons")
Class "SpatialPolygons" [package "sp"]

Slots:

Name:     polygons   plotOrder        bbox proj4string
Class:        list     integer      matrix         CRS

Extends: "Spatial"

Known Subclasses: "SpatialPolygonsDataFrame"
> getClass("SpatialLines")
Class "SpatialLines" [package "sp"]

Slots:

Name:        lines        bbox proj4string
Class:        list      matrix         CRS

Extends: "Spatial"

Known Subclasses: "SpatialLinesDataFrame"
>
> getClass("SpatialPolygons")
Class "SpatialPolygons" [package "sp"]

Slots:

Name:     polygons   plotOrder        bbox proj4string
Class:        list     integer      matrix         CRS

Extends: "Spatial"

Known Subclasses: "SpatialPolygonsDataFrame"
> getClass("SpatialLines")
Class "SpatialLines" [package "sp"]

Slots:

Name:        lines        bbox proj4string
Class:        list      matrix         CRS

Extends: "Spatial"

Known Subclasses: "SpatialLinesDataFrame"
> sessionInfo()
R version 2.14.0 (2011-10-31)
Platform: x86_64-pc-linux-gnu (64-bit)

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
 [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8
 [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8
 [7] LC_PAPER=C                 LC_NAME=C
 [9] LC_ADDRESS=C               LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

other attached packages:
[1] sp_0.9-92

loaded via a namespace (and not attached):
[1] grid_2.14.0    lattice_0.20-0


-- 
Edzer Pebesma
Institute for Geoinformatics (ifgi), University of Münster
Weseler Straße 253, 48151 Münster, Germany. Phone: +49 251
8333081, Fax: +49 251 8339763  http://ifgi.uni-muenster.de
http://www.52north.org/geostatistics      e.pebesma at wwu.de


More information about the Rspatial-devel mailing list