pub struct ChartTypeParams {Show 28 fields
pub styles: ChartTypeStyles,
pub renko_size_method: BoxSizeMethod,
pub kagi_size_method: BoxSizeMethod,
pub range_size_method: BoxSizeMethod,
pub pnf_size_method: BoxSizeMethod,
pub renko_source: PriceBasedSource,
pub kagi_source: PriceBasedSource,
pub line_break_source: PriceBasedSource,
pub pnf_source: PriceBasedSource,
pub renko_wicks: bool,
pub renko_brick_size: f64,
pub kagi_reversal: f64,
pub range_size: f64,
pub pnf_box_size: f64,
pub pnf_reversal: u32,
pub line_break_count: usize,
pub baseline: BaselineLevel,
pub columns_base: Option<f64>,
pub tpo_period_minutes: u32,
pub tpo_initial_balance_minutes: u32,
pub tpo_poor_highs_lows: bool,
pub tpo_initial_balance_extensions: bool,
pub tpo_row_ticks: u32,
pub tpo_value_area: f64,
pub tpo_split_sessions: bool,
pub tpo_single_prints: bool,
pub tpo_letters: bool,
pub tpo_composites: Vec<RangeInclusive<DateTime<Utc>>>,
}Expand description
The parameters of the chart types that need them. Sizes are in price units and are used as given; a size the chart cannot use is reported on the chart instead of being replaced.
Fields§
§styles: ChartTypeStylesIndependent line, area and baseline styles, retained across chart type changes.
renko_size_method: BoxSizeMethodRenko: method resolved once from loaded history, then frozen while bars stream.
kagi_size_method: BoxSizeMethodKagi: method for its reversal amount.
range_size_method: BoxSizeMethodRange bars: method for their range.
pnf_size_method: BoxSizeMethodPoint and Figure: method for its box size.
renko_source: PriceBasedSourceRenko: close or high/low input, also used for wick extremes.
kagi_source: PriceBasedSourceKagi: close or high/low input.
line_break_source: PriceBasedSourceLine Break: close or high/low input.
pnf_source: PriceBasedSourcePoint and Figure: high/low, the traditional method, or close input.
renko_wicks: boolDraw Renko wicks from the brick’s actual high and low.
renko_brick_size: f64Renko: size of a brick.
kagi_reversal: f64Kagi: the move against the line that starts a new line.
range_size: f64Range bars: the range of a bar from its low to its high.
pnf_box_size: f64Point and Figure: the size of a box.
pnf_reversal: u32Point and Figure: the number of boxes a move against the column must cover to start a new one.
line_break_count: usizeLine Break: the number of lines a close must break through to reverse, 1 to 10.
baseline: BaselineLevelBaseline: where the base line is drawn.
columns_base: Option<f64>Columns: the price the columns rise above or fall below; None draws them up from the
pane bottom.
tpo_period_minutes: u32TPO: minutes per period, raised to the bar interval when shorter.
tpo_initial_balance_minutes: u32TPO: minutes from the session open included in the initial balance, 60 by default.
tpo_poor_highs_lows: boolTPO: mark the highest and lowest rows when they hold more than one TPO.
tpo_initial_balance_extensions: boolTPO: draw one and two initial balance ranges above its high and below its low.
tpo_row_ticks: u32TPO: instrument ticks per price row. Zero, or an instrument without a tick size, fits about 40 rows to the visible price range, each a whole number of the instrument’s ticks when it has a tick size.
tpo_value_area: f64TPO: share of the TPOs in the value area, in percent.
tpo_split_sessions: boolTPO: separate profiles for pre-market, regular and post-market hours.
tpo_single_prints: boolTPO: highlight the rows touched by a single period.
tpo_letters: boolTPO: paint each period’s letter inside its block.
tpo_composites: Vec<RangeInclusive<DateTime<Utc>>>TPO: sessions combined into one profile, as in
TPOConfig::composites.
Implementations§
Source§impl ChartTypeParams
impl ChartTypeParams
Sourcepub fn tpo_config(&self, tick_size: Option<f64>) -> TPOConfig
pub fn tpo_config(&self, tick_size: Option<f64>) -> TPOConfig
The TPO settings for an instrument with minimum price increment tick_size, as the TPO
chart type builds its profiles with them.
Sourcepub fn with_atr_renko(atr: f64, multiplier: f64) -> Self
pub fn with_atr_renko(atr: f64, multiplier: f64) -> Self
Create with ATR-based Renko brick size
Trait Implementations§
Source§impl Clone for ChartTypeParams
impl Clone for ChartTypeParams
Source§fn clone(&self) -> ChartTypeParams
fn clone(&self) -> ChartTypeParams
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 ChartTypeParams
impl Debug for ChartTypeParams
Source§impl Default for ChartTypeParams
impl Default for ChartTypeParams
Source§impl<'de> Deserialize<'de> for ChartTypeParamswhere
ChartTypeParams: Default,
impl<'de> Deserialize<'de> for ChartTypeParamswhere
ChartTypeParams: Default,
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>,
Source§impl PartialEq for ChartTypeParams
impl PartialEq for ChartTypeParams
Source§impl Serialize for ChartTypeParams
impl Serialize for ChartTypeParams
impl StructuralPartialEq for ChartTypeParams
Auto Trait Implementations§
impl Freeze for ChartTypeParams
impl RefUnwindSafe for ChartTypeParams
impl Send for ChartTypeParams
impl Sync for ChartTypeParams
impl Unpin for ChartTypeParams
impl UnsafeUnpin for ChartTypeParams
impl UnwindSafe for ChartTypeParams
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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