Here is the original indicator:
protected override void Initialize()
{
Add(new Plot(Color.FromKnownColor(KnownColor.Orange), PlotStyle.Line, "Plot0"));
Overlay = false;
Add("WBS 07-11",PeriodType.Second, 1, MarketDataType.Ask);
Add("WBS 07-11",PeriodType.Second, 1, MarketDataType.Bid);
}
/// <summary>
/// Called on each bar update event (incoming tick)
/// </summary>
protected override void OnBarUpdate()
{
if (CurrentBars[0] < 0 || CurrentBars[1] < 0) return;
Plot0.Set((Closes[1][0]) - (Closes[2][0]));
}
#region Properties
[Browsable(false)] // this line prevents the data series from being displayed in the indicator properties dialog, do not remove
[XmlIgnore()] // this line ensures that the indicator can be saved/recovered as part of a chart template, do not remove
public DataSeries Plot0
{
get { return Values[0]; }
}
#endregion
Comment