Hausky

Ichimoku-Hausky Trading system

This is a indicator with some parts of the ichimoku and EMA. It's my first script so i have used other peoples script (Chris Moody and DavidR) as reference cause I really have no idea myself on how to script with pinescript.
Hope that is okay!

I use 20M timeframe but it should work with any timeframe! I have not tested this system much so I would really appreciate feedback and tips for better entries, settings etc..

Tenken-sen: green line
Kijun-sen: blue line
EMA: Purple

Rules:

Buy:
IF price crosses or bounce above Kijun-sen
THEN see if market has closed above EMA
IF Market has closed above EMA
THEN see if EMA is above Kijun-sen
IF EMA is above Kijun-sen
THEN buy and set trailing stop 5 pips below EMA

Sell:
IF price crosses or bounce below Kijun-sen
THEN see if market has closed below EMA
IF Market has closed below EMA
THEN see if EMA is below Kijun-sen
IF EMA is below Kijun-sen
THEN sell and set trailing stop 5 pips above EMA

オープンソーススクリプト

TradingViewの精神に則り、このスクリプトの作者は、トレーダーが理解し検証できるようにオープンソースで公開しています。作者に敬意を表します!無料で使用することができますが、このコードを投稿で再利用するには、ハウスルールに準拠する必要があります。 お気に入りに登録してチャート上でご利用頂けます。

免責事項

これらの情報および投稿は、TradingViewが提供または保証する金融、投資、取引、またはその他の種類のアドバイスや推奨を意図したものではなく、またそのようなものでもありません。詳しくは利用規約をご覧ください。

チャートでこのスクリプトを利用したいですか?
//Created By User Hausky

study(title="Hausky100", shorttitle="Hausky100", overlay=true)
turningPeriods = input(50, minval=1, title="Tenkan-Sen")
standardPeriods = input(100, minval=1, title="Kinjun-Sen")
sts = input(true, title="Show Tenkan-Sen (50 Period)?")
sks = input(true, title="Show Kinjun-Sen (100 Period)?")

//Definitions for Tenkan-Sen (50 Period), Kinjun-Sen (100 Period)
donchian(len) => avg(lowest(len), highest(len))
turning = donchian(turningPeriods)
standard = donchian(standardPeriods)


//Plot Kijun-sen and Tenkan-sen
plot(sts and turning ? turning : na, title = 'Tenkan-Sen (50 Period)', linewidth=2, color=green)
plot(sks and standard ? standard : na, title = 'Kinjun-Sen (100 Period)', linewidth=2, color=blue)

//Definitions for EMA
src = close
EMA  = input(45, minval=1, title="EMA")
fPivot = ((high + low + close)/3)
fEMA    = ema(fPivot, EMA)

//Plot EMA
plot(fEMA, color=fuchsia, title="EMA", linewidth=2)