Matlab Data Object.As Matrix<T> Method
Attempts to convert the object to a matrix with the specified element type.
Definition
Namespace: Numerics.NET.Data.Matlab
Assembly: Numerics.NET.Data (in Numerics.NET.Data.dll) Version: 4.0.3
C#
The new matrix if successful; otherwise null.
Assembly: Numerics.NET.Data (in Numerics.NET.Data.dll) Version: 4.0.3
public virtual Matrix<T> AsMatrix<T>(
bool strict = true
)
Parameters
- strict Boolean (Optional)
- Specifies whether the element type should be matched exactly (true), or whether conversions are allowed (false).
Type Parameters
- T
- The element type of the matrix
Return Value
Matrix<T>The new matrix if successful; otherwise null.
Implements
IDataObject<TObject>.AsMatrix<T>(Boolean)Remarks
The conversion may fail for two reasons. Either the object is not a matrix or vector, or the element type of the matrix cannot be cast to T.