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

Four Model for Amibroker (AFL)

Rating:
2 / 5 (Votes 3)
Tags:
trading system, amibroker

Four Model by Martin Zweig’s
See Zweig Book: Martin Zweig’s Winning with New IRAs, pages 117-128

Model was designed to be applied toa weekly chart of the Value Line Composite index ( VLCI)
Program uses a the weekly close of the VLCI to initate trades
Buy if the weekly close of the VLCI rises 4% or more from its lowest close ( since the last sell signal)
Sell if the weekly close of the VLCI falls 4% or more from its highest close ( since the last buy signal)

Similar Indicators / Formulas

All in One
Submitted by Nahid over 13 years ago
Kase Peak Osc. V2 batu
Submitted by batu1453 over 9 years ago
Kase CD V2batu
Submitted by batu1453 over 9 years ago
Ichimoku
Submitted by prashantrdx almost 10 years ago
Arvind' System
Submitted by akdabc almost 14 years ago
Miftha remix for dse
Submitted by coolpace over 13 years ago

Indicator / Formula

Copy & Paste Friendly
// Four Model by Martin Zweig's
// See Zweig Book: Martin Zweig's Winning with New IRAs, pages 117-128
// Translated to AFL by Xavier 
// Model was designed to be applied toa weekly chart of the Value Line Composite index ( VLCI)
// Program uses a the weekly close of the VLCI to initate trades
// Buy if the weekly close of the VLCI rises 4% or more from its lowest close ( since the last sell signal)
// Sell if the weekly close of the VLCI falls 4% or more from its highest close ( since the last buy signal)

perOffLo = Param("% off lowest close", 4,1, 10);
perOffHi = Param("% off highest close", 4,1, 10);
trend = 0;
HC = LC = C[0];

for( i =0; i < BarCount ; ++i)
{
	if ( trend == 0)
	{
		if (((C[i] - LC) / LC) >= (perOffLo / 100))
		{
			trend = 1;
		}
		if (((HC - C[i] ) / HC) >= (perOffLo / 100)) 
		{
			trend = -1;
		}
	}
	else if ( trend == 1 AND ((HC - C[i]) / HC) >= (perOffHi / 100)) 
	{
		Sell[i] = 1;
		trend = -1;
		LC = C[i];
	}
	else if ( trend == -1 AND ((C[i] - LC) / LC) >= (perOffLo / 100)) 
	{
		Buy[i] = 1;
		trend = 1;
		HC = C[i];
	}
	
	if ( C[i] < LC) LC = C[i];
	if ( C[i] > HC) HC = C[i];
}

2 comments

1. administrator

To All

This is trading system only. No chart. But it should be easy to add.

2. XavierJohn

I test with
Value Line Arithmetic Index,RTH (^VAY)
yahoo finance.

It can be used as a signal to buy other stocks.

Leave Comment

Please login here to leave a comment.

Back