How can I retrieve the historical values for RIC .AD.US using either the Eikon Data API, or the Hist

For RIC .AD.US I am able to bring in current values using Eikon Data API and RDP,, but not historical... can you please guide on best way to bring in any of these fields historically... It seems they are available via Eikon Excel; but when I try using ek.get_data() I am only able to retrieve the most recent value; ek.get_timeseries() does provide a time series of total volume but nother else. I really need the number of Avancers and decliners historically.

When I try using rdp.HistoricalPricing.get_summaries('AD.US') I get "None" as an output.


df, err = ek.get_data(['.AD.US'], ['ISSUES_ADV','ISSUES_DEC','ISSUES_UNC',

'TOT_ISSUES','NEW_HIGHS','VOLUME_ADV',

'VOLUME_DEC','VOLUME_UNC','TOT_VOLUME','NEW_LOWS'])

df


image

Best Answer

  • Function layer of RDP Library is easier to use (but less flexible) than Content Layer. So, the easiest way to retrieve this data is to use the function layer of RDP Library:

    rdp.get_historical_price_summaries('.AD.US')

    The above function returns pandas dataframe.

    image

    This said, you should be able to use Content layer, if you wish. On my end I do not reproduce rdp.HistoricalPricing.get_summaries('.AD.US') returning None. It returns an object of type "refinitiv.dataplatform.content.data.historical_pricing.HistoricalPricing.HistoricalPricingResponse". To extract the payload from this object you need to utilize object's properties and methods. E.g. to get the same result you get from rdp.get_historical_price_summaries function you can use

    res = rdp.HistoricalPricing.get_summaries('.AD.US')
    res.data.df

    image

Answers

  • Hi @James.Perkins,

    You can use the Historical Pricing API.

    Try this example retrieving daily values in the month of Dec 2020.

    rdp.get_historical_price_summaries(
    universe = '.AD.US',
    interval = rdp.Intervals.DAILY,
    start = '2020-12-01',
    end = '2020-12-31'
    )

    image

  • thank you Nick.

  • thank you again for the answer; why do none of the above solutions seem to work for RIC .IBBEU003D ?