If this indicator have helped you in your trading or you plan to use the code in one of your script,
please donate to following with a message to specify the money as Donation.
SKRILL : firstname.lastname@example.org
Donated money will go to Plan Canada (Save a Girl) and other charities around the world.
LETS PAY THE TAXES FROM OUR TRADING PROFITS TO NATURE, COMMUNITY AND GOOD CAUSES :)
Likes will help promote the script and is appreciable. (wink wink). :)
study(title="Kay_MA", shorttitle="Colored MA", overlay=true)
len = input(5, minval=1, title="MA")
src = input(hl2, title="Source")
cc = input(true, title="Change Color")
out = sma(src, len)
col = cc ? (change(out) > 0 ? green : red) : red
plot(out, title="MA", color=col, transp=0, linewidth=2)