You are on page 1of 5

STOCK 6 - Check ✔

Momentum[entry]:

Long signal = momentum line breaks through the zero line upside

Short signal = momentum line breaks through the zero line downside

Exit Short Trade If:

⮚ Candle is closed and close > EMA (based on close) [exit]

Exit Long Trade If:

⮚ Candle is closed and close < EMA (based on close) [exit]

Pyramiding Trades

Pyramiding trades is an input which has the set the amount of trades that can be open
simultaneously. Note that this means that if a maximum has already been met that no new trade can
be opened until a previous one has been closed due to either a stop loss hit or an exit indicator
signal.

Position size:

Risk per trade Equals position size times stop loss distance (input risk % per trade)

Stop-loss:

long_stop_loss = entry price – (ATR X ATR multiplier input)

short_stop_Loss = entry price + (ATR X ATR multiplier input)

Enter Long trade if:

⮚ Momentum Long Signal

(AND)

⮚ BBW > SMA (based on SMA)


(AND)

⮚ Supertrend == long conformation

AND

⮚ Candle is closed (open trade on next candle)


Enter Short trade if:

⮚ Momentum Short Signal

AND

⮚ BBW > SMA (based on SMA) [conformation]


AND

⮚ Supertrend == short conformation [conformation]

AND

⮚ Candle is closed (open trade on next candle)

Super Trend indicator [conformation]:

Super Trend Longs Signal = long_conf

Super Trend Short Signal = short_conf

Break Even and Stop Profit Function:

Variables and user input information:

stop_profit_levels_long = array

stop_profit_level_short = array

amount_of_sp_lvls = user input Integers

be_and_sp_multiplier = user input float


stop_loss_long = See Stop loss calculation documention

example code Python / Pinescript:

If use break even and stop profit function is True (AND) Long Entry:

⮚ Step 1: clear array “stop profit levels long”

⮚ Step 2: for i=0 to amount_of_sp_lvls:


sp_lvl_long = entry_price + ((ATR * be_and_sp_multiplier)*i)
array.append(stop_profit_levels_long, sp_lvl_long)

⮚ Step 3: for i=1 to amount_of_sp_lvls_long:


sp_lvl_long_i = array get(stop_profit_levels_long, i)
sp_lvl_long_im1 = array get(stop_profit_levels_long, i-1)
if close > sp_lvl_long_i (AND) sp_lvl_long_im1 > long_stop_loss:
long_stop_loss := sp_lvl_long_im1

description:

stop profit levels should be calculated automatically based on the value of the ATR indicator and the
be_and_sp_multiplier user input. The amount of stop profit levels to be calculated must be based on
a user input.

The sum for each level in the case of long trades looks like this:

entry price + ((ATR * be_and_sp_multiplier)* the stop profit level number)

the sum for each level in the case of short trades looks like this:

entry price - ((ATR * be_and_sp_multiplier)* the stop profit level number)

in the case of a long trade, the following counts:

when the market close above a stop profit level the stop loss must be moved to the previous stop
profit level.

in the case of a short trade the following counts:

if the close of the market closes below a stop profit level the stop loss must be moved to the
preceding stop profit level.
Name input Value Start Stop Step

Entry Indicator: INTEGER INTEGER INTEGER INTEGER


Momentum
Length

Confo BBW: SOURCE


Source

Confo BBW: INTEGER


Length

Confor BBW: FLOAT


multiplier

Confo BBW: SMA INTEGER


Length

Confo SOURCE
SuperTrend:
source

Confo INTEGER
SuperTrend: ATR
period

Confo INTEGER
SuperTrend: ATR
multiplier

Confo BOOLEAN
SuperTrend:
Change ATR
calculation
method?

Exit Indicator: INTEGER


EMA length

ATR Stop Loss FLOAT


Multiplier

Use Break–even BOOLEAN


and Stop Profit
levels?

ATR BE & SP FLOAT


Multiplier

Amount of Stop INTEGER


Profit levels

Position Risk % FLOAT

Pyramiding INTEGER
Trades

Take Long BOOLEAN


Trades?

Take Short BOOLEAN


Trades?

You might also like