pub struct RiskConfigChange {
pub settle_ccy: String,
pub max_loss: f64,
pub eloss_floor: f64,
pub max_pliq: f64,
pub margin_buffer: f64,
pub corr_discount: f64,
pub meta: ActionMeta,
}Expand description
Risk configuration
- target maximum dollar loss
- minimum eloss bps
- maximum p(liquidation) allowed
We determine the E[loss] threshold as:
let eloss_notional = max_loss / notional * 1e4;
let eloss_max = (4.0 * max_loss) / notional * 1e4;
let eloss_target = f64::max(eloss_notional, eloss_floor).min(eloss_max)Fields§
§settle_ccy: String§max_loss: f64§eloss_floor: f64§max_pliq: f64§margin_buffer: f64§corr_discount: f64§meta: ActionMetaTrait Implementations§
Source§impl Clone for RiskConfigChange
impl Clone for RiskConfigChange
Source§fn clone(&self) -> RiskConfigChange
fn clone(&self) -> RiskConfigChange
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RiskConfigChange
impl Debug for RiskConfigChange
Source§impl<'de> Deserialize<'de> for RiskConfigChange
impl<'de> Deserialize<'de> for RiskConfigChange
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>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for RiskConfigChange
impl RefUnwindSafe for RiskConfigChange
impl Send for RiskConfigChange
impl Sync for RiskConfigChange
impl Unpin for RiskConfigChange
impl UnsafeUnpin for RiskConfigChange
impl UnwindSafe for RiskConfigChange
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
Mutably borrows from an owned value. Read more