For a deeper look into our Eikon Data API, look into:

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
1 1 0 0

EPS Trailing 12 Months of a company

Hello, I am trying to download on Python the EPS Trailing 12 month of a company.


Until now, I found the EPS reported for the last Year of the company, using the command:

data_EPS = ek.get_data('AAPL.O', ["TR.EPSActValue.calcdate","TR.EPSActValue"], {"SDate":"0", "EDate" : "0", "Frq" : "Y"})[0].dropna()

and I correctly find the estimate 3.28 for 2020


However, I would like to get the code for EPS Traiing 12 month, which corresponds to the last 4 available reported quarters.
In the case of AAPL.O, the company already reported Q121 results and the estimated value should be 3.70.

What is the correct field to be entered?
If it is required to use Datastream colud you provide me the whole formula please?


Thank you for your help


Daniele

eikoneikon-data-apiworkspaceworkspace-data-apirefinitiv-dataplatform-eikonpythondata
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Upvote
Accepted
6.7k 8 6 7

@daniele.bonanomi If you want the last 4 quarters you can try:

data_EPS,err = ek.get_data('AAPL.O', ["TR.EPSActValue.date","TR.EPSActValue"], {"SDate":"-3", "EDate" : "0", "Period":"FQ0","Frq" : "FQ"})

data_EPS

Im not sure if this is what you want or if you want the sum of these values? I hope this can help.


1612781743207.png (38.9 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Upvotes
1 1 0 0

Hi Jason, thank you for your help
Yes, I need the field for the yearly estimate, which is basically the sum of the 4 EPS that you reported.

I will sum them together

Thanks

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Click below to post an Idea Post Idea