Learn R Programming

sampSurf (version 0.7-6)

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

Description

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

Usage

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.

Value

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

Details

The details are all presented above.

See Also

bbox, bboxToPoly, bboxCheck

Examples

Run this code
# NOT RUN {
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)
# }

Run the code above in your browser using DataLab