fm.inner.prodR Documentation

Matrix inner product

Description

It takes two operators and performs inner product on a dense matrix

Usage

fm.inner.prod(fm, mat, Fun1, Fun2)

Arguments

fm

A FlashR matrix

mat

A FlashR dense matrix.

Fun1

The reference or the name of one of the predefined basic binary operators.

Fun2

The reference or the name of one of the predefined basic binary operators.

Value

a FlashR vector if the second argument is a vector; a FlashR matrix if the second argument is a matrix.

Author(s)

Da Zheng <dzheng5@jhu.edu>

Examples

mat1 <- fm.runif.matrix(1000, 100)
mat2 <- fm.runif.matrix(100, 10)
mat <- fm.inner.prod(mat1, mat2, "*", "+")
mat <- fm.inner.prod(mat1, mat2, fm.bo.mul, fm.bo.add)