For a deeper look into our Eikon Data API, look into:
Overview | Quickstart | Documentation | Downloads | Tutorials | Articles
With Eikon Data API version 1.1.8
I just tested this code and this should be the code you are looking for:
syntax = "Hospital AND ( build OR reopen OR construct OR expansion OR upgrade OR develop OR repurpose OR modern )" df = ek.get_news_headlines(syntax) df
Many Thanks! One last thing. Can we filter news based on most important? We can do that in Eikon Desktop.
I believe that it is not possible to filter by "only important" with ek.get_news_headlines()
You can run help(ek.get_news_headlines) to see the function description.
@alankar.gupta you can double click on the query in NEWS monitor app and it will generate the query string for you which you can copy and paste into the get_news_headlines() API call. Please see my article which goes through this. I hope this can help.
Hello Jason. I think i need to convert this to a python format before copy pasting it. That's what i am trying to understand.
I was trying with this query but it's not working.
df = ek.get_news_headlines(query="Hospital\\\" AND \\\ ("build\\\" OR \\\"reopen\\\" OR \\\"construct\\\" OR \\\"expansion\\\" OR \\\"upgrade\\\" OR \\\"develop\\\" OR \\\"repurpose\\\" OR \\\"modern\\\" ))
Can You help me with this?