• Ask a question
  • Spaces
    • TT® Platform
    • Autospreader®
    • Autotrader™
    • Charting & Analytics
    • Options
    • ADL®
      • ADL Samples
    • RTD
    • APIs
      • TT .NET SDK
      • TT API & XT API
      • TT REST API
    • Cryptocurrencies
    • Topics
    • Questions
    • Articles
    • Ideas
    • Badges
  • Sign in
  • Home /
  • ADL® /
avatar image
0
Question by amarkantiitkgp · Jan 04 at 05:17 AM · ADL®

Use of Historical data from Analytics block

hi,
i am trying to extract and use historical data stored in Analytics block to create a technical indicator using Value Extractor block. but I am not able to make it work. Can someone please help me out? Thanks in Advance!!

Comment
Add comment
10 |1800 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by russelltromans-1 · Jan 06 at 11:22 AM

Below is a basic example of how you can access the data within the Analytics Block for use in the calculation of your own indicators.

In the below example I have created a 20 period moving average based off the close. I use the Index output of the Loop block to cycle through the 20 most recent bars of the Analytics Block. Each time the index value changes the data in the lower section of the Analytics block marked with an 'i' is updated. I then use a Value Accumulator marked 'Value Collection' to accumulate the value of 'close_i'.

Once the loop sequence is complete I use the Value Extractor labelled 'Moving Average' to divide the 'Value Collection' result by 20 to give me my average value. I then reset the Accumulator Block so that it has a clean data set ready for the next bar complete.


Depending on the indicator you are looking to create the complexity of your calculations can vary greatly although the fundamental concept of accessing the data from the Analytics block remains the same.


tta1.png (108.1 kB)
Comment
Add comment · Share
10 |1800 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Community

Ask questions and share ideas about the TT® and X_TRADER® platforms.

First time here? See our Getting Started Guide and FAQs.

Follow

Follow this Question

Answers Answers and Comments

40 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

GeneratorBlock inside virtualised block 1 Answer

Search String on ADL Instrument - Option Underlying and Strike 1 Answer

Value Bucket Update Only on Matching Hole Value 2 Answers

Same Algo/Buy or Sell Entry as Alternative to Flip For Sell Logic 2 Answers

range value store,range 1 Answer

Trading Technologies Home - Legal - Privacy - Contact

© 2017 Trading Technologies International, Inc. All rights reserved.

Powered by AnswerHub

  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Create an article
  • Post an idea
  • Spaces
  • TT® Platform
  • Autospreader®
  • Autotrader™
  • Charting & Analytics
  • Options
  • ADL®
    • ADL Samples
  • RTD
  • APIs
    • TT .NET SDK
    • TT API & XT API
    • TT REST API
  • Cryptocurrencies
  • Explore
  • Topics
  • Questions
  • Articles
  • Ideas
  • Badges