Skip to content

Commit

Permalink
Stability improvements; ready for CRAN
Browse files Browse the repository at this point in the history
  • Loading branch information
baddstats committed Mar 24, 2024
1 parent d30c7c8 commit 02783c0
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 9 deletions.
8 changes: 4 additions & 4 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: spatstat.linnet
Version: 3.1-4.001
Date: 2024-02-05
Version: 3.1-5
Date: 2024-03-24
Title: Linear Networks Functionality of the 'spatstat' Family
Authors@R: c(person("Adrian", "Baddeley",
role = c("aut", "cre", "cph"),
Expand All @@ -25,8 +25,8 @@ Authors@R: c(person("Adrian", "Baddeley",
person("Ottmar", "Cronie",
role = "ctb"))
Maintainer: Adrian Baddeley <[email protected]>
Depends: R (>= 3.5.0), spatstat.data (>= 3.0), spatstat.geom (>= 3.2-7), spatstat.random (>= 3.2-1), spatstat.explore (>= 3.2-5), spatstat.model (>= 3.2-9), stats, graphics, grDevices, methods, utils
Imports: spatstat.utils (>= 3.0-3), Matrix, spatstat.sparse (>= 3.0)
Depends: R (>= 3.5.0), spatstat.data (>= 3.0-4), spatstat.geom (>= 3.2-9), spatstat.random (>= 3.2-3), spatstat.explore (>= 3.2-7), spatstat.model (>= 3.2-11), stats, graphics, grDevices, methods, utils
Imports: spatstat.utils (>= 3.0-4), Matrix, spatstat.sparse (>= 3.0-3)
Suggests: goftest, locfit, spatstat (>= 3.0)
Description: Defines types of spatial data on a linear network
and provides functionality for geometrical operations,
Expand Down
6 changes: 4 additions & 2 deletions NEWS
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@

CHANGES IN spatstat.linnet VERSION 3.1-4.001
CHANGES IN spatstat.linnet VERSION 3.1-5

OVERVIEW

o Slightly accelerated
o Slightly accelerated.

o Internal stability improvements.

SIGNIFICANT USER-VISIBLE CHANGES

Expand Down
7 changes: 5 additions & 2 deletions R/lpp.R
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#
# lpp.R
#
# $Revision: 1.82 $ $Date: 2022/10/09 11:00:03 $
# $Revision: 1.83 $ $Date: 2024/03/24 00:53:42 $
#
# Class "lpp" of point patterns on linear networks

Expand All @@ -21,6 +21,8 @@ lpp <- function(X, L, ...) {
X <- as.data.frame(X)
#' validate local coordinates
if(nrow(X) > 0) {
X$seg <- as.integer(X$seg)
X$tp <- as.double(X$tp)
nedge <- nsegments(L)
if(with(X, any(seg < 1 | seg > nedge)))
stop("Segment index coordinate 'seg' exceeds bounds")
Expand All @@ -47,7 +49,8 @@ lpp <- function(X, L, ...) {
#' projected points (spatial coordinates and marks)
df <- as.data.frame(pro$Xproj)
#' local coordinates
lo <- data.frame(seg=pro$mapXY, tp=pro$tp)
lo <- data.frame(seg = as.integer(pro$mapXY),
tp = as.double(pro$tp))
}
}
# combine spatial, local, marks
Expand Down
3 changes: 2 additions & 1 deletion inst/doc/packagesizes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,5 @@ date version nhelpfiles nobjects ndatasets Rlines srclines
"2023-10-22" "3.1-2" 148 307 0 12268 3270
"2023-10-28" "3.1-3" 148 307 0 12268 3270
"2024-02-04" "3.1-4" 148 312 0 12340 3270
"2024-02-05" "3.1-4.001" 148 312 0 12340 3270
"2024-03-24" "3.1-5" 148 312 0 12343 3270
"2024-03-24" "3.1-5" 148 312 0 12343 3270

0 comments on commit 02783c0

Please sign in to comment.