# CM_Price-Action-Bars

587 3
study("CM_Price-Action-Bars", overlay=true)

pctP = input(66, minval=1, maxval=99, title="Percentage Input For PBars, What % The Wick Of Candle Has To Be")
pblb = input(6, minval=1, maxval=100, title="PBars Look Back Period To Define The Trend of Highs and Lows")
pctS = input(5, minval=1, maxval=99, title="Percentage Input For Shaved Bars, Percent of Range it Has To Close On The Lows or Highs")
spb = input(false, title="Show Pin Bars?")
ssb             = input(false, title="Show Shaved Bars?")
sib = input(false, title="Show Inside Bars?")
sob = input(false, title="Show Outside Bars?")
sgb = input(false, title="Check Box To Turn Bars Gray?")

//PBar Percentages
pctCp = pctP * .01
pctCPO = 1 - pctCp

//Shaved Bars Percentages
pctCs = pctS * .01
pctSPO = pctCs

range = high - low

///PinBars
pBarUp() => spb and open > high - (range * pctCPO) and close > high - (range * pctCPO) and low <= lowest(pblb) ? 1 : 0
pBarDn() => spb and open < high - (range * pctCp) and close < high-(range * pctCp) and high >= highest(pblb) ? 1 : 0

//Shaved Bars
sBarUp() => ssb             and (close >= (high - (range * pctCs)))
sBarDown() => ssb             and close <= (low + (range * pctCs))

//Inside Bars
insideBar() => sib and high <= high and low >= low ? 1 : 0
outsideBar() => sob and (high > high and low < low) ? 1 : 0

//PinBars
barcolor(pBarUp() ? lime : na)
barcolor(pBarDn() ? red : na)
//Shaved Bars
barcolor(sBarDown() ? fuchsia : na)
barcolor(sBarUp() ? aqua : na)
//Inside and Outside Bars
barcolor(insideBar() ? yellow : na )
barcolor(outsideBar() ? orange : na )

barcolor(sgb and close ? gray : na)
Hello,

First...I'm honored your using my codes.

There is a issue though. You copied my code 100% and made no improvements or additions to it. I posted the code to be used my anyone...but you only repost code if you've ADDED to it.

Next...the only part of the code you didn't repost is the 2 Comment lines at the top. This is a issue b/c I gave credit to Chris Capre who gave me permission to post this code for the benefit of the TradingView community. It's his code not mine....he deserves credit.

Then...you have the PinBars turned on which highlight the bars red or green...But those are the colors of the default candles on your chart so it's nearly impossible to see any of the conditions being TRUE.

No additional comments or Analysis are included here so what is the value to the community?

You didn't modify the name of the code...so when people search for the name 2 indicators show up...The issue here is there are people who search for this code from several different educators...if they click on yours there is no explanation of how the code works...

The way you included the code in the description...which is the same as the actual code that automatically posts below...It's pretty obvious you posted this by accident.

Please explain the situation to support and see if they can take this version of the indicator down...There is No Value created and it's cluttering up the Public Library.

Again...No hard feelings..I think you just posted this by accident.
ChrisMoody
Here is the original post:

did u copy from Chris Moody..
EN English
EN English (UK)
EN English (IN)
DE Deutsch
FR Français
ES Español
IT Italiano
PL Polski
SV Svenska
TR Türkçe
RU Русский
PT Português
ID Bahasa Indonesia
MS Bahasa Melayu
TH ภาษาไทย
VI Tiếng Việt
JA 日本語
KO 한국어
ZH 简体中文
ZH 繁體中文
AR العربية
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