Count


Summary

Gets the total number of elements contained in the DataSeries.

Syntax

public int Count{ get; }

Example 1

protected override void OnTick()
{
    int total = MarketSeries.Close.Count;
    Print("The total elements contained in the MarketSeries.Close Series is: {0}", total);
    int lastIndex = total - 1;    
    double lastCloseValue = MarketSeries.Close[lastIndex];
    //Print the last value of the series
    Print("The last value of Close Series is: {0}", lastCloseValue);
}