How to make each candle stick appears $value gain + % gain with the Open price and Close price?

LLP

Member
VIP
How to make each candle stick appears it’s up or down in value and % with the Open price and Close price?

Please see photo for explain. Example candle stick Close Price $105 , Open price is $100 , then it’s is up 5% will appear on the candle stick with + $5 value.
 

Attachments

  • 5%.png
    5%.png
    84.5 KB · Views: 114
Solution
How to make each candle stick appears it’s up or down in value and % with the Open price and Close price?

Please see photo for explain. Example candle stick Close Price $105 , Open price is $100 , then it’s is up 5% will appear on the candle stick with + $5 value.

This will place a bubble to the right of the last candle with the information you requested. You can move the bubble sideways by the number of bars @input bubblemover

Screenshot 2023-08-18 082427.png
Code:
#How to make each candle stick appears $value gain + % gain with the Open price and Close price?

input showbubble = yes;

input bubblemover = 0;#Hint bubblemover: Move sideways

def o = Round(open);
def c = Round(close);
def b = bubblemover;
def b1 = b + 1;
def last = IsNaN(c[b])...
How to make each candle stick appears it’s up or down in value and % with the Open price and Close price?

Please see photo for explain. Example candle stick Close Price $105 , Open price is $100 , then it’s is up 5% will appear on the candle stick with + $5 value.

This will place a bubble to the right of the last candle with the information you requested. You can move the bubble sideways by the number of bars @input bubblemover

Screenshot 2023-08-18 082427.png
Code:
#How to make each candle stick appears $value gain + % gain with the Open price and Close price?

input showbubble = yes;

input bubblemover = 0;#Hint bubblemover: Move sideways

def o = Round(open);
def c = Round(close);
def b = bubblemover;
def b1 = b + 1;
def last = IsNaN(c[b]) and !IsNaN(c[b1]);

AddChartBubble(
#Places bubble in expansion area by number of bars, determined by bubblemover, past last bar
showbubble and last[b],

#Bubble will appear at this price level
low[b1],

#Stack Open/Close prices
(if o[b1] > c[b1]
then "O: " + AsDollars(o[b1]) + "\n C: " + AsDollars(c[b1])
else "C: " + AsDollars(c[b1]) + "\nO: " + AsDollars(o[b1])) + "\n"

#Dollar change between Open/Close
+ AsDollars((c[b1] - o[b1])) + "\n"

#Percent changee between Open/Close
+ AsPercent((c[b1] - o[b1]) / Min(c[b1], o[b1])),

#Bubble color
if o[b1] > c[b1]
then Color.LIGHT_RED
else Color.LIGHT_GREEN);

#
 
  • Gold STAR
Reactions: LLP
Solution
This will place a bubble to the right of the last candle with the information you requested. You can move the bubble sideways by the number of bars @input bubblemover
Hi, can you make each candle permanently stated with changes in $vaue & % without BOX? example only include: -$1.00 -0.02% (only Dollar value change and % change)
 
Last edited:

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
413 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