api / koma.matrix.ejml / EJMLMatrixFactory
EJMLMatrixFactory
class EJMLMatrixFactory :DoubleFactoryBase<EJMLMatrix>
Constructors
| Name | Summary |
|---|---|
| <init> | EJMLMatrixFactory() |
Functions
| Name | Summary |
|---|---|
| create | fun create(data:IntRange):EJMLMatrixCreates a row-vector with initial values pulled from an int range, e.g. 1..45 fun create(data:DoubleArray):EJMLMatrixCreates a row-vector with initial values pulled from a double array fun create(data:Array<DoubleArray>):EJMLMatrixCreates a matrix from an array of arrays (row-major) |
| eye | fun eye(size:Int):EJMLMatrixCreates an identity matrix of the requested shape fun eye(rows:Int, cols:Int):EJMLMatrixCreates an identity matrix of the requested shape, with zero padding if the axis lengths arent equal. |
| ones | fun ones(rows:Int, cols:Int):EJMLMatrixCreates a one initialized matrix of the requested shape |
| zeros | fun zeros(rows:Int, cols:Int):EJMLMatrixGenerate a zero initialized matrix of the requested shape. |
Inherited Functions
| Name | Summary |
|---|---|
| arange | open fun arange(start:Double, stop:Double, increment:Double):Topen fun arange(start:Int, stop:Int, increment:Int):TCreates a row-vector with the first value of start and the last value of stop, with increment steps between each value. open fun arange(start:Double, stop:Double):Topen fun arange(start:Int, stop:Int):TCreates a row-vector with the first value of start and the last value of stop, with unit steps between each value. |
| rand | open fun rand(rows:Int, cols:Int):TCreates a matrix of uniform 0-1 random samples |
| randn | open fun randn(rows:Int, cols:Int):TCreates a matrix of unit-normal random samples |