MarcoValente

ema-sma

1638
oscillator from the difference between Ema and Sma, moving around 0 line, Quite reactive if use the cross of the 2 lines , more conservative if wait the lines cross the zero line. I add columns for the big change of volume with the cut off so it s show only big divergence with the avarage. colors show trends. I think usefull
סקריפט קוד פתוח

ברוח TradingView אמיתית, מחבר הסקריפט הזה פרסם אותו בקוד פתוח, כך שסוחרים יכולים להבין ולאמת אותו. כל הכבוד למחבר! אתה יכול להשתמש בו בחינם, אך שימוש חוזר בקוד זה בפרסום כפוף לכללי הבית. אתה יכול להכניס אותו למועדפים כדי להשתמש בו בגרף.

כתב ויתור

המידע והפרסומים אינם אמורים להיות, ואינם מהווים, עצות פיננסיות, השקעות, מסחר או סוגים אחרים של עצות או המלצות שסופקו או מאושרים על ידי TradingView. קרא עוד בתנאים וההגבלות.

רוצה להשתמש בסקריפ זה בגרף?
//
study(title="ema-sma", shorttitle="ema-sma + vol")
src =input(close,title="source"),length = input(9, minval=1,title="short ema"),lensma=input(17,title="long sma")
vol=volume
vm=100*((sma(vol,length)-(sma(vol,length)[4]))/(sma(vol,length)[4]))
vvm=100*(sma(((vm-vm[1])/vm[1]),3))
osc=sma((ema(src,length)-sma(src,lensma)),3)
sig=(osc+2*osc[1]+2*osc[2]+osc[3])/6
cc=osc>0 ? lime : osc<0 ? red: na
cut=abs(vvm/8)> abs(sma(vvm,5)) ?osc/0.7 : na
cv=cut>0 ? aqua : orange 
si=plot(sig,color=cc)
duml=plot((osc>sig?osc:sig), style=circles, linewidth=0, color=gray)
os=plot(osc,color=cc,linewidth=2, title="ROC")
fill(si,duml,color=green,transp=60)
fill(os,duml,color=red,transp=60)
hline(0, title="Zero Line",color=white)
plot(cut,color=cv,style=columns,linewidth=2,transp=60)