#[non_exhaustive]pub struct ComparisonRow {Show 19 fields
pub label: String,
pub strategy_name: String,
pub symbol: String,
pub total_return_pct: f64,
pub annualized_return_pct: f64,
pub sharpe_ratio: f64,
pub sortino_ratio: f64,
pub calmar_ratio: f64,
pub max_drawdown_pct: f64,
pub win_rate: f64,
pub profit_factor: f64,
pub total_trades: usize,
pub kelly_criterion: f64,
pub sqn: f64,
pub expectancy: f64,
pub omega_ratio: f64,
pub time_in_market_pct: f64,
pub rank_score: f64,
pub rank: usize,
}Expand description
A single row in the comparison table — one strategy’s key metrics.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.label: StringUser-supplied label for the strategy (e.g. "SMA 10/50").
strategy_name: StringName embedded in the BacktestResult by the engine.
symbol: StringSymbol that was tested.
total_return_pct: f64Total return percentage.
annualized_return_pct: f64Annualised return percentage.
sharpe_ratio: f64Sharpe ratio.
sortino_ratio: f64Sortino ratio.
calmar_ratio: f64Calmar ratio.
max_drawdown_pct: f64Maximum drawdown as a fraction (0.0–1.0).
Multiply by 100 to get a conventional percentage.
win_rate: f64Win rate (winning_trades / total_trades).
profit_factor: f64Profit factor (gross_profit / gross_loss).
total_trades: usizeTotal number of completed trades.
kelly_criterion: f64Kelly Criterion: optimal capital fraction to risk per trade.
sqn: f64System Quality Number.
expectancy: f64Expectancy in dollar terms per trade.
omega_ratio: f64Omega Ratio.
time_in_market_pct: f64Time in market as a fraction (0.0–1.0).
rank_score: f64The score on the metric used to rank the comparison.
rank: usize1-based rank within the comparison (1 = best).
Trait Implementations§
Source§impl Clone for ComparisonRow
impl Clone for ComparisonRow
Source§fn clone(&self) -> ComparisonRow
fn clone(&self) -> ComparisonRow
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ComparisonRow
impl Debug for ComparisonRow
Source§impl<'de> Deserialize<'de> for ComparisonRow
impl<'de> Deserialize<'de> for ComparisonRow
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 ComparisonRow
impl RefUnwindSafe for ComparisonRow
impl Send for ComparisonRow
impl Sync for ComparisonRow
impl Unpin for ComparisonRow
impl UnsafeUnpin for ComparisonRow
impl UnwindSafe for ComparisonRow
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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 more