pub struct BacktestConfig {
pub cost_model: CostModel,
pub timestamp_col: String,
pub symbol_col: Option<String>,
pub close_col: String,
pub signal_col: String,
pub entry_filter_col: Option<String>,
pub size_multiplier_col: Option<String>,
}Expand description
Configuration for a backtest run.
Fields§
§cost_model: CostModel§timestamp_col: StringColumn names (customizable for long-format flexibility).
symbol_col: Option<String>§close_col: String§signal_col: StringSignal column: f64 or bool/int. >0 means desired long exposure (units for sizing). For rich PA + features/regime in batch DF path: pre-compute an ‘exposure’ col (e.g. via Polars exprs on ta.features + PA struct fields) and/or use the streaming path (run_streaming_simulation + Next impl emitting StrategySignal with metadata for pole_height etc). Full native Struct signal_col support (auto meta extract + filter/size cols) is the 06sz extension point (see entry_filter_col etc below; implemented for streaming today).
entry_filter_col: Option<String>Optional boolean col: dynamic entry filter (AND with signal). For regime labels/probs or feature thresholds (ta.features outputs). Batch path uses pre-filtered DF or scalar exposure=0 when false; streaming uses in generator.
size_multiplier_col: Option<String>Optional f64 col: position size modulator (multiplies signal exposure). E.g. pole_height normalized or regime_prob. Enables ‘sized by pole’.
Trait Implementations§
Source§impl Clone for BacktestConfig
impl Clone for BacktestConfig
Source§fn clone(&self) -> BacktestConfig
fn clone(&self) -> BacktestConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for BacktestConfig
impl Debug for BacktestConfig
Source§impl Default for BacktestConfig
impl Default for BacktestConfig
Source§impl<'de> Deserialize<'de> for BacktestConfig
impl<'de> Deserialize<'de> for BacktestConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for BacktestConfig
impl RefUnwindSafe for BacktestConfig
impl Send for BacktestConfig
impl Sync for BacktestConfig
impl Unpin for BacktestConfig
impl UnsafeUnpin for BacktestConfig
impl UnwindSafe for BacktestConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.