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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
37 3 3 10

issues with the values returned by the function get_data()

I use the function get_data() in the following way:

index_id = ['US0378331005', 'CH0244767585', 'IT0003796171', 'JP3246400000', 'CH0038863350', 'HK0267001375', 'AU000000ORG5', 'BE0974258874', 'PTEDP0AM0009']
data, err   = ek.get_data(index_id,['TR.isPrimaryInstrument']) 

and the return is a serie of string "True".

Now if I use this function with another set of index_id, it will return 1 and 0. Why is that behavior and how to avoid it?


eikoneikon-data-apiworkspaceworkspace-data-apirefinitiv-dataplatform-eikonpython
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
Accepted
18k 21 12 20

Hi @Tulkkas

Please share the other instruments which you got 0 or 1.

I would like to try to retrieve the information on API and on Excel.


For the provided instrument codes in your question, I got True.

Thanks.


ahs.png (27.8 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
37 3 3 10

it was a very large universe and I don't know which exact ISIN was trigerring the 1/0 instead of true/false. I can't even copy/past the full list here as there are more than 4000 ISIN.

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