SetPlotColor one bar late - EasyLanguage Programming | futures io social day trading
futures io futures trading


SetPlotColor one bar late
Updated: Views / Replies:407 / 3
Created: by olobay Attachments:1

Welcome to futures io.

(If you already have an account, login at the top of the page)

futures io is the largest futures trading community on the planet, with over 90,000 members. At futures io, our goal has always been and always will be to create a friendly, positive, forward-thinking community where members can openly share and discuss everything the world of trading has to offer. The community is one of the friendliest you will find on any subject, with members going out of their way to help others. Some of the primary differences between futures io and other trading sites revolve around the standards of our community. Those standards include a code of conduct for our members, as well as extremely high standards that govern which partners we do business with, and which products or services we recommend to our members.

At futures io, our focus is on quality education. No hype, gimmicks, or secret sauce. The truth is: trading is hard. To succeed, you need to surround yourself with the right support system, educational content, and trading mentors Ė all of which you can find on futures io, utilizing our social trading environment.

With futures io, you can find honest trading reviews on brokers, trading rooms, indicator packages, trading strategies, and much more. Our trading review process is highly moderated to ensure that only genuine users are allowed, so you donít need to worry about fake reviews.

We are fundamentally different than most other trading sites:
  • We are here to help. Just let us know what you need.
  • We work extremely hard to keep things positive in our community.
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts.
  • We firmly believe in and encourage sharing. The holy grail is within you, we can help you find it.
  • 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.

-- Big Mike, Site Administrator

Reply
 
Thread Tools Search this Thread
 

SetPlotColor one bar late

  #1 (permalink)
Elite Member
Montreal
 
Futures Experience: Intermediate
Platform: MultiCharts
Broker/Data: IB Canada/IQFeed
Favorite Futures: TF, CL
 
Posts: 261 since Jul 2011
Thanks: 288 given, 332 received

SetPlotColor one bar late

Hi,

I'm trying to code a simple CCI indicator. When the CCI is going up, colour should be green and red when the CCI is going down. With the code below, the indicator is changing colours one bar too late. Any ideas how to make it react on time?

Thanks.

 
Code
input: fast_length(6),raw_length(20),smooth_length(10),
	zone1(100),zone2(-100),zone3(0),
	upColour(Green), downColour(Red);

variables: slow(0), medium(0), fast(0), raw(0), smooth(0);

fast=cci(fast_length);
raw=cci(raw_length);
smooth=average(raw,smooth_length);

plot1(fast, "6");
plot2(smooth, "Smooth");
plot3(zone1, " ");
plot4(zone2, " ");
plot5(zone3, " ");


if (Plot1 > Plot1[1]) then 
SetPlotColor(1, upColour)
else if (Plot1 < Plot1[1]) then 
SetPlotColor(1, downColour);
Every time the indicator changes direction, the plot color lags one bar. Not all direction changes have been marked in the picture.

Please register on futures.io to view futures trading content such as post attachment(s), image(s), and screenshot(s).

Reply With Quote
 
  #2 (permalink)
Quick Summary
Quick Summary Post

Quick Summary is created and edited by users like you... Add FAQ's, Links and other Relevant Information by clicking the edit button in the lower right hand corner of this message.

 
  #3 (permalink)
Market Wizard
Hamburg Germany
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation, Multicharts.NET, NinjaTrader, MetaTrader
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 1,527 since Apr 2013
Thanks: 229 given, 854 received
Forum Reputation: Legendary


olobay,

this is the way SetPlotColor works. When the condition is detected it will color like that to the next plot value.
You can shift the coloring by one bar adding [1] to SetPlotColor.

Regards,
ABCTG

Reply With Quote
The following user says Thank You to ABCTG for this post:
 
  #4 (permalink)
Elite Member
Montreal
 
Futures Experience: Intermediate
Platform: MultiCharts
Broker/Data: IB Canada/IQFeed
Favorite Futures: TF, CL
 
Posts: 261 since Jul 2011
Thanks: 288 given, 332 received


ABCTG View Post
olobay,

this is the way SetPlotColor works. When the condition is detected it will color like that to the next plot value.
You can shift the coloring by one bar adding [1] to SetPlotColor.

Regards,
ABCTG

Thanks ABCTG. That's exactly what I want.

Reply With Quote

Reply



futures io > > > > > SetPlotColor one bar late

Thread Tools Search this Thread
Search this Thread:

Advanced Search



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

Linda Bradford Raschke: Reading The Tape

Elite only

Adam Grimes: TBA

Elite only

NinjaTrader: TBA

January

Ran Aroussi: TBA

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to step forward bar by bar (F12) with full bar not half bar? mercyman MetaTrader 1 October 23rd, 2012 05:49 PM
Got home late kbit Jokes 0 July 27th, 2012 04:56 PM
Never be late kbit Jokes 0 January 30th, 2012 06:05 PM
SetPlotcolor to Orange. Is it possible? arjfca EasyLanguage Programming 3 December 1st, 2010 08:20 PM
1 Bar Late Zoethecus Commodities Futures Trading 13 January 1st, 2010 03:48 PM


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

Copyright © 2017 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432, info@futures.io
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 2017-12-13 in 0.08 seconds with 20 queries on phoenix via your IP 54.196.182.102