Stock Portfolio Organizer

The ultimate porfolio management solution.

Shares, Margin, CFD's, Futures and Forex
EOD and Realtime
Dividends and Trust Distributions
And Much More ....
For Portfolio Manager Click Here

WiseTrader Toolbox

#1 Selling Amibroker Plugin featuring:

Advanced Adaptive Indicators
Advanced Pattern Exploration
Neural Networks
And Much More ....
Find Out More Here

Exploration To Quickly Check For Top 5 Highest High and Lowest Low for Amibroker (AFL)

Rating:
5 / 5 (Votes 1)
Tags:
Highest, Lowest, amibroker, exploration

Easily check the percentage difference between top 5 highest high and lowest low compared to the current price.

Screenshots

Indicator / Formula

Copy & Paste Friendly
highestclose = Close[BarCount - 1];
highest1 = 0;
highest1p = 0;
highest2 = 0;
highest3 = 0;
highest4 = 0;
highest5 = 0;
curfinal = 0;
lowestclose = Close[BarCount - 1];
lowest1 = 0;
lowest2 = 0;
lowest3 = 0;
lowest4 = 0;
lowest5 = 0;

for( i = 0; i < BarCount ; i++ ) // CORRECT
{
    finalc = Close[i];

    checkchange = ( ( Close[i] - Close ) / Close ) * 100;

    if( highestclose < Close[i] )
    {
        highest5 = highest4;
        highest4 = highest3;
        highest3 = highest2;
        highest2 = highest1;
        highestclose = Close[i];
        highest1 = checkchange;
    }

    if( lowestclose > Close[i] )
    {
        lowest5 = lowest4;
        lowest4 = lowest3;
        lowest3 = lowest2;
        lowest2 = lowest1;
        lowestclose = Close[i];
        lowest1 = checkchange;
    }

    curfinal = checkchange;
}

highest1color = IIf( highest1 > 0, colorGreen, IIf( highest1 < 0, colorRed, colorDefault ) );
highest2color = IIf( highest2 > 0, colorGreen, IIf( highest2 < 0, colorRed, colorDefault ) );
highest3color = IIf( highest3 > 0, colorGreen, IIf( highest3 < 0, colorRed, colorDefault ) );
highest4color = IIf( highest4 > 0, colorGreen, IIf( highest4 < 0, colorRed, colorDefault ) );
highest5color = IIf( highest5 > 0, colorGreen, IIf( highest5 < 0, colorRed, colorDefault ) );
lowest1color = IIf( lowest1 > 0, colorGreen, IIf( lowest1 < 0, colorRed, colorDefault ) );
lowest2color = IIf( lowest2 > 0, colorGreen, IIf( lowest2 < 0, colorRed, colorDefault ) );
lowest3color = IIf( lowest3 > 0, colorGreen, IIf( lowest3 < 0, colorRed, colorDefault ) );
lowest4color = IIf( lowest4 > 0, colorGreen, IIf( lowest4 < 0, colorRed, colorDefault ) );
lowest5color = IIf( lowest5 > 0, colorGreen, IIf( lowest5 < 0, colorRed, colorDefault ) );

AddColumn( finalc, "final", 0 );
AddColumn( highest1, "highest1", 0, highest1color );
AddColumn( highest2, "highest2", 0, highest2color );
AddColumn( highest3, "highest3", 0, highest3color );
AddColumn( highest4, "highest4", 0, highest4color );
AddColumn( highest5, "highest5", 0, highest5color );
AddColumn( lowest1, "lowest1", 0, lowest1color );
AddColumn( lowest2, "lowest2", 0, lowest2color );
AddColumn( lowest3, "lowest3", 0, lowest3color );
AddColumn( lowest4, "lowest4", 0, lowest4color );
AddColumn( lowest5, "lowest5", 0, lowest5color );

Filter = 1;

3 comments

1. shon

Not working brother, all collum are showing zero price, Need your help. Thanks @shoncornar@gmail.com

2. mumbaiboy

Showing All Zero Values :(

3. administrator

I am hoping the author will drop in and explain how it should be run.

Leave Comment

Please login here to leave a comment.

Back