Description Usage Arguments Examples
Segments comparison of different homogeneous segmentations methods.
1 2 3 4 5 6 |
start |
A character of start location name of a spatial line. |
end |
A character of end location name of a spatial line. |
var |
A character or a character vector of variable names, such as a road pavement performance indicator. |
data |
A list of segmentation result. |
segid.matrix |
A matrix of segmentations. |
methods |
A vector of segmentation method names, default NULL. |
x |
A list of segments comparison result. |
... |
Ignore |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | testdata <- tsdwa[1:300, ]
testdata$length <- testdata$SLK.end - testdata$SLK.start
variable <- c("Curvature", "Deflection", "BLI")
seg1 <- hs(start = "SLK.start", end = "SLK.end", var = variable,
testdata, method = "shs", range = c(0.1, 0.5)) # 0.3 s
seg2 <- hs(start = "SLK.start", end = "SLK.end", var = variable,
testdata, method = "cda", range = c(0.1, 0.5)) # 0.7 s
seg3 <- hs(start = "SLK.start", end = "SLK.end", var = variable,
testdata, method = "mcv", range = c(0.1, 0.5)) # 0.6 s
segid.matrix <- cbind(seg1$seg.id, seg2$seg.id, seg3$seg.id)
data(segid.matrix)
cp <- segcompare(start = "SLK.start", end = "SLK.end", var = variable,
testdata, segid.matrix, methods = c("SHS", "CDA", "MCV")) # 4.8 s
cp
plot(cp)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.