Applies the Math2 group functions to spam objects

# max(x,..., na.rm = FALSE)

Arguments

x

spam object.

na.rm

a logical indicating whether missing values should be removed.

Value

If structurebased=TRUE, all functions operate on the vector x@entries and return the result thereof.

Conversely, if structurebased=FALSE, the result is identical to one with as.matrix(x) input.

Details

The na.rm argument is only meaninful if NAOK=TRUE.

See also

Author

Reinhard Furrer

Examples

getGroupMembers("Summary")
#> [1] "max"   "min"   "range" "prod"  "sum"   "any"   "all"  

smat <- diag.spam( runif(15))
range(smat)
#> [1] 0.0000000 0.9947343
options(spam.structurebased=FALSE)
range(smat)
#> [1] 0.0000000 0.9947343

if (FALSE) {
max( log(spam(c(1,-1))), na.rm=TRUE)
}
# allow 'NA's first:
# TODO
# options(spam.NAOK=TRUE)
# max( log(spam(c(1,-1))), na.rm=TRUE)