Hi QC team, 

First off thanks for the work you’ve done to maintain and improve QC. It has very impressive capabilities and having attempted to create my own simple equity backtester I can only imagine the difficulty of the work.

I am trying to create a dynamic universe for an equity backtest. The universe largely depends on trends of fundamentals, specifically EarningReports.BasicEPS, such that I want the reported values and dates they were released from the last 2 years. I cannot use EarningReports.BasicEPS.TwelveMonths, as I need data further back in time.

I have written some basic code to attempt to log the earnings reports and their filing date. I do my coarse filtering and then access the dataframe containing the fundamental data of the coarse symbols. In my code I commented this out and just hard coded AAPL so that I could verify the logs. I then log the date and the earningreports.BasicEPS.ThreeMonths to get the most recent reported earnings. 

There are two problems:

1. The BasicEPS from the historical dataframe in universe selection is reported multiple days late

2. The format of the FileDate of the earnings report is confusing

For problem 1, know that external sources say that an earnings report was released on 2023-11-02 for AAPL. On a universe selection performed on 2023-11-03, the BasicEPS value is 1.27 and on a universe selection on 2023-11-04, the BasicEPS value is 1.47. The backtest should have access to the BasicEPS on 2023-11-03 since it was reported the day before. This likely won’t have a large affect on my filtering process but I’d like to know if this is a mistake or a feature.

For problem 2, I want to know how to access the earnings release dates so that I know when new earnings are reported. I need this to distinguish in the event that two successive earnings reports are the equal. On a universe selection performed on 2023-11-03, the BasicEPS value is 1.27 and the FileDate output is: 3M:8/4/2023 12:00:00 AM; 6M:5/5/2023 12:00:00 AM; 9M:8/4/2023 12:00:00 AM; 12M:10/28/2022 12:00:00 AM. The 3M value makes sense since the that is the day after the earnings report for the previous quarter was released. But why is the 9M also that date? Don’t these parameters refer to which previous quarter the BasicEPS is from, 3M being the most recent and 12M being the report for the same quarter a year ago? Then on a universe selection from 2023-11-04, the BasicEPS value is 1.47, and the FileDate output is: 3M:8/4/2023 12:00:00 AM;6M:5/5/2023 12:00:00 AM;9M:8/4/2023 12:00:00 AM;12M:11/3/2023 12:00:00 AM. Why isn’t the 3M updated to 11/3/2023 since it is now the most recent reported date and instead it was updated in the 12M value?

In the end I just want to, for each stock, run simple calculations on the last 8 quarters of earnings, if available, and updated whenever the new earnings report is released. If there is a more efficient way to do this in QC I would love to know! Thanks in advance. I have added my backtest for reference