TradingView
HPotter
6 אוק׳ 2022 09:15

Elder Ray (Bull Power) TP and SL 

Bitcoin / TetherUSBinance

תיאור

Developed by Dr Alexander Elder, the Elder-ray indicator measures buying
and selling pressure in the market. The Elder-ray is often used as part
of the Triple Screen trading system but may also be used on its own.
Dr Elder uses a 13-day exponential moving average (EMA) to indicate the
market consensus of value. Bull Power measures the ability of buyers to
drive prices above the consensus of value. Bear Power reflects the ability
of sellers to drive prices below the average consensus of value.
Bull Power is calculated by subtracting the 13-day EMA from the day's High.
Bear power subtracts the 13-day EMA from the day's Low.
WARNING:
- For purpose educate only
- This script to change bars colors.
תגובות
variousSwift55903
ONCE HIfractal = high
ONCE LOfractal = low
Periods = max(1,min(999,Periods))
//
HIfractal = high[1] > high[2] AND high[1] > high
LOfractal = low[1] < low[2] AND low[1] < low
//
IF HIfractal THEN
HIfractal = high[1]
ELSE
HIfractal = HIfractal[1]
ENDIF
IF LOfractal THEN
LOfractal = low[1]
ELSE
LOfractal = LOfractal[1]
ENDIF
HIvalue = highest[Periods](HIfractal)
LOvalue = lowest[Periods](LOfractal)
RETURN HIvalue AS "Upper Fcb BAND",LOvalue AS "Lower Fcb BAND"

Hi can you help me create fractal chaos bands .. as above formula.. I am using your other script.. but there are some variations.. could you please help me with it
UdavPitonov
Looks like a copy/paste error, here it should probably say "Market Short" instead of "Market Long" : if (possig == -1) and strategy.position_size == 0
strategy.entry('Short', strategy.short, comment='Market Long')
stylesofy
I am a beginner who is learning Pine language, and I noticed that the ":=" operator appeared in your indicator. I couldn't find its instruction introduction in the Pine documentation. Can you explain briefly what this operator means? thanks .
HPotter
@stylesofy, This operator put value to the exist variable. If you write a = 1, it is creating new variable a. But if you write a := 1 it will rewrite value in the variable "a" initialized before. For more understanding please read this doc:
tradingview.com/pine-script-reference/v5/
Cervinmole
Good morning, sir
Can this script be used for forex ?
Is it possible to transform your script so that you can reason in ticks and not in profit percentages or loss percentages?
Thank you very much for all your work and the sharing you do.
HPotter
@Cervinmole, Yes it can be used on the FOREX. Tick is not universal points for TP and SL
Cervinmole
@HPotter, Thank you sir
Cervinmole
@HPotter, In fact, I meant "pip" instead of "tick". In forex trading, SL and TP are expressed in pips.
עוד