NeedForTrade Documentation

Bar Class

Represents bar. Bar type is used to represent market data. Bars can be


Bar members:


    // Properties
    BarType BarType

    double Close
    double High
    bool IsValid
    double Low
    double Open
    double OpenInterest
    double Volume

    DateTime Time		// EndTime of the bar
    TimeSpan TimeInterval	// Time interval between StartTime and EndTime

    DateTime StartTime
    DateTime EndTime
    DateTime UniversalEndTime     // EndTime in UTC (GMT) time
    DateTime UniversalStartTime   // StartTime in UTC (GMT) time
    DateTime UniversalTime        // EndTime in UTC (GMT) time

    // Methods
    bool ContainsTime(DateTime time);
    bool ContainsUniversalTime(DateTime universalTime);
    bool ContainsPrice(double price);

Bar properties are read-only. You can access Bar properties by using dot operator. For example: open = Bars[0].Open;