FinancialDataLoader<T>
Models & Types · AiDotNet.Finance.Data
Data loader for financial time series forecasting.
Inheritance: DataLoaderBase<T> → InputOutputDataLoaderBase<T, Tensor<T>, Tensor<T>> → FinancialDataLoader<T>
For Beginners
This loader creates training samples like:
- Input: the last N time steps (lookback window)
- Output: the next M time steps (prediction horizon)
It handles batching, shuffling, and splitting into train/val/test.
How It Works
FinancialDataLoader turns a list of OHLCV points into windowed tensors suitable for training forecasting models. It implements the standard InputOutputDataLoader API so it works with AiDotNet’s training pipeline.
Constructors
| Constructor | Summary |
|---|---|
FinancialDataLoader(IReadOnlyList<MarketDataPoint<T>> series, int sequenceLength, int predictionHorizon, bool includeVolume, bool includeReturns, bool predictReturns, bool normalizeMinMax, FinancialPreprocessor<T> preprocessor, int batchSize) |
Creates a new financial data loader. |
Properties
| Property | Summary |
|---|---|
int FeatureCount { get; } |
|
int OutputDimension { get; } |
|
int TotalCount { get; } |
|
string Description { get; } |
|
string Name { get; } |
Methods
| Method | Summary |
|---|---|
ValueTuple<IInputOutputDataLoader<T, Tensor<T>, Tensor<T>>, IInputOutputDataLoader<T, Tensor<T>, Tensor<T>>, IInputOutputDataLoader<T, Tensor<T>, Tensor<T>>> Split(double trainRatio, double validationRatio, int? seed) |