Giter Site home page Giter Site logo

eikonapir's People

Contributors

ahmedmohamedali avatar hoenie-ams avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

eikonapir's Issues

count in 'get_news_headlines.Rd' doesn't work

Thanks Ahmed for this package. Great work! I noticed the count in 'get_news_headlines.Rd' doesn't work.
I get the following error: "get_news_headlines error: count must be an integer"

Open Interest on time series

Hi,

Do you have a way to retrieve the field "open interest" of a time series RIC with the fonction "get_timeseries()" ?

Thank you.

Alban

errors with eikonapir queries

There seems to be a change in the Eikon interface that breaks previously running script running with eikonapir. Wanted you to be aware of the following thread in the developers forum https://community.developers.thomsonreuters.com/questions/28988/eikon-api-errors-in-previously-working-scripts.html.

In addition when running the get_symbology command with debug on there's a strange message about the app id, seems like it's "forgetting" the app id that was set just earlier:

eikonapir::set_app_id("7ed51e7f947b428f9690bac0c1116b122cac54a5")
get_symbology("MSFT.O","RIC","ISIN",raw_ouput = FALSE,debug = TRUE)
[1] "Request *************************************"
{"Entity":{"E":["SymbologySearch"],"W":{"symbols":[["MSFT.O"]],"from":["RIC"],"to":[["ISIN"]],"bestMatchOnly":[true]}}}
[1] "Response *************************************"
[1] "{"ErrorCode":1401,"ErrorMessage":"Application id ED142B67FBF0B94BAC3AB is invalid"}"
[1] "Response status *************************************"
[1] 403
Error in print.default("HTTP Error, code= ", response$status_code, sep = "") :
invalid 'digits' argument

Error in using get_timeseries

Hi,
I get an error retrieving some data. When I download ticker seperately everything is ok. But when I use a list I get an Error.

set_app_id('###########')
#No problem with this code
df = get_timeseries("AMb.CO",list(""),"2005-01-01T15:04:05","2016-01-10T15:04:05","monthly")
df = get_timeseries("AAK.ST",list("
"),"2005-01-01T15:04:05","2016-01-10T15:04:05","monthly")
df = get_timeseries("AAB.CO",list("*"),"2005-01-01T15:04:05","2016-01-10T15:04:05","monthly")

This gives the error:
df = get_timeseries(list("AMb.CO","AAK.ST","AAB.CO"),list("*"),"2005-01-01T15:04:05","2016-01-10T15:04:05","monthly")
Error in rbind(deparse.level, ...) :
numbers of columns of arguments do not match

Eikon API error

Hi,

I am getting the below error when I try Eikon api using R.
No encoding supplied: defaulting to UTF-8.
Error in print.default("HTTP Error, code= ", response$status_code, sep = "") :
invalid printing digits 503
Can you please help me to fix it?
Thanks,

time field in get_timeseries

Thanks for the package, looks good so far.
Time field in the get_timeseries() command does not seem to work, see issue I opened in TR Eikon API forum for details. Let me know where do you prefer to see issues as we work with the package in this beta stage, here or in the user forum.

regards

Real time News Headlines

Does this package work for downloading real time news? For example, if I am waiting for a news headlines that has not been published yet, like a company earnings, does this package support real time news headlines extraction?

And while on the topic of real time, does this package allow for real time prices and real time RIC updates?

Unable to get a list of all private companies of an specific country

Hi,

I´m trying to get a list of private companies that are listed on eikon using eikonapir.

The command lines are the following:
set_app_id("my_app_id")
type <- 'IN(Private(OrgType(COM, UNK, MKP)))/UNV:Private/)'
country <- 'IN(TR.HQCountryCode,"BR")'
companies <- paste0('SCREEN(U(',type,',',country,')')
columns <- list(TR_Field(field_name = 'TR.CommonName'))
list_companies <- get_data(companies,columns)

I was successful using this method for public companies, setting type as 'IN(Equity(active,public,primary))/UNV:Public/)'. But it´s not working for private companies.

Could you help me?

Cannot install package

I get the following message when I try to install the package:

> install_github("ahmedmohamedali/eikonapir")
Installation failed: Timeout was reached: Connection timed out after 10000 milliseconds

Installing devtools worked fine.

I'd appreciate any help.

documentation for eikon::set_app_id

Hi - it all works great for me so far - you might want to change the document files as the eikon::set_app_id('your_app_id') function syntax is wrongly written as eikon.set_app_id('your_app_id') - threw me off for a second :)

awesome work - will take it for more of a spin this weekend.

thx Jason

get_data mishandle column with NULL values

It seems that get_data cannot correctly handle columns with NULL/missing values.

Consider this:

ticker <- "0388.HK"
req.fields <- list("TR.EPSEstValue(Period=FY2019)", "TR.EPSEstValue(Period=FY2019).date", "TR.EPSEstValue(Period=FY2019).origdate", "TR.EPSEstValue(Period=FY2019).confirmdate")
get_data(ticker, req.fields)
   Instrument Earnings Per Share - Broker Estimate                 Date      Activation Date         Confirm Date
1     0388.HK                                 8.19 2018-03-01T15:00:00Z 2018-03-01T15:00:00Z 2018-03-02T00:00:00Z
2     0388.HK                                 6.94 2018-03-01T05:58:00Z 2018-03-01T05:58:00Z 2018-02-28T00:00:00Z
3     0388.HK                                  9.6 2018-04-12T12:00:00Z 2018-04-12T12:00:00Z 2018-04-13T00:00:00Z
4     0388.HK                               12.038 2018-01-29T16:35:00Z 2018-01-29T16:35:00Z 2018-03-01T00:00:00Z
5     0388.HK                                9.238 2018-04-12T08:27:00Z 2018-04-12T08:27:00Z 2018-03-20T00:00:00Z
6     0388.HK                                 9.41 2018-01-26T21:10:00Z 2018-01-26T21:10:00Z 2018-03-27T00:00:00Z
7     0388.HK                                 7.04 2017-10-03T14:00:00Z 2018-04-01T22:40:18Z                     
8     0388.HK                               10.684 2018-03-01T05:40:00Z 2018-03-01T05:40:00Z                     
9     0388.HK                                  9.2 2018-03-01T19:37:00Z 2018-03-01T19:37:00Z                     
10    0388.HK                                7.802 2018-03-01T14:57:00Z 2018-03-01T14:57:00Z                     
11    0388.HK                                11.99 2018-03-01T17:17:00Z 2018-03-01T17:17:00Z                     
12    0388.HK                                7.586 2018-03-05T10:30:00Z 2018-03-05T10:30:00Z                     
13    0388.HK                                 7.61 2018-02-28T12:20:00Z 2018-02-28T12:20:00Z                     
14    0388.HK                                  7.7 2018-01-11T07:47:00Z 2018-01-11T07:47:00Z                     
15    0388.HK                                 9.04 2018-03-01T09:22:00Z 2018-03-01T09:22:00Z                     
16    0388.HK                                 7.89 2018-02-28T21:54:00Z 2018-02-28T21:54:00Z                     
17    0388.HK                                7.978 2018-03-01T08:34:00Z 2018-03-01T08:34:00Z                     
18    0388.HK                                 8.75 2018-04-09T21:08:00Z 2018-04-09T21:08:00Z                     
19    0388.HK                                 7.32 2018-01-09T20:44:00Z 2018-01-09T20:44:00Z                     
20    0388.HK                                9.754 2018-02-28T14:15:00Z 2018-02-28T14:15:00Z      

Note that there are 5 confirm dates and they are all attached to the first 5 rows.

But, this is wrong.

From Eikon/Excel

in cell A1:
=TR("0388.HK","TR.EPSEstValue;TR.EPSEstValue.origdate;TR.EPSEstAge;TR.EPSEstFootNote","Period=FY2019 SDate=1D CH=Fd RH=IN;date;confirmdate;analystcode;brokername;isexcluded",B2)"

Output:

Ticker date confirmdate analystcode brokername isexcluded broker estimate Activation Date Age footnote
0388.HK 3/1/2018 15:00 Permission Denied 483808 FALSE 8.19 3/1/2018 15:00 48 NULL
0388.HK 3/1/2018 5:58 6CGC "MORNINGSTAR INC." FALSE 6.94 3/1/2018 5:58 48
0388.HK 4/12/2018 12:00 Permission Denied 73704 FALSE 9.6 4/12/2018 12:00 6 NULL
0388.HK 1/29/2018 16:35 3/2/2018 Permission Denied 7896 FALSE 12.038 1/29/2018 16:35 79 NULL
0388.HK 4/12/2018 8:27 786C NOMURA ASIAN EQUITY RESEARCH FALSE 9.238 4/12/2018 8:27 6 NULL
0388.HK 1/26/2018 21:10 2/28/2018 4AVH BNP PARIBAS GROUP FALSE 9.41 1/26/2018 21:10 82 NULL
0388.HK 10/3/2017 14:00 4INH RHB RESEARCH TRUE 7.04 4/1/2018 22:40 197 Contributor update pending: Estimate failed freshness policy
0388.HK 3/1/2018 5:40 4/13/2018 Permission Denied 25632 FALSE 10.684 3/1/2018 5:40 48 NULL
0388.HK 3/1/2018 19:37 7A4D CHINA EVERBRIGHT RESEARCH LTD FALSE 9.2 3/1/2018 19:37 48 NULL
0388.HK 3/1/2018 14:57 Permission Denied 128064 FALSE 7.802 3/1/2018 14:57 48 NULL
0388.HK 3/1/2018 17:17 3/1/2018 7GOU CHINA INTERNATIONAL CAPITAL CORPORATION (HONG KONG) LIMITED FALSE 11.99 3/1/2018 17:17 48 NULL
0388.HK 3/5/2018 10:30 Permission Denied 22760 FALSE 7.586 3/5/2018 10:30 44 NULL
0388.HK 2/28/2018 Permission Denied 32 FALSE 7.61 2/28/2018 12:20 49 NULL
0388.HK 1/11/2018 7HRJ KGI SECURITIES (SG) PTE LTD FALSE 7.7 1/11/2018 7:47 97 NULL
0388.HK 3/1/2018 7IA9 CHINA GALAXY INTERNATIONAL SECURITIES FALSE 9.04 3/1/2018 9:22 48 NULL
0388.HK 2/28/2018 Permission Denied 392 FALSE 7.89 2/28/2018 21:54 49 NULL
0388.HK 3/1/2018 772H UOB KAY HIAN PTE LTD FALSE 7.978 3/1/2018 8:34 48 NULL
0388.HK 4/9/2018 Permission Denied 36928 FALSE 8.75 4/9/2018 21:08 9 NULL
0388.HK 1/9/2018 3/20/2018 Permission Denied 23816 FALSE 7.32 1/9/2018 20:44 99 NULL
0388.HK 2/28/2018 14:15 3/27/2018 Permission Denied 2880 FALSE 9.754 2/28/2018 14:15 49 NULL

If we look at the first row or the R output,
forecast value is 8.19 with confirmdate of 2018-3-2
but, in Excel, forecast value for the first row is also 8.19, but there is no confirm date. Confirm date of 2018-3-2 is linked with the forecast value of 12.038 (row 4).

Furthermore, I noted that the sequence of confirm date is consistent in both results but R get_data does not inject NULL into the data frame correctly.

I haven't tested it with Python API yet. though.

Thanks,

Andy

get_timeseries - "corax " is not Working.

Hi,
I try to get an adjusted price and it didn't work.

corax parameter for the get_timeseries is not working.
"Error in set_string_property(payload, "corax", corax) :
object 'payload' not found"

Good job with the library!

Error to install

I got this error when I have tried to install: (Windows 10 Machine, R 4.2.2 )

devtools::install_github("ahmedmohamedali/eikonapir")

Using GitHub PAT from the git credential store.
Erro: Failed to install 'unknown package' from GitHub:
HTTP error 401.
Bad credentials

Rate limit remaining: 57/60
Rate limit reset at: 2024-06-25 21:52:05 UTC

Failed to connect to localhost port 9000:

Hi, when i run the command get_timeseries (or any other command) I get:

Error in curl::curl_fetch_memory(url, handle = handle) :
Failed to connect to localhost port 9000: Connection refused

The package used to work until some tiime ago, and I tried everything (reinstalling and more), but this did not solve the issue. Can you please let me know if you know a solution? thanks!

count parameter in get_timeseries()

The count parameter doesn't seem to work (or maybe I'm doing something wrong).

It seems to default 3000. If I try to increase or decrease the number. E.g., if I increase to 6000, still get 3000. If I decrease to 100, still get 3000 (or the maximum available).

Also, I need to do a as.integer() on any number submitted or I get an error saying it isn't an integer (which might be true but most functions of this type don't have this requirement).

proxy error after downloading latest version of package

I did an install of latest package from github hoping that by getting the version with the new port number to Eikon I'll be able to work without relogging every time I move from Eikon to R. Now I can't get any data, not when I'm logged in Eikon and not when I log in the separate Eikon API proxy. The error message is:

Error in get_proxy_port() :
no slot of name "proxy_port" for this object of class "RequestInfo"

Thanks, claudiu

Port number has changed

Hi @ahmedmohamedali, recently the API capabilities have been integrated into the Eikon Toolbar. The port number being used now is 9000 (instead of 36036). Could you please amend this in the source code? The package is still looking for 36036, so we get the following error:
Error in curl::curl_fetch_memory(url, handle = handle) : Couldn't connect to server
Thanks!

Error handle

I don't know if it's an issue or if I am missing something..
Python API can map error with the code below. How to do it with R?
df, err = ek.get_data(['GOOG.O', 'MSFT.O', 'FB.O', 'AMZN.O', 'TWTR.K'],
['TR.Revenue.date','TR.Revenue','TR.GrossProfit'],
{'Scale': 6, 'SDate': 0, 'EDate': -2, 'FRQ': 'FY', 'Curn': 'EUR'})

Argument of length 0 in get_timeseries

I have seeing this error a couple of times. Usually when Im trying to download a big index like New York Stock exchange. Usually it goes well, but sometimes it throws this error. This time at stock WYN.N.

get_timeseries("WYN.N",list("TIMESTAMP","HIGH","CLOSE","LOW","OPEN","VOLUME"),"2000-01-01T15:04:05",end_time,"daily")

[1] "WYN.N"
Error in 1:nrow(input_data_frame) : argument of length 0
Calls: get_timeseries -> get_formatted_data_frame

Clean/dirty price

Hi everyone,
is there a way to retrieve the clean and dirty price of a bond with the function get_data?
thanks

Problem by retrieving tick data

I have a problem by obtaining tick data from EIKON. I can get the data, when I use "minut" (or "daily" or "hour") , but not when I use "tick". I cannot figure out why.

Code:
eikonapir.set_app_id('YOUR_APP_ID')

%# This works fine (minut data)
df = get_timeseries('IBM','*',start_date = '2017-03-21T00:00:00Z',end_date='2017-03-21T16:00:00Z',interval='minute')

%# This does NOT work (tick data)
df = get_timeseries('IBM','*',start_date = '2017-03-21T00:00:00Z',end_date='2017-03-21T16:00:00Z',interval='tick')

Thanks in advance - and thank you very much for a very useable package!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.