PROTECTED SOURCE SCRIPT

APIBridge Heikin Ashi Strategy on normal candles

Güncellendi
Strategy Premise

Heikin–Ashi, also sometimes spelled Heiken–Ashi, means “average bar” in Japanese. The Heikin–Ashi technique can be used in conjunction with candlestick charts when trading securities to spot market trends and predict future prices. It’s useful for making candlestick charts more readable and trends easier to analyze

Heikin Ashi is better for price action however we can get optimum results by using some filters like ema, rsi, volume, etc. Further, we will demonstrate the steps to automate the simple Heikin-Ashi strategy.

We can generated heikinashi values with a mathematical formula considering some of the previous candles values. There are two primary trade signals we can identify through the Heiken Ashi candlestick:

Bullish candlesticks have no wicks or very small wicks. They indicate a strong uptrend and excellent buying opportunities.
Small candlesticks can be characterize by a small body, big upper, and lower wicks. They signal a potential reversal.

Heikin ashi is better for price action however we can get optimum results by using some filters like ema, rsi, volume,etc. Further we will demonstrate the steps to automate simple heikin-ashi strategy.

Limitations on Heikin Ashi traditional charts:

Trading view free/pro users cant access HA charts for intraday
It shows wrong back testing results. When any strategy is applied on Heikin ashi it would show best profit curve but that’s unreal because heikin ashi has so much of variation from real market price
It actually has chance to mislead people that heikin ashi is best always
Therefore we are going to setup an alternative heikin ashi strategy which can be applied on normal candlestick charts.

Advantages of Heikin Ashi strategy with normal candles over traditional:
The price is related to real markets and logic is related to renko block building this strategy will reduce slippages when applied on real markets
Trading view free users/pro users who cannot access renko charts can use this to apply renko on normal charts
Strategy Logic

Long Entry : when there is a cross over with Heikin Ashi candle and Ema +2 consecutive Heikin Ashi bullish candles Send LE

Long Exit: Either when SL or Target is hit. If SL/TGT is not hit or trend is reversed Send LX and SE

Short Entry: When there is cross under of Heikin Ashi value and Ema + 2 consecutive bearish candles Send SE

Short Exit: Either when SL or Target is hit. If SL/TGT is not hit or trend is reversed Send SX and LE


Heikin-Ashi Parameters on TradingView

1.Ma Type: Choose the Moving Average type you want to use in script , default is Exponential Moving Average(EMA).

2.Ma-Length: Define the length of the moving average , defaut is 6

3.Backtesting : Use this to backtest the strategy between Starting and Ending Date and time , it can also be used to set trades in future time

4.Alert_Message : Need to copy while creating alert into Message Box

5.Trade Setup : Intraday / Positional (Selecct accordingly)

6.Start Time Stop Time (Session 1) : Intraday / Positional start time and end time of trade for session 1

7.End Session 1 : Define time to exit any existing position taken in session 1 so that exchange charges will not apply

8.Use Second Session : Check this to use second intraday session

9.Start Time Stop Time (Session 2) : Intraday / Positional start time and end time of trade for session 2

10.End Session 1 : Define time to exit any existing position taken in session 2 so that exchange charges will not apply

11.Use Target : check if you want to set required target if not cheque will not applicable

12.Use StopLoss : Cheque if you want to set stop loss if not cheque will not applicable

13.Trailling Stoploss : Cheque if you want to set trailing stop loss if not cheque will not applicable

14.Point Or Percentage For TG SL : Use Points or Percentage as per your choice

15.Target : Set as per the selection of (Point Or Percentage For TG SL)

16.Stop Loss : Set as per the selection of (Point Or Percentage For TG SL)

17.TSL_Type : Select as per your logic in %/ATR/Points

18.TSL_Input : Set in case you select %/Points in TSL_Type

19.ATR Length : Set as per your logic if you select ATR in the field of TSL_Type

20.ATR_Mult : Set as per your logic if you select ATR in the field of TSL_Type

21.Segment : Select segment of your logic EQ/FUTIDX/FUTSTK/OPTIDX/OPTSTK/FUTCUR/FUTCUM (Used in case of option / Futures )

22.Select Expiry Date : Select the expiry date of your trade as per the segment you selected (Used in case of option / Futures )

23.Select Expiry Month : Select the expiry Month of your trade as per the segment you selected (Used in case of option / Futures )

24.Year : Select the expiry Year of your trade as per the segment you selected (Used in case of option / Futures )

25.Quantity : Enter the quantity in which you want to trade (Used in case of option / Futures )

26.Product Type : Select MIS/Normal/ CNC as per your logic (Used in case of option / Futures )

27.Order Type : Select Market/Limit as per your logic (Used in case of option / Futures )

28.Strategy Tag : Enter the value in case you are using webhook / advance template in APIBridgeTM

29.Lotsize : Enter the lotsize as per your lotic and quentity selection (Used in case of option / Futures )

30.STEP (OTM/ATM/ ITM ) : Select OTM(+1)/ATM(0)/ ITM (-1) as per your logic works in case of options only

31.DIFFERENCE_BETWEEN 2 STRIKE : Select difference of 2 strikes you have used in APIBridge symbol setting list, like for Nifty 50 BankNifty 100

32.APIB Port : Set as per provided to you by Algoji in case of webhook / advance templet

The Segment full form is given below
EQ Equity
FUTIDX Future Index
FUTSTK Future Stock
OPTIDX Index Option
OPTSTK Stock Option
FUTCUR Futcur Currency
FUTCUM Future Commodity

Sürüm Notları
Updated Version with added MA type - DEMA (Double Exponential Moving Average) , HMA (Hull Moving Average)
algojialgotradingapibridgeCandlestick analysisheikinashiMoving AveragesTrend Analysis

Korumalı komut dosyası

Bu komut dosyası kapalı kaynak olarak yayınlanmıştır ve özgürce kullanabilirsiniz. Bir grafikte kullanmak için favorilerinize ekleyebilirsiniz. Kaynak kodunu görüntüleyemez veya değiştiremezsiniz.

Bu komut dosyasını bir grafikte kullanmak ister misiniz?


Regards,
Algoji Enterprises Private Limited
APIBridge™
Aynı zamanda::

Feragatname