matrixUtil

vecxt.matrixUtil
object matrixUtil

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
matrixUtil.type

Members list

Type members

Classlikes

enum Horizontal

Attributes

Supertypes
trait Enum
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
enum Vertical

Attributes

Supertypes
trait Enum
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Extensions

Extensions

extension [A](m: Matrix[A])
inline def col(i: Int)(using ClassTag[A]): Array[A]

Note that m.submatrix(::, i) will give back a zero-copy matrix with the correct strides.

Note that m.submatrix(::, i) will give back a zero-copy matrix with the correct strides.

It is probably more efficient

Attributes

inline def diag(using ClassTag[A]): Array[A]
inline def diag(col: Col, startFrom: Vertical, direction: Horizontal)(using ClassTag[A]): Array[A]
inline def diag(row: Row, startFrom: Horizontal, direction: Vertical)(using ClassTag[A]): Array[A]
inline def horzcat(m2: Matrix[A])(using inline boundsCheck: BoundsCheck, ct: ClassTag[A]): Matrix[A]
inline def mapCols[B](inline f: Array[A] => Array[B])(using ClassTag[B], ClassTag[A]): Matrix[B]
inline def mapColsInPlace(inline f: Array[A] => Array[A])(using ClassTag[A]): Unit
inline def mapColsToScalar[B](inline f: Array[A] => B)(using ClassTag[B], ClassTag[A])(using inline boundsCheck: BoundsCheck): Matrix[B]
inline def mapRows[B](inline f: Array[A] => Array[B])(using ClassTag[B], ClassTag[A]): Matrix[B]
inline def mapRowsInPlace(inline f: Array[A] => Array[A])(using ClassTag[A]): Unit

There should be

There should be

Attributes

inline def mapRowsToScalar[B](inline f: Array[A] => B)(using ClassTag[B], ClassTag[A]): Matrix[B]
inline def printMat(using ClassTag[A]): String
inline def row(i: Int)(using ClassTag[A]): Array[A]

Returns a row of the matrix as an NArray.

Returns a row of the matrix as an NArray.

Note that this copies the data. m.submatrix(i, ::) returns a zero copy view.

Attributes

inline def transpose: Matrix[A]
inline def vertcat(m2: Matrix[A])(using inline boundsCheck: BoundsCheck, ct: ClassTag[A]): Matrix[A]