bboxSum: Function to Compute an Overall Bounding Box (bbox)

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/bboxSum.R

Description

Takes an array of bbox matrices and forms the overall encapsulating bounding box from these.

Usage

1
bboxSum(arr.bbox, ...)

Arguments

arr.bbox

This is a 3 dimensional array of bbox matrices with the rows and columns of each matrix as the first two dimensions, and each matrix indexed by the 3rd dimension of the array. Note that each bbox will be checked for validity such that row names must be c("x", "y") and column names must be c("min", "max"). Usually it is most convenient to use the bbox method for retrieving valid individual bbox matrices to put into the array.

...

Not presently used.

Details

The details are all presented above.

Value

A valid bbox matrix for the minimal bounding box of the set.

Author(s)

Jeffrey H. Gove

See Also

bbox, bboxToPoly, bboxCheck

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
dlogs = downLogs(3)
bboxArray = array(dim=c(2,2,3))
bboxArray[,,1] = bbox(perimeter(dlogs@logs$log.1))
bboxArray[,,2] = bbox(perimeter(dlogs@logs$log.2))
bboxArray[,,3] = bbox(perimeter(dlogs@logs$log.3))
dimnames(bboxArray) = dimnames(bbox(dlogs@logs$log.1)) #page dim doesn't matter
bbox = bboxSum(bboxArray)    
## Not run: 
plot(dlogs, axes=TRUE)
plot(bboxToPoly(bbox), add=TRUE)

## End(Not run)

sampSurf documentation built on March 5, 2021, 5:06 p.m.