Hi, Using the Eikon API, I'm trying to use ek.get_data to get historical data for a stock index (0#.SPX) in order able to calculate how each index component's closed on each day compared to its 52 week high as of that same day. However, it appears that "TR.Price52WeekHigh" does not include historical data, only a stock's 52 week high as of right now.
Am I missing something? Is there a smart/simple way to get a stock's 52 week high as of a date in the past without also getting its entire closing price history for 52 weeks previous to that date and calculating the 52 week high myself? Doing that for hundreds of components of an index over years of trading seems inefficient.
I'm a journalist and my overall goal is to be able to say, "Today, ? number of S&P 500 stocks were trading down 20% or more from their 52 week highs, the highest number since xx date."
Many thanks!