PROTECTED SOURCE SCRIPT
Cruce 9-21

//version=5
indicator("Cruce 9-21", overlay=true)
// ----------------------------
// Inputs básicos
// ----------------------------
showShapes = input.bool(true, "Mostrar flechas")
bbLen = input.int(20, "BB Length")
bbMult = input.float(2.0, "BB Mult", step=0.1)
// ----------------------------
// Cálculos
// ----------------------------
ema9 = ta.ema(close, 9)
ema21 = ta.ema(close, 21)
// Bollinger Bands
basis = ta.sma(close, bbLen)
dev = bbMult * ta.stdev(close, bbLen)
bbUpper = basis + dev
bbLower = basis - dev
// ----------------------------
// Señales SIMPLE BASE (solo EMAs + BB)
// ----------------------------
longCond = ta.crossover(ema9, ema21) and close > basis
shortCond = ta.crossunder(ema9, ema21) and close < basis
// Flechas
plotshape(showShapes and longCond, title="Long", style=shape.triangleup, location=location.belowbar, text="CALL", size=size.normal)
plotshape(showShapes and shortCond, title="Short", style=shape.triangledown, location=location.abovebar, text="PUT", size=size.normal)
indicator("Cruce 9-21", overlay=true)
// ----------------------------
// Inputs básicos
// ----------------------------
showShapes = input.bool(true, "Mostrar flechas")
bbLen = input.int(20, "BB Length")
bbMult = input.float(2.0, "BB Mult", step=0.1)
// ----------------------------
// Cálculos
// ----------------------------
ema9 = ta.ema(close, 9)
ema21 = ta.ema(close, 21)
// Bollinger Bands
basis = ta.sma(close, bbLen)
dev = bbMult * ta.stdev(close, bbLen)
bbUpper = basis + dev
bbLower = basis - dev
// ----------------------------
// Señales SIMPLE BASE (solo EMAs + BB)
// ----------------------------
longCond = ta.crossover(ema9, ema21) and close > basis
shortCond = ta.crossunder(ema9, ema21) and close < basis
// Flechas
plotshape(showShapes and longCond, title="Long", style=shape.triangleup, location=location.belowbar, text="CALL", size=size.normal)
plotshape(showShapes and shortCond, title="Short", style=shape.triangledown, location=location.abovebar, text="PUT", size=size.normal)
סקריפט מוגן
סקריפט זה פורסם כמקור סגור. עם זאת, תוכל להשתמש בו בחופשיות וללא כל מגבלות – למד עוד כאן
כתב ויתור
המידע והפרסומים אינם מיועדים להיות, ואינם מהווים, ייעוץ או המלצה פיננסית, השקעתית, מסחרית או מכל סוג אחר המסופקת או מאושרת על ידי TradingView. קרא עוד ב־תנאי השימוש.
סקריפט מוגן
סקריפט זה פורסם כמקור סגור. עם זאת, תוכל להשתמש בו בחופשיות וללא כל מגבלות – למד עוד כאן
כתב ויתור
המידע והפרסומים אינם מיועדים להיות, ואינם מהווים, ייעוץ או המלצה פיננסית, השקעתית, מסחרית או מכל סוג אחר המסופקת או מאושרת על ידי TradingView. קרא עוד ב־תנאי השימוש.