.NET SDK Timeseries extraction

Options

Client is looking for a script to extract timeseries data for any equity instrument since 1980. The tutorial guide does not contain any examples which match this requirement.

Can you please share a sample script for MSFT.O and hisotrical price for OPEN Price , HIGH Price , LOW Price , CLOSE Price and volume from period of 1980 to till date?

Best Answer

  • nityanand.koppad
    Answer ✓

    @Meenakshi.Swarnkar

    Please use below example

     {
    IdentifierList = InstrumentIdentifierList.Create(
    new[]
    {
    new InstrumentIdentifier { Identifier = "MSFT.O", IdentifierType = IdentifierType.Ric }
    }, null, false),
    ContentFieldNames = new[] {"RIC", "Trade Date", "Universal Close Price", "High Price", "Low Price", "Open Price", "Volume"},
    Condition = new TimeSeriesCondition
    {
    StartDate = new DateTimeOffset(new DateTime(1980, 01, 01)),
    EndDate = new DateTimeOffset(new DateTime(2019, 01, 25))
    }
    };