Trading System API  3.0
Library for Simulating and Deploying Trading and Investment Strategies
tsa::plot::bar Class Reference

Plots a 'bars' on a chart pane where bars are drawn from the zero line. Bars essentially oscillate around the zero line with values are both positive and negative. More...

#include <TSCPlots.h>

Inheritance diagram for tsa::plot::bar:
tsa::plot::plot_base

Public Member Functions

 bar (const tsa::variant &value, const color &color=color::auto_color, size_t weight=DEFAULT_WEIGHT, bool dynamicColor=false)
 Constructor. More...
 
 bar (const tsa::variant &value, const color &colorPrim, const color &colorSec, size_t weight=DEFAULT_WEIGHT)
 x More...
 
 ~bar (void)
 Destructor.
 
- Public Member Functions inherited from tsa::plot::plot_base
 plot_base (void)
 Constructor.
 
 plot_base (plot_type_t _t, const tsa::variant &_v, const color &_pc, const color &_sc, size_t _w, bool _dc, int _js, bool _has_pivot, double _piv)
 
 plot_base (plot_type_t _t, size_t _nv, const color &_pc, const color &_sc, size_t _w, bool _dc, int _js, bool _has_pivot, double _piv)
 
 ~plot_base (void)
 

Detailed Description

Plots a 'bars' on a chart pane where bars are drawn from the zero line. Bars essentially oscillate around the zero line with values are both positive and negative.

Constructor & Destructor Documentation

tsa::plot::bar::bar ( const tsa::variant value,
const color color = color::auto_color,
size_t  weight = DEFAULT_WEIGHT,
bool  dynamicColor = false 
)
explicit

Constructor.

Parameters
valueThe current value to be drawn.
colorThe bar color.
weightThe bar weight / width.
dynamicColorSet this to true if the bar color may change from bar to bar.
tsa::plot::bar::bar ( const tsa::variant value,
const color colorPrim,
const color colorSec,
size_t  weight = DEFAULT_WEIGHT 
)
explicit

x

Parameters
valueThe current value to be drawn.
colorPrimPrimary color
colorSecSecondary color
weightThe bar weight / width.