R/columnwiseExponentiation.R

Defines functions columnwiseExponentiation

#' @export
columnwiseExponentiation <- function(iBase, iExponent) {

    nBase <- length(iBase)
    ce <- iExponent

    for (column in 1:nBase) {

        base <- iBase[column]
        exponent <- iExponent[,column]

        ce[,column] <- base ^ exponent

    }

    return(ce)

}
jonathan-erdmann/optimizebets documentation built on Sept. 1, 2022, 10:35 p.m.