TOS Draw Horizontal Line at Current Price Indicator needed - ThinkOrSwim | futures trading

Go Back

> Futures Trading, News, Charts and Platforms > Platforms and Indicators > ThinkOrSwim

TOS Draw Horizontal Line at Current Price Indicator needed
Started:April 11th, 2016 (11:10 PM) by ceramictilepro Views / Replies:274 / 1
Last Reply:August 23rd, 2016 (05:18 PM) Attachments:0

Welcome to

Welcome, Guest!

This forum was established to help traders (especially futures traders) by openly sharing indicators, strategies, methods, trading journals and discussing the psychology of trading.

We are fundamentally different than most other trading forums:
  • We work extremely hard to keep things positive on our forums.
  • We do not tolerate rude behavior, trolling, or vendor advertising in posts.
  • We firmly believe in openness and encourage sharing. The holy grail is within you, it is not something tangible you can download.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.

You'll need to register in order to view the content of the threads and start contributing to our community. It's free and simple, and we will never resell your private information.

-- Big Mike

Thread Tools Search this Thread

TOS Draw Horizontal Line at Current Price Indicator needed

Old April 11th, 2016, 11:10 PM   #1 (permalink)
Elite Member
Roseville CA
Futures Experience: Advanced
Platform: N7
Broker/Data: Amp Futures/CQG
Favorite Futures: ES
Posts: 124 since Jun 2009
Thanks: 32 given, 18 received

TOS Draw Horizontal Line at Current Price Indicator needed


I am looking for a simple indicator that draws a horizontal line across chart at current price.

very similar to the ninjatrader indicator

any help would greatly be appreciated.

I found this free TOS indicator online and it is real close to what I'm looking for but fails to draw across complete chart

# Close Extended Line
# From within the script settings panel, change the value of lineLength to extend the line further if desired.

input lineLength = 4;
def barNumber = BarNumber();
def barCount = HighestAll(If(IsNaN(close), 0, barNumber));
def closeLine = if barNumber == 1 then Double.NaN else if barNumber == barCount - lineLength then close[-lineLength] else if barNumber == barCount then Double.NaN else closeLine[1];
plot data = closeLine;
here is the link to the above code illustrating indicator in action
Fun with ThinkScript

thanks for any help

Reply With Quote

Old August 23rd, 2016, 05:18 PM   #2 (permalink)
Elite Member
munich germany
Futures Experience: Beginner
Platform: NinjaTrader
Favorite Futures: ES
Posts: 3 since Jun 2016
Thanks: 0 given, 0 received

Currrent price line can be made directly in NinjaTrader

In the meantime I have found a solution directly from NinjaTrader:
how do I draw a horizontal price line? - NinjaTrader Support Forum

Here is the video that explains how to do it: 2015-08-06_0713 - NT_Paul's library

This works also in NT8.

Best regards

Reply With Quote

Reply > Futures Trading, News, Charts and Platforms > Platforms and Indicators > ThinkOrSwim > TOS Draw Horizontal Line at Current Price Indicator needed

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Upcoming Webinars and Events (4:30PM ET unless noted)

An Afternoon with FIO trader bobwest

Elite only

NinjaTrader 8: Programming Profitable Trading Edges w/Scott Hodson

Elite only

Anthony Drager: Executing on Intermarket Correlations & Order Flow, Part 2

Elite only

Adam Grimes: Five critically important keys to professional trading

Elite only

Machine Learning Concepts w/FIO member NJAMC

Elite only

MarketDelta Cloud Platform: Announcing new mobile features

Dec 1

NinjaTrader 8: Features and Enhancements

Dec 6

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to draw Horizontal Lines with price label at predefined Prices ? jsk123 ThinkOrSwim Programming 4 October 4th, 2015 04:44 PM
Horizontal line moving with price X tics away. deandavis NinjaTrader 1 September 5th, 2015 05:11 PM
Looking for Midpoint pivots and Horizontal line with price/text KahunaDog NinjaTrader 2 January 10th, 2015 02:00 PM
Where did Horizontal Price Line Indie Go? tdaman NinjaTrader 12 January 5th, 2012 01:29 PM
can you get a horizontal line at the current high of the volume indicator anniebee321 NinjaTrader 4 December 10th, 2010 05:18 PM

All times are GMT -4. The time now is 04:04 AM.

Copyright © 2016 by All information is for educational use only and is not investment advice.
There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
no new posts

Page generated 2016-10-23 in 0.08 seconds with 20 queries on phoenix via your IP