List Vector<T>.Map Method
Definition
Namespace: Numerics.NET.DataAnalysis
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 10.2.0
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 10.2.0
Overload List
| Map<TResult>(Func<T, TResult>) | Applies a transformation to each element in each list. |
| Map<U>(Func<T, U>) | Applies a function to the elements of a vector and returns the result. |
| Map<TScalar, TResult>(Vector<TScalar>, Func<T, TScalar, TResult>) | Applies a transformation to each element in each list, using a corresponding scalar value per list. |
| Map<TScalar1, TScalar2, TResult>(Vector<TScalar1>, Vector<TScalar2>, Func<T, TScalar1, TScalar2, TResult>) | Applies a transformation to each element in each list, using two corresponding scalar values per list. |
Map<TResult>(Func<T, TResult>)
Applies a transformation to each element in each list.
public ListVector<TResult> Map<TResult>(
Func<T, TResult> func
)
Parameters
Type Parameters
- TResult
- The result type of the transformation.
Return Value
ListVector<TResult>A new list vector with transformed elements.
Map<TScalar, TResult>(Vector<TScalar>, Func<T, TScalar, TResult>)
Applies a transformation to each element in each list, using a corresponding scalar value per list.
public ListVector<TResult> Map<TScalar, TResult>(
Vector<TScalar> scalars,
Func<T, TScalar, TResult> func
)
Parameters
- scalars Vector<TScalar>
- A vector of scalar values, one per list.
- func Func<T, TScalar, TResult>
- The function to apply to each element and its corresponding scalar.
Type Parameters
- TScalar
- The type of the scalar values.
- TResult
- The result type of the transformation.
Return Value
ListVector<TResult>A new list vector with transformed elements.
Map<TScalar1, TScalar2, TResult>(Vector<TScalar1>, Vector<TScalar2>, Func<T, TScalar1, TScalar2, TResult>)
Applies a transformation to each element in each list, using two corresponding scalar values per list.
public ListVector<TResult> Map<TScalar1, TScalar2, TResult>(
Vector<TScalar1> scalars1,
Vector<TScalar2> scalars2,
Func<T, TScalar1, TScalar2, TResult> func
)
Parameters
- scalars1 Vector<TScalar1>
- A vector of first scalar values, one per list.
- scalars2 Vector<TScalar2>
- A vector of second scalar values, one per list.
- func Func<T, TScalar1, TScalar2, TResult>
- The function to apply to each element and its corresponding scalars.
Type Parameters
- TScalar1
- The type of the first scalar values.
- TScalar2
- The type of the second scalar values.
- TResult
- The result type of the transformation.
Return Value
ListVector<TResult>A new list vector with transformed elements.