Episodic Pivots For ThinkOrSwim

Tootall

New member
VIP
Plus
The Author States:
Episodic pivot screen 1 inspired by stockbee
Rule 1
1. Current price / yesterday > 1.04
2. current volume > sma50.1 volume * 3. since tradingview doesnt allow to use 50.1 in sma so i am using sma 50
3. Current volume >= 300000
HQiUwDf.png



Hello, i need help with the conversion of the trading view episodic pivot Indicator to a ToS Indicator or chart study

Here's the url link to trading view:
https://www.tradingview.com/v/PZghP0Uq/
 
Last edited by a moderator:
This should work, I'm plotting an arrow under the EP candle instead of a lower indicator. Added user inputs for average type/length and volume threshold.

I'm not able to test on Adaro energy but appears to be working on META which had an EP on Friday.

Code:
#https://www.tradingview.com/v/PZghP0Uq/
#Plots an arrow on EP instead of a lower indicator
#converted by Babel 02/24

#Userin
input AvgType = AverageType.SIMPLE;
input AvgLength = 50;
input volSize = 300000;

#Volume Moving average
def sma50vol = MovingAverage(AvgType, volume, AvgLength);

#Conditions
def cond1 = close / close[1] > 1.04;
def cond2 = volume > 3 * sma50vol;
def cond3 = volume > volSize;

#Plot arrow on EP
plot EP = cond1 and cond2 and cond3;
EP.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_UP);
 
This should work, I'm plotting an arrow under the EP candle instead of a lower indicator. Added user inputs for average type/length and volume threshold.

I'm not able to test on Adaro energy but appears to be working on META which had an EP on Friday.

Code:
#https://www.tradingview.com/v/PZghP0Uq/
#Plots an arrow on EP instead of a lower indicator
#converted by Babel 02/24

#Userin
input AvgType = AverageType.SIMPLE;
input AvgLength = 50;
input volSize = 300000;

#Volume Moving average
def sma50vol = MovingAverage(AvgType, volume, AvgLength);

#Conditions
def cond1 = close / close[1] > 1.04;
def cond2 = volume > 3 * sma50vol;
def cond3 = volume > volSize;

#Plot arrow on EP
plot EP = cond1 and cond2 and cond3;
EP.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_UP);
Thank you very much!
 
Last edited by a moderator:

Join useThinkScript to post your question to a community of 21,000+ developers and traders.

Similar threads

Not the exact question you're looking for?

Start a new thread and receive assistance from our community.

87k+ Posts
486 Online
Create Post

Similar threads

Similar threads

The Market Trading Game Changer

Join 2,500+ subscribers inside the useThinkScript VIP Membership Club
  • Exclusive indicators
  • Proven strategies & setups
  • Private Discord community
  • ‘Buy The Dip’ signal alerts
  • Exclusive members-only content
  • Add-ons and resources
  • 1 full year of unlimited support

Frequently Asked Questions

What is useThinkScript?

useThinkScript is the #1 community of stock market investors using indicators and other tools to power their trading strategies. Traders of all skill levels use our forums to learn about scripting and indicators, help each other, and discover new ways to gain an edge in the markets.

How do I get started?

We get it. Our forum can be intimidating, if not overwhelming. With thousands of topics, tens of thousands of posts, our community has created an incredibly deep knowledge base for stock traders. No one can ever exhaust every resource provided on our site.

If you are new, or just looking for guidance, here are some helpful links to get you started.

What are the benefits of VIP Membership?
VIP members get exclusive access to these proven and tested premium indicators: Buy the Dip, Advanced Market Moves 2.0, Take Profit, and Volatility Trading Range. In addition, VIP members get access to over 50 VIP-only custom indicators, add-ons, and strategies, private VIP-only forums, private Discord channel to discuss trades and strategies in real-time, customer support, trade alerts, and much more. Learn all about VIP membership here.
How can I access the premium indicators?
To access the premium indicators, which are plug and play ready, sign up for VIP membership here.
Back
Top