edzer / sp

Classes and methods for spatial data
http://edzer.github.io/sp/
127 stars 27 forks source link

re-fix #125 #144

Closed bastistician closed 6 months ago

bastistician commented 6 months ago

This patch restores the fix for #125 that got lost in #138.

It avoids the unnecessary loading of sf for "default" Spatial objects with unset CRS, for example in:

SpatialPoints(cbind(1:5, 1:5)) |> summary()
## ...
## Is projected: NA 
## ...

is.projected() doesn't need a whole sf pipeline to get to that NA. ;)

edzer commented 6 months ago

Thanks @bastistician and sorry to cause you double work. I think this looks good; to be sure, @rsbivand could you pls also give this a look?

rsbivand commented 6 months ago

Yes, looks OK here.

edzer commented 6 months ago

Submitted to CRAN...

edzer commented 6 months ago

On CRAN now!