Simple Coding Help - No Promise.

onequorauser

Well-Known Member
Joined
Aug 14, 2017
Messages
770
Likes
1,800
Does exploration in Amibroker need any extra coding apart from the usual filter statements when using RT feeds like truedata?

I am using truedata but the exploration results only give me results arrived at 9.15 and not after that.

statements that I am writing are pretty straight forward e.g. filter = ema(close,21)>ma(close,8)
 

pannet1

Well-Known Member
Joined
Aug 3, 2011
Messages
2,094
Likes
3,168
Location
a secret location on earth with internet
Does exploration in Amibroker need any extra coding apart from the usual filter statements when using RT feeds like truedata?

I am using truedata but the exploration results only give me results arrived at 9.15 and not after that.

statements that I am writing are pretty straight forward e.g. filter = ema(close,21)>ma(close,8)
you could get inspiration from this
 

VJAY

Well-Known Member
Joined
Jun 16, 2008
Messages
8,337
Likes
16,566
Dear happy bro/other friends,
I want code for exploration in ami...I want to scan scrips which is closed above and near 200 EMA (means near 1% )...I tryed editing some similar codes but not got the result ...Please help....
 
Joined
May 11, 2016
Messages
9
Likes
6
Dear happy bro/other friends,
I want code for exploration in ami...I want to scan scrips which is closed above and near 200 EMA (means near 1% )...I tryed editing some similar codes but not got the result ...Please help....
http://traders.com/documentation/feedbk_docs/2009/12/TradersTips.html#TT19

Code:
// DIX-scan.afl - Disparity Index Scan in Amibroker 4.9
// Scan to list DIX(200), DIX(50) and DIX(20)
// ‘use filter’ = Nasdaq 100 stock universe
// ‘range’ = n last days with n=1
// Copyright 2009 Dan Valcu
Buy=1;
Filter = 1; /* all symbols and quotes accepted */
// Compute DIX(200)
nper1 = 200;
dix200=100*(C-EMA(C,nper1))/C;

// Compute DIX(50)
nper2 = 50;
dix50=100*(C-EMA(C,nper2))/C;

// Compute DIX(20)
nper3 = 20;
dix20=100*(C-EMA(C,nper3))/C;

Col2 = dix200;
Col3 = dix50;
Col4 = dix20;

SetOption(“NoDefaultColumns”, True );
AddTextColumn(Name(), “Ticker”, 5 , colorDefault, colorDefault);
AddColumn(Close,”Close”,1.2);
AddColumn(Col2,”DIX(200)”,1.2);
AddColumn(Col3,”DIX(50)”,1.2);
AddColumn(Col4,”DIX(20)”,1.2);
AddTextColumn(Name(), “Ticker”, 5 , colorDefault, colorDefault);
 

VJAY

Well-Known Member
Joined
Jun 16, 2008
Messages
8,337
Likes
16,566
http://traders.com/documentation/feedbk_docs/2009/12/TradersTips.html#TT19

Code:
// DIX-scan.afl - Disparity Index Scan in Amibroker 4.9
// Scan to list DIX(200), DIX(50) and DIX(20)
// ‘use filter’ = Nasdaq 100 stock universe
// ‘range’ = n last days with n=1
// Copyright 2009 Dan Valcu
Buy=1;
Filter = 1; /* all symbols and quotes accepted */
// Compute DIX(200)
nper1 = 200;
dix200=100*(C-EMA(C,nper1))/C;

// Compute DIX(50)
nper2 = 50;
dix50=100*(C-EMA(C,nper2))/C;

// Compute DIX(20)
nper3 = 20;
dix20=100*(C-EMA(C,nper3))/C;

Col2 = dix200;
Col3 = dix50;
Col4 = dix20;

SetOption(“NoDefaultColumns”, True );
AddTextColumn(Name(), “Ticker”, 5 , colorDefault, colorDefault);
AddColumn(Close,”Close”,1.2);
AddColumn(Col2,”DIX(200)”,1.2);
AddColumn(Col3,”DIX(50)”,1.2);
AddColumn(Col4,”DIX(20)”,1.2);
AddTextColumn(Name(), “Ticker”, 5 , colorDefault, colorDefault);
Thanks brother...will check it after market..:up:
 
Joined
Apr 11, 2018
Messages
5
Likes
0
Want help to correct the code- want to execute buy sell orders at time 0959
Below is the code
Buy=Ref(MACDpt,-1)>Ref(Close,-1) AND (TimeNum()>095800 AND TimeNum()<100000);
Short=Ref(MACDpt,-1)<Ref(Close,-1) AND (TimeNum()>095800 AND TimeNum()<100000);

Short signals are generated at 0959 but buy signals are not generated at time 0959.
 

nitingosavi

Well-Known Member
Joined
Jun 1, 2015
Messages
3,575
Likes
10,697
can some one plz code a display box ?

I need a display box on amibroker price chart which will show me different indicators value.
1. I should be able to add remove it whenever needed.
2. size color should be adjustable.
3. the indicators values / i should be able to add, remove/ select indicators may be 4-5.
4. its location on chart window should be adjustable.

i know basic afl. but unable to create display box.

can some one help me out ? thanks in advance.
 

Similar threads

Broker Special Offers