gouter: GPU generalized outer product.

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

View source: R/04operations.R

Description

This function calculates the outer product of two gvectors.

Usage

1
gouter(x, y, FUN = "*", normalOrder = TRUE)

Arguments

x

a 'vector' or gvector object

y

a 'vector' or gvector object

FUN

one of the following characters '*', '+', '-', '/' or '^'

normalOrder

logical input determining which order the operation should be performed in.

Details

This function is similar to the outer function in R base. It performs the specified operation on all posible combinations of elements from the first vector with the second. This function does not behave the same as R base when operating on matrices. Also, the operator %o% may be used as in the R base package.

Value

returns a gmatrix with the specified operation performed

Author(s)

Nathan Morris

See Also

outer, %o%

Examples

1
gouter(grnorm(10), grnorm(10), FUN="-")

njm18/gmatrix documentation built on May 23, 2019, 7:07 p.m.