Jump to content

Welcome to the new Traders Laboratory! Please bear with us as we finish the migration over the next few days. If you find any issues, want to leave feedback, get in touch with us, or offer suggestions please post to the Support forum here.

  • Welcome Guests

    Welcome. You are currently viewing the forum as a guest which does not give you access to all the great features at Traders Laboratory such as interacting with members, access to all forums, downloading attachments, and eligibility to win free giveaways. Registration is fast, simple and absolutely free. Create a FREE Traders Laboratory account here.

bigboy

Easy ADE Problem

Recommended Posts

Hello,

 

I'm thinking this is an easy answer for someone more familiar with Elcollections and ADE than I am. Anyway, I have this written to a file by an external dll.

 

Date,Time,mdindex,mdbidvol,mdaskvol,mdopen,mdhigh,mdlow

02/04/2008,1744,499,1,0,13780.000000,13785.000000,13775.000000

02/04/2008,1744,500,0,2,13780.000000,13785.000000,13775.000000

02/04/2008,1744,501,25,0,13780.000000,13785.000000,13775.000000

02/04/2008,1745,499,1,1,13795.000000,13805.000000,13790.000000

02/04/2008,1745,500,34,11,13795.000000,13805.000000,13790.000000

02/04/2008,1745,501,11,167,13795.000000,13805.000000,13790.000000

02/04/2008,1745,502,0,3,13795.000000,13805.000000,13790.000000

02/04/2008,1746,497,41,0,13795.000000,13795.000000,13780.000000

02/04/2008,1746,498,20,107,13795.000000,13795.000000,13780.000000

02/04/2008,1746,499,23,18,13795.000000,13795.000000,13780.000000

02/04/2008,1746,500,68,0,13795.000000,13795.000000,13780.000000

 

I'm trying to make a map of a map I guess so that I can read in the values but there is not a one to one correspondence with the bar. Instead each bar has variable amount of data depending upon the number of price movemements in the bar. I need to somehow read this in from a file and store it in a map or list to operate on and print out. I need a map or list that is created from this that has variable number of members keyed by the minute bar id somehow.

 

Here's the contents of what I have in my ADC.GetMDELTA function

Inputs:

Sym(StringSimple),

Interval(NumericSimple),

BarID(NumericSimple),

vmdeltaindexlist(NumericRef),

vbidList(NumericRef),

vaskList(NumericRef),

vmdopenList(NumericRef),

vmdhighList(NumericRef),

vmdlowList(NumericRef);

 

Vars:

LastSym(""),

LastInterval(-1),

Index(0),

DataMap(0),

BarList(0),

mdeltaindexlist(0),

bidList(0),

askList(0),

mdopenList(0),

mdhighList(0),

mdlowList(0);

 

if Sym <> LastSym or Interval <> LastInterval then begin

LastSym = Sym;

LastInterval = Interval;

 

DataMap = ADE.GetRequiredMap("MDELTA", Sym, Interval);

BarList = MapSC.Get(DataMap, ":Bar");

 

mdeltaindexlist = MapSC.Get(DataMap, "mdindex");

bidList = MapSC.Get(DataMap, "mdbidvol");

askList = MapSC.Get(DataMap, "mdaskvol");

mdopenList = MapSC.Get(DataMap, "mdopen");

mdhighList = MapSC.Get(DataMap, "mdhigh");

mdlowList = MapSC.Get(DataMap, "mdlow");

 

 

 

end;

 

if ListN.IsSorted(BarList) = false then

Value1 = ADE.SortDataMap(DataMap);

 

if ListN.Lookup(BarList, BarID, Index) = false then

Index = Index - 1;

 

if Index <> 0 then begin

vmdeltaindexlist = ListN.Get(mdeltaindexlist, Index);

vbidList = ListN.Get(bidList, Index);

vaskList = ListN.Get(askList, Index);

vmdopenList = ListN.Get(mdopenList, Index);

vmdhighList = ListN.Get(mdhighList, Index);

vmdlowList = ListN.Get(mdlowList, Index);

end;

 

ADC.GetMDELTA = Index;

 

Since these do not match up with individual ticks either, the zerobar stuff doesn't work for this.

 

Any help appreciated.

Bigboy

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.