Skip to main content

sandbox_quant/execution/
target_translation.rs

1use crate::domain::exposure::Exposure;
2
3#[derive(Debug, Clone, Copy, PartialEq)]
4pub struct TargetNotional {
5    pub target_usdt: f64,
6}
7
8pub fn exposure_to_notional(exposure: Exposure, equity_usdt: f64) -> TargetNotional {
9    TargetNotional {
10        target_usdt: exposure.value() * equity_usdt,
11    }
12}