question

Upvotes
Accepted
4 2 1 6

Filtering data at source

Hi,
I am querying data from TRTH Intraday summary via python. Is it possible to do any of the below:

1. Only call certain fields: For instance, I do not need to to get data on default fields such as Domain, Underlying RIC Alias, Type.

2. Is there a way to only get non empty data. For instance, if Price ("Last") and Volume are empty, I do not want to download that row.

tick-history-rest-apifieldsfilter
icon clock
10 |1500

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

@lhabinsky

Thank you for your participation in the forum. Is the reply below satisfactory in resolving your query? If yes please click the 'Accept' text next to the reply. This will guide all community members who have a similar question. Otherwise please post again offering further insight into your question.
Thanks,
-AHS

@lhabinsky

Please be informed that a reply has been verified as correct in answering the question, and has been marked as such.
Thanks,
-AHS

1 Answer

· Write an Answer
Upvotes
Accepted
13.7k 26 8 12

@lhabinsky,

  1. You might have seen the TRTH REST Tutorial 6 on TRTH Intraday summaries. Among other things it explains how to select returned fields. That said, some default fields will be delivered in any case (Alias Underlying RIC,Domain,Date-Time,GMT Offset,Type), they cannot be disabled.
  2. It is not possible to only get non empty data. You can set TimebarPersistence to false to remove empty bars, but there is no way to suppress a row based on a specific set of fields being empty.

icon clock
10 |1500

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

Thanks for the response. Could you provide more detail on TimebarPersistence? If data is missing for a bar, does it forward fill/back fill or does it drop the observation?

@lhabinsky,

TimebarPersistence influences what is delivered when there is no data in an interval:

  • False: a bar is not generated, the row is not returned.
  • True: a bar is generated, using the values from the previous interval.

See attached example, from that same tutorial 6, with results for both settings of TimeBarPersistence.

tbpersist.txt

tbpersist.txt (7.7 KiB)

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

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