diff --git a/articles/sftime.html b/articles/sftime.html index dfbc940..a92e64b 100644 --- a/articles/sftime.html +++ b/articles/sftime.html @@ -144,12 +144,12 @@
sftime
class#> Bounding box: xmin: 1 ymin: 1 xmax: 2 ymax: 3
#> CRS: NA
#> Time column with classes: 'POSIXct', 'POSIXt'.
-#> Ranging from 2024-09-08 07:24:22.832028 to 2024-09-11 07:24:22.832028.
+#> Ranging from 2024-09-08 07:57:43.147894 to 2024-09-11 07:57:43.147894.
#> a x_sfc time
-#> 1 1 POINT (1 2) 2024-09-11 07:24:22
-#> 2 2 POINT (1 3) 2024-09-10 07:24:22
-#> 3 3 POINT (2 3) 2024-09-09 07:24:22
-#> 4 4 POINT (2 1) 2024-09-08 07:24:22
+#> 1 1 POINT (1 2) 2024-09-11 07:57:43
+#> 2 2 POINT (1 3) 2024-09-10 07:57:43
+#> 3 3 POINT (2 3) 2024-09-09 07:57:43
+#> 4 4 POINT (2 1) 2024-09-08 07:57:43
Methods for sftime
objects are:
methods(class = "sftime")
@@ -175,17 +175,17 @@ Functions t
# get the values from the time column
st_time(x_sftime1)
-#> [1] "2024-09-11 07:24:22 UTC" "2024-09-10 07:24:22 UTC"
-#> [3] "2024-09-09 07:24:22 UTC" "2024-09-08 07:24:22 UTC"
+#> [1] "2024-09-11 07:57:43 UTC" "2024-09-10 07:57:43 UTC"
+#> [3] "2024-09-09 07:57:43 UTC" "2024-09-08 07:57:43 UTC"
x_sftime1$time # alternative way
-#> [1] "2024-09-11 07:24:22 UTC" "2024-09-10 07:24:22 UTC"
-#> [3] "2024-09-09 07:24:22 UTC" "2024-09-08 07:24:22 UTC"
+#> [1] "2024-09-11 07:57:43 UTC" "2024-09-10 07:57:43 UTC"
+#> [3] "2024-09-09 07:57:43 UTC" "2024-09-08 07:57:43 UTC"
# set the values in the time column
st_time(x_sftime1) <- Sys.time()
st_time(x_sftime1)
-#> [1] "2024-09-11 07:24:23 UTC" "2024-09-11 07:24:23 UTC"
-#> [3] "2024-09-11 07:24:23 UTC" "2024-09-11 07:24:23 UTC"
+#> [1] "2024-09-11 07:57:43 UTC" "2024-09-11 07:57:43 UTC"
+#> [3] "2024-09-11 07:57:43 UTC" "2024-09-11 07:57:43 UTC"
# drop the time column to convert an sftime object to an sf object
st_drop_time(x_sftime1)
@@ -206,12 +206,12 @@ Functions t
#> Bounding box: xmin: 1 ymin: 1 xmax: 2 ymax: 3
#> CRS: NA
#> Time column with classes: 'POSIXct', 'POSIXt'.
-#> Ranging from 2024-09-11 07:24:23.017823 to 2024-09-11 07:24:23.017823.
+#> Ranging from 2024-09-11 07:57:43.334141 to 2024-09-11 07:57:43.334141.
#> a x_sfc time
-#> 1 1 POINT (1 2) 2024-09-11 07:24:23
-#> 2 2 POINT (1 3) 2024-09-11 07:24:23
-#> 3 3 POINT (2 3) 2024-09-11 07:24:23
-#> 4 4 POINT (2 1) 2024-09-11 07:24:23
+#> 1 1 POINT (1 2) 2024-09-11 07:57:43
+#> 2 2 POINT (1 3) 2024-09-11 07:57:43
+#> 3 3 POINT (2 3) 2024-09-11 07:57:43
+#> 4 4 POINT (2 1) 2024-09-11 07:57:43
# add a time column to an sf object converts it to an sftime object
st_time(x_sftime1, time_column_name = "time") <- Sys.time()
@@ -389,8 +389,8 @@ Subsetting
st_time(x_sftime1)
-#> [1] "2024-09-11 07:24:23 UTC" "2024-09-11 07:24:23 UTC"
-#> [3] "2024-09-11 07:24:23 UTC" "2024-09-11 07:24:23 UTC"
+#> [1] "2024-09-11 07:57:43 UTC" "2024-09-11 07:57:43 UTC"
+#> [3] "2024-09-11 07:57:43 UTC" "2024-09-11 07:57:43 UTC"
Other subsetting functions work as for sf
objects,
e.g. selecting rows by row indices returns the specified rows. A key
difference is that the active time column of an sftime
@@ -409,9 +409,9 @@
x <- Sys.time() + 5:1 * 3600 * 24
sort(x)
-#> [1] "2024-09-12 07:24:10 UTC" "2024-09-13 07:24:10 UTC"
-#> [3] "2024-09-14 07:24:10 UTC" "2024-09-15 07:24:10 UTC"
-#> [5] "2024-09-16 07:24:10 UTC"
+#> [1] "2024-09-12 07:57:30 UTC" "2024-09-13 07:57:30 UTC"
+#> [3] "2024-09-14 07:57:30 UTC" "2024-09-15 07:57:30 UTC"
+#> [5] "2024-09-16 07:57:30 UTC"
is_sortable(x)
#> [1] TRUE
diff --git a/reference/print.sftime.html b/reference/print.sftime.html
index 54ecfd8..2fef3ef 100644
--- a/reference/print.sftime.html
+++ b/reference/print.sftime.html
@@ -81,13 +81,13 @@ Examples#> Bounding box: xmin: 1 ymin: 1 xmax: 3 ymax: 3
#> CRS: NA
#> Time column with classes: 'POSIXct', 'POSIXt'.
-#> Ranging from 2024-09-11 07:24:11.697086 to 2024-09-11 07:24:15.697086.
+#> Ranging from 2024-09-11 07:57:32.225044 to 2024-09-11 07:57:36.225044.
#> a g time
-#> 1 1 POINT (1 2) 2024-09-11 07:24:11
-#> 2 2 POINT (1 3) 2024-09-11 07:24:12
-#> 3 3 POINT (2 3) 2024-09-11 07:24:13
-#> 4 4 POINT (2 1) 2024-09-11 07:24:14
-#> 5 5 POINT (3 1) 2024-09-11 07:24:15
+#> 1 1 POINT (1 2) 2024-09-11 07:57:32
+#> 2 2 POINT (1 3) 2024-09-11 07:57:33
+#> 3 3 POINT (2 3) 2024-09-11 07:57:34
+#> 4 4 POINT (2 1) 2024-09-11 07:57:35
+#> 5 5 POINT (3 1) 2024-09-11 07:57:36
print(x[0, ])
#> Spatiotemporal feature collection with 0 features and 1 field
#> Bounding box: xmin: NA ymin: NA xmax: NA ymax: NA
diff --git a/reference/st_as_sftime.html b/reference/st_as_sftime.html
index a2b94b9..f81c1a1 100644
--- a/reference/st_as_sftime.html
+++ b/reference/st_as_sftime.html
@@ -126,7 +126,7 @@ Argumentsagr
-A character vector; see the details section of st_sf
.
+A character vector; see the details section of st_sf
.
coords
@@ -140,7 +140,7 @@ Argumentsdim
-Passed on to st_point
(only when argument
+
Passed on to st_point
(only when argument
coords
is given).
@@ -325,19 +325,19 @@ Examples#> Bounding box: xmin: 0 ymin: 0 xmax: 1 ymax: 1
#> CRS: NA
#> Time column with classes: 'POSIXct', 'POSIXt'.
-#> Ranging from 2024-09-11 07:24:13.537388 to 2024-09-11 07:24:22.537388.
+#> Ranging from 2024-09-11 07:57:34.089476 to 2024-09-11 07:57:43.089476.
#> First 10 features:
#> label geom time
#> NA window POLYGON ((0 0, 1 0, 1 1, 0 ... <NA>
-#> 1 segment LINESTRING (0.3203339 0.798... 2024-09-11 07:24:13
-#> 2 segment LINESTRING (0.4039816 0.366... 2024-09-11 07:24:14
-#> 3 segment LINESTRING (0.03262274 0.38... 2024-09-11 07:24:15
-#> 4 segment LINESTRING (0.4922266 0.673... 2024-09-11 07:24:16
-#> 5 segment LINESTRING (0.1416749 0.439... 2024-09-11 07:24:17
-#> 6 segment LINESTRING (0.7991584 0.712... 2024-09-11 07:24:18
-#> 7 segment LINESTRING (0.4091124 0.435... 2024-09-11 07:24:19
-#> 8 segment LINESTRING (0.9364347 0.665... 2024-09-11 07:24:20
-#> 9 segment LINESTRING (0.7329098 0.523... 2024-09-11 07:24:21
+#> 1 segment LINESTRING (0.3203339 0.798... 2024-09-11 07:57:34
+#> 2 segment LINESTRING (0.4039816 0.366... 2024-09-11 07:57:35
+#> 3 segment LINESTRING (0.03262274 0.38... 2024-09-11 07:57:36
+#> 4 segment LINESTRING (0.4922266 0.673... 2024-09-11 07:57:37
+#> 5 segment LINESTRING (0.1416749 0.439... 2024-09-11 07:57:38
+#> 6 segment LINESTRING (0.7991584 0.712... 2024-09-11 07:57:39
+#> 7 segment LINESTRING (0.4091124 0.435... 2024-09-11 07:57:40
+#> 8 segment LINESTRING (0.9364347 0.665... 2024-09-11 07:57:41
+#> 9 segment LINESTRING (0.7329098 0.523... 2024-09-11 07:57:42
# convert an lpp object to an sftime object (modified from the
# spatstat.linnet package)
@@ -385,7 +385,7 @@ Examples#> Bounding box: xmin: -3 ymin: -1 xmax: 3 ymax: 7
#> CRS: NA
#> Time column with classes: 'POSIXct', 'POSIXt'.
-#> Ranging from 2024-09-11 07:24:13.754417 to 2024-09-11 07:24:16.754417.
+#> Ranging from 2024-09-11 07:57:34.305421 to 2024-09-11 07:57:37.305421.
#> label seg tp a geom time
#> 1 window NA NA NA POLYGON ((-3 -1, 3 -1, 3 7,... <NA>
#> 2 segment NA NA NA LINESTRING (-2 0, -1 3) <NA>
@@ -393,10 +393,10 @@ Examples#> 4 segment NA NA NA LINESTRING (0 6, 1 3) <NA>
#> 5 segment NA NA NA LINESTRING (1 3, 2 0) <NA>
#> 6 segment NA NA NA LINESTRING (-1 3, 1 3) <NA>
-#> 7 point 1 0.5 1 POINT (-1.5 1.5) 2024-09-11 07:24:13
-#> 8 point 5 0.5 2 POINT (0 3) 2024-09-11 07:24:14
-#> 9 point 3 0.5 3 POINT (0.5 4.5) 2024-09-11 07:24:15
-#> 10 point 4 0.5 4 POINT (1.5 1.5) 2024-09-11 07:24:16
+#> 7 point 1 0.5 1 POINT (-1.5 1.5) 2024-09-11 07:57:34
+#> 8 point 5 0.5 2 POINT (0 3) 2024-09-11 07:57:35
+#> 9 point 3 0.5 3 POINT (0.5 4.5) 2024-09-11 07:57:36
+#> 10 point 4 0.5 4 POINT (1.5 1.5) 2024-09-11 07:57:37
# convert an sftrack object to an sftime object (modified from sftrack)
if (require(sftrack)) {
diff --git a/reference/st_crop.sftime-1.png b/reference/st_crop.sftime-1.png
index a856843..8a40371 100644
Binary files a/reference/st_crop.sftime-1.png and b/reference/st_crop.sftime-1.png differ
diff --git a/reference/st_geometry.html b/reference/st_geometry.html
index 0c035bc..d29dc26 100644
--- a/reference/st_geometry.html
+++ b/reference/st_geometry.html
@@ -76,7 +76,7 @@ Examplesx <- st_sftime(a = 3, g, time = time)
st_drop_geometry(x)
#> a time
-#> 1 3 2024-09-11 07:24:16
+#> 1 3 2024-09-11 07:57:37