Two dimensional array in EasyLanguage - EasyLanguage Programming | futures io social day trading
futures io futures trading


Two dimensional array in EasyLanguage
Updated: Views / Replies:4,669 / 6
Created: by Big Mike Attachments:3

Welcome to futures io.

(If you already have an account, login at the top of the page)

futures io is the largest futures trading community on the planet, with over 90,000 members. At futures io, our goal has always been and always will be to create a friendly, positive, forward-thinking community where members can openly share and discuss everything the world of trading has to offer. The community is one of the friendliest you will find on any subject, with members going out of their way to help others. Some of the primary differences between futures io and other trading sites revolve around the standards of our community. Those standards include a code of conduct for our members, as well as extremely high standards that govern which partners we do business with, and which products or services we recommend to our members.

At futures io, our focus is on quality education. No hype, gimmicks, or secret sauce. The truth is: trading is hard. To succeed, you need to surround yourself with the right support system, educational content, and trading mentors Ė all of which you can find on futures io, utilizing our social trading environment.

With futures io, you can find honest trading reviews on brokers, trading rooms, indicator packages, trading strategies, and much more. Our trading review process is highly moderated to ensure that only genuine users are allowed, so you donít need to worry about fake reviews.

We are fundamentally different than most other trading sites:
  • We are here to help. Just let us know what you need.
  • We work extremely hard to keep things positive in our community.
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts.
  • We firmly believe in and encourage sharing. The holy grail is within you, we can help you find it.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.

You'll need to register in order to view the content of the threads and start contributing to our community.  It's free and simple.

-- Big Mike, Site Administrator

Reply
 
Thread Tools Search this Thread
 

Two dimensional array in EasyLanguage

  #1 (permalink)
Site Administrator
Manta, Ecuador
 
Futures Experience: Advanced
Platform: My own custom solution
Favorite Futures: E-mini ES S&P 500
 
Big Mike's Avatar
 
Posts: 46,238 since Jun 2009
Thanks: 29,350 given, 83,215 received

Two dimensional array in EasyLanguage

I'm having a bit of difficulty getting a two dimensional array to work in EasyLanguage.

Let's say that I want to store the volume at each tick(price) in an array. It seemed logical to me this should be a two dimensional array, one for price, one for the volume count.

8:00:01 AM Price = 84.00, Volume = 12
8:00:02 AM Price = 84.01, Volume = 3
8:00:03 AM Price = 84.00, Volume = 5

I want to be able to have an array with two rows -- 84.00 and 84.01 -- the the column of row 0 would show a total volume of 17 (84.00 12+5) and row 1 would show 3 (84.01 3).

 
Code
                            
Array:IntraBarPersist VolAtPrice[1000,1000](0); 

First note to self -- no way to have a dynamic [] two dimensional array? I guess we'll have to assume 1000 tick increments between High and Low of day are sufficient.

Ok, so now I am thinking about how to insert a value into the two dimensional array, but how am I to track which array index holds the price (Close) I want to insert the volume for?

Some help?

Thx,
Mike

Due to time constraints, please do not PM me if your question can be resolved or answered on the forum.

Need help?
1) Stop changing things. No new indicators, charts, or methods. Be consistent with what is in front of you first.
2) Start a journal and post to it daily with the trades you made to show your strengths and weaknesses.
3) Set goals for yourself to reach daily. Make them about how you trade, not how much money you make.
4) Accept responsibility for your actions. Stop looking elsewhere to explain away poor performance.
5) Where to start as a trader? Watch this webinar and read this thread for hundreds of questions and answers.
6)
Help using the forum? Watch this video to learn general tips on using the site.

If you want
to support our community, become an Elite Member.

Reply With Quote
 
  #2 (permalink)
Quick Summary
Quick Summary Post

Quick Summary is created and edited by users like you... Add FAQ's, Links and other Relevant Information by clicking the edit button in the lower right hand corner of this message.

 
  #3 (permalink)
Elite Member
Madison, WI
 
Futures Experience: Advanced
Platform: Sierra Charts, ALT
Favorite Futures: ES
 
aslan's Avatar
 
Posts: 614 since Jan 2010
Thanks: 342 given, 1,077 received


You might want to look into ELCollections. It is the base of the ADE package for TS. It provides powerful collections that are implemented in C+ DLL, via EL routines. I have used ADE in MC, so the ELC should work fine.

Attached is the latest setup file from the TS wiki and the pdf.

The setup performs the following steps:
1. Places ELCollections.dll in the windows system directory
2. Places the ELCollections ELD files and documentation in a subdirectory of your program files directory
3. Creates program group TradeStation Forum/ELCollections and places shortcuts to the ELD and documentation
4. Automatically launches the TS import wizard for the ELD file

That last one does not make sense for MC.

I am sure there is some info on the MC forums as well.

Attached Thumbnails
Two dimensional array in EasyLanguage-elcollections.pdf  
Attached Files
Register to download File Type: zip ELC Setup.exe.zip (463.0 KB, 45 views)
Reply With Quote
The following user says Thank You to aslan for this post:
 
  #4 (permalink)
Elite Member
Canada
 
Futures Experience: Beginner
Platform: Multichart
 
Posts: 43 since Feb 2010
Thanks: 7 given, 27 received

Maybe this link will help you

https://www.tradestation.com/wiki/display/EasyLanguage/Understanding+Arrays

phil

Reply With Quote
 
  #5 (permalink)
Site Administrator
Manta, Ecuador
 
Futures Experience: Advanced
Platform: My own custom solution
Favorite Futures: E-mini ES S&P 500
 
Big Mike's Avatar
 
Posts: 46,238 since Jun 2009
Thanks: 29,350 given, 83,215 received



Can you cut/paste, I don't have a tradestation account.

Mike

Due to time constraints, please do not PM me if your question can be resolved or answered on the forum.

Need help?
1) Stop changing things. No new indicators, charts, or methods. Be consistent with what is in front of you first.
2) Start a journal and post to it daily with the trades you made to show your strengths and weaknesses.
3) Set goals for yourself to reach daily. Make them about how you trade, not how much money you make.
4) Accept responsibility for your actions. Stop looking elsewhere to explain away poor performance.
5) Where to start as a trader? Watch this webinar and read this thread for hundreds of questions and answers.
6)
Help using the forum? Watch this video to learn general tips on using the site.

If you want
to support our community, become an Elite Member.

Reply With Quote
 
  #6 (permalink)
Elite Member
Canada
 
Futures Experience: Beginner
Platform: Multichart
 
Posts: 43 since Feb 2010
Thanks: 7 given, 27 received

If you need related article to that one, just let me know.

phil

Attached Thumbnails
Two dimensional array in EasyLanguage-easylanguage-5680-20100505-14_34_00.pdf  

Last edited by philloo; May 5th, 2010 at 04:22 PM. Reason: change better format
Reply With Quote
 
  #7 (permalink)
Elite Member
Orlando, Florida
 
Futures Experience: Advanced
Platform: NinjaTrader, TradeStation, MultiCharts, eSignal, MetaTrader
Favorite Futures: ES
 
Posts: 56 since Aug 2010
Thanks: 3 given, 66 received

I realize this thread is a bit dated, but figured I'd throw in my $.02 for what it's worth.

It would be logical to store the information in a two-dimensional array, however in your code you are using the wrong dimensions (1000 X 1000). Since you are only storing price and volume, the dimensions should be (1000 X 2). Therefore you could easily accomplish the same thing with 2 identical single-dimensional arrays (Price[1000] and Volume[1000]).

Single-dimensional arrays can be dynamic. See the reserve word "array_setmaxindex".

To store the values, you could try something similar to the following...

 
Code
                            
Vars:
tick(minmove/pricescale);

Array:
IntraBarPersist VolAtPrice[1000,2](0);

// calculate number of ticks above below prior day close, which is center point (500 element) in array. 
value1=(Close-CloseD(1))/tick;

// store price
VolAtPrice[500+value11]=Close;

// increment volume
VolAtPrice[500+value12]=VolAtPrice[500+value12]+Volume
You will have to add in some code that eventually resets VolAtPrice[x,2] back to 0. I'm guessing you would do this on a new date.

Reply With Quote
The following user says Thank You to MooreTech for this post:

Reply



futures io > > > > > Two dimensional array in EasyLanguage

Thread Tools Search this Thread
Search this Thread:

Advanced Search



Upcoming Webinars and Events (4:30PM ET unless noted)

Linda Bradford Raschke: Reading The Tape

Elite only

Adam Grimes: TBA

Elite only

NinjaTrader: TBA

January

Ran Aroussi: TBA

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
Converting EasyLanguage to C# christof21 Platforms and Indicators 5 December 9th, 2013 08:31 PM
Easylanguage subroutines skan EasyLanguage Programming 7 August 18th, 2011 08:34 PM
EasyLanguage vs NinjaScript Traderji Platforms and Indicators 2 October 22nd, 2010 02:00 AM
Easylanguage vs. C++ Cogito ergo sum EasyLanguage Programming 10 August 2nd, 2010 03:12 PM


All times are GMT -4. The time now is 01:31 PM.

Copyright © 2017 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432, info@futures.io
All information is for educational use only and is not investment advice.
There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
no new posts
Page generated 2017-12-11 in 0.11 seconds with 20 queries on phoenix via your IP 54.145.16.43