Grouping.Resample Method
Definition
Namespace: Numerics.NET.DataAnalysis
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.4
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.4
Overload List
Resample( | Creates a grouping that resamples the observations according to the specified recurrence. |
Resample<R>(Index<R>, Index<R>, Direction) | Creates a grouping that resamples the observations from one index to another. |
Resample(Index<DateTime>, Recurrence, Direction)
Creates a grouping that resamples the observations
according to the specified recurrence.
public static Grouping<DateTime> Resample(
Index<DateTime> index,
Recurrence recurrence,
Direction direction = Direction.Backward
)
Parameters
- index Index<DateTime>
- The original index.
- recurrence Recurrence
- The recurrence pattern to resample to.
- direction Direction (Optional)
- Indicates whether the entries in index should be taken as the start (Forward) or end (Backward) of a sampling interval.
Return Value
Grouping<DateTime>A grouping object that represents the resampling.
Exceptions
Argument | index is null. -or- recurrence is null. |
Resample<R>(Index<R>, Index<R>, Direction)
Creates a grouping that resamples the observations
from one index to another.
public static Grouping<R> Resample<R>(
Index<R> oldIndex,
Index<R> newIndex,
Direction direction
)
Parameters
- oldIndex Index<R>
- The original index.
- newIndex Index<R>
- The new index.
- direction Direction
- Indicates whether the entries in newIndex should be taken as the start (Forward) or end (Backward) of a sampling interval.
Type Parameters
- R
- The element type of the indexes.
Return Value
Grouping<R>A grouping object that represents the resampling.
Exceptions
Argument | oldIndex is null. -or- newIndex is null. |
Invalid | oldIndex or newIndex is not sorted. -or- oldIndex and newIndex do not have the same sort order. |