ListVector<T>.ToColumnMatrix Method

Definition

Namespace: Numerics.NET.DataAnalysis
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 10.2.0

Overload List

ToColumnMatrix() Creates a matrix with the vector as its only column..
ToColumnMatrix(T) Converts the list vector to a matrix with lists in columns, padding or truncating as necessary.
ToColumnMatrix(Int32, T) Converts the list vector to a matrix with lists in columns, padding or truncating as necessary.

ToColumnMatrix(T)

Converts the list vector to a matrix with lists in columns, padding or truncating as necessary.
C#
public Matrix<T> ToColumnMatrix(
	T paddingValue
)

Parameters

paddingValue  T
The value to use for padding short lists.

Return Value

Matrix<T>
A matrix where each column corresponds to a list.

Remarks

Lists shorter than the maximum list length are padded with paddingValue. Lists longer than the maximum are truncated. The resulting matrix has as many columns as there are lists, and as many rows as the length of the longest list.

ToColumnMatrix(Int32, T)

Converts the list vector to a matrix with lists in columns, padding or truncating as necessary.
C#
public Matrix<T> ToColumnMatrix(
	int rowCount,
	T paddingValue
)

Parameters

rowCount  Int32
The number of rows in the resulting matrix.
paddingValue  T
The value to use for padding short lists.

Return Value

Matrix<T>
A matrix where each column corresponds to a list.

Remarks

Lists shorter than rowCount are padded with paddingValue. Lists longer than rowCount are truncated to the specified length.

See Also