N

nTrend Filter v0.1

N  
Determines long term trend bias on the conditions below:
If price is above the 200sma and 50sma = Green Candles = Bullish
If price is below the 200sma and 50sma = Red Candles = Bearish
Remove from Favorite Scripts Add to Favorite Scripts
// nTrend v0.1
// Made by Nicholas Luca Ricciardi - nricciardi.co.uk
// Determines long term trend bias
// If price is above the 200sma and 50sma = Green Candles = Bullish
// If price is below the 200sma and 50sma = Red Candles = Bearish

study(title = "nTrend v0.1", shorttitle="nTrend v1",overlay=true)

sma1 = (50)
usedEma = sma(close, sma1)

emaUpColor() => hlc3 >= usedEma
emaDownColor() => hlc3  < usedEma

col = hlc3  >= usedEma ? lime : hlc3  < usedEma ? red : black

barcolor(emaUpColor() ? lime: emaDownColor() ? red : na)
plot(usedEma ? usedEma : na, title="EMA", style= (line) , linewidth=(2), color=white)

BiasSMA = (200)
usedSMA = sma(close, BiasSMA)

plot(usedSMA ? usedSMA : na, title="EMA", style= (line) , linewidth=(3), color=black)
simple but useful, thanks!
Reply
United States
United Kingdom
India
Deutschland
France
España
Italia
Polska
Türkiye
Россия
Brasil
Indonesia
Malaysia
ประเทศไทย
Việt Nam
日本
한국
简体
繁體
Home Stock Screener Forex Signal Finder Cryptocurrency Signal Finder Economic Calendar How It Works Chart Features House Rules Moderators Website & Broker Solutions Widgets Stock Charting Library Feature Request Blog & News FAQ Help & Wiki Twitter
Profile Profile Settings Account and Billing My Support Tickets Contact Support Ideas Published Followers Following Private Messages Chat Sign Out