Trend Line plots once - EasyLanguage Programming | futures io social day trading
futures io futures trading


Trend Line plots once
Updated: Views / Replies:1,059 / 9
Created: by RGButzArchInc Attachments:0

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
 

Trend Line plots once

  #1 (permalink)
Trading Apprentice
Columbus OHio
 
Futures Experience: Intermediate
Platform: TradeStation
Favorite Futures: Stocks
 
Posts: 10 since Sep 2014
Thanks: 0 given, 0 received

Trend Line plots once

I have an If Then statement with 4 conditions that may occur. When one of the four conditions occur the Then statement plot a vertical trend line with two text statements. The text statements are of the same name. One statement plots the name name of the bar above the high of the bar and one text statement plots the name below the low of the bar on the trend line.The trend line and names plot the first time one of the four conditions is met. However, succeeding times when the condition(s) occur nothing is plotted. I know the conditions are properly identified in the data because the print statement that plots in the debug tab plots the conditions as sought by the code. Thank you in advance for any all help and insight.

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,533 since Apr 2013
Thanks: 231 given, 855 received
Forum Reputation: Legendary


RGButzArchInc,

it's pretty hard to give you a helpful hint without knowing your code. If you post the code I am sure someone is willing to take a look at it. You don't have to reveal your actual logic, but can even replace it with something else. Just leave the trendline part and make sure the new logic suffers from the same issues.

Regards,
ABCTG

Reply With Quote
 
  #4 (permalink)
Trading Apprentice
Columbus OHio
 
Futures Experience: Intermediate
Platform: TradeStation
Favorite Futures: Stocks
 
Posts: 10 since Sep 2014
Thanks: 0 given, 0 received

The Code described in the narrative

TDR Ingress Line (ShowMe) - Tuesday, September 30, 2014 08:11:46
{*******************************************************************
Description : This Show Me Study draws a line on the chart
********************************************************************}
{Declarations}
Vars: Ingress Line(O);
Vars: Ingress-Date (0);
Vars: Ingress-Month(O);
Vars: Ingress-Day of Week(O);
Vars: Lower Llmit(O);
Vars: Upper-Limit(O);
Vars: Glyph-Lower(-l);
Vars: G1yph=Upper(-I);

{Aasignments}

Ingress Date = @DayofMonth(date);
Ingress-Month = @Month(date);
Ingress-Day_of_Week = @DayofWeek(date);
Lower Limit
Upper=Limit
Low -10;
High + 10;

Ingress falls on a Tuesday, Wednesday, or Thursday, or Friday}

If (Ingress Month = 1 and
Ingress Date = 21 and
(Ingress Day of Week = 2 or
Ingress Day of Week 3 or
Ingress Day-of-Week 4 or
Ingress=Day=of=Week 5)) Or

{Ingress falls on a Monday}

(Ingress_Month = 1 and
Ingress Date = 18 and
Ingress-Day_of_Week = 5 ) or

{Ingress falls on a Saturday}

(Ingress_Month = 1 and
Ingress Date = 20 and
Ingress-Day_of_Week = 5 or

{Ingress falls on a Sunday}

(Ingress_Month = 1 and
Ingress_Date = 19 and
Ingress_Day_of_Week = 5 ) then

Begin
Glyph_Lower = Text New(Date, 1600, (low -3), "CAP "+NumToStr(Year(Date),4) );
Text SetColor(Glyph Lower, White);
Text-SetStyle(Glyph=Lower,2,2) ;

Glyph_Upper = Text New(Date, 1600, (high + 5),"CAP "+NumToStr(Year(Date),4) );
Text SetColor(Glyph Upper, White);
Text-SetStyle(Glyph=Upper,2,2);

Ingress_Line @TL New(Date, 1600,Lower Limit,Date, O,Upper_Limit);

TL-SetCo1or(Ingress Line,Ye11ow);
TL-SetStyle(Ingress-Line,2) ;
TL=SetSize(Ingress_Line,7);

end;

Reply With Quote
 
  #5 (permalink)
Market Wizard
Hamburg Germany
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation, Multicharts.NET, NinjaTrader, MetaTrader
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 1,533 since Apr 2013
Thanks: 231 given, 855 received
Forum Reputation: Legendary

What are the @'s supposed to do in your code? Also there are a lot of spaces between variable names, so that the code you provided won't verify let alone even draw a single trendline.

Regards,
ABCTG

Reply With Quote
 
  #6 (permalink)
Trading Apprentice
Columbus OHio
 
Futures Experience: Intermediate
Platform: TradeStation
Favorite Futures: Stocks
 
Posts: 10 since Sep 2014
Thanks: 0 given, 0 received

Response

Thd @ signs are indicators that the function is a Easy Language function

The code runs on my computer.

I put the spaces in the post to make the code easily readable.

What the code doesn't does not plot any of the trend lines after the first trend line is plotted on the chart.

Reply With Quote
 
  #7 (permalink)
Market Wizard
Hamburg Germany
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation, Multicharts.NET, NinjaTrader, MetaTrader
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 1,533 since Apr 2013
Thanks: 231 given, 855 received
Forum Reputation: Legendary

So why are you converting reserved words into functions or what does @DayOfMonth do different than the reserved word DayOfMonth? Also what is "Ingress Date" supposed to do? That's what I meant with spaces between variable names, not the whitespaces in your code.

Regards,
ABCTG

 
Code
Ingress Date = @DayofMonth(date);


RGButzArchInc View Post
Thd @ signs are indicators that the function is a Easy Language function

The code runs on my computer.

I put the spaces in the post to make the code easily readable.

What the code doesn't does not plot any of the trend lines after the first trend line is plotted on the chart.


Reply With Quote
 
  #8 (permalink)
Trading Apprentice
Columbus OHio
 
Futures Experience: Intermediate
Platform: TradeStation
Favorite Futures: Stocks
 
Posts: 10 since Sep 2014
Thanks: 0 given, 0 received

The spaces are where the scan of the code did not recognize a dash or an equal sign, for example.

Reply With Quote
 
  #9 (permalink)
Membership Temporarily Revoked
Calgary Alberta/Canada
 
Futures Experience: Advanced
Platform: TDWaterhouse
Favorite Futures: stocks (long term)
 
Posts: 934 since Feb 2014
Thanks: 180 given, 777 received

First of all, please forgive me if what I point out is unimportant as I am not totally familiar with this language but I do notice inconsistencies in your code. I have changed the color of the code to highlight them



RGButzArchInc View Post
TDR Ingress Line (ShowMe) - Tuesday, September 30, 2014 08:11:46
{*******************************************************************
Description : This Show Me Study draws a line on the chart
********************************************************************}
{Declarations}
Vars: Ingress Line(O);
Vars: Ingress-Date (0);
Vars: Ingress-Month(O);
Vars: Ingress-Day of Week(O);
Vars: Lower Llmit(O);

Why is there no dash between "Lower" and Limit"
Vars: Upper-Limit(O);
Vars: Glyph-Lower(-l);
Vars: G1yph=Upper(-I);

{Aasignments}

Ingress Date = @DayofMonth(date);
Ingress-Month = @Month(date);
Ingress-Day_of_Week = @DayofWeek(date);
Lower Limit
Upper=Limit
Low -10;
High + 10;


There don't appear to be any assignments here. Should not these statements be

Lower Limit = Low-10; (or rather : Lower-Limit = Low-10;
Upper-Limit = High + 10;


Ingress falls on a Tuesday, Wednesday, or Thursday, or Friday}

It seems to me that {} brackets are to wrap comments...but you are missing the left bracket in that previous line...Is that a problem??? I don't know but it is inconsistent

{Ingress falls on a Tuesday, Wednesday, or Thursday, or Friday}



these are my observations on your code...maybe those observations don't mean much or maybe they are your problem.

Finally why would you use a dash "-" in your variables.....How can one tell the difference between an subtraction and a character....would not an underscore "_" or simply joining the characters into one word be better??

EDIT: I also note other inconsistencies in the naming of your variables....

Vars: Ingress Line(O); ........ has no dash
Vars: G1yph=Upper(-I); ........ Is this a mathematical function or a variable name also is this a typo should it not be "Glyph" not "G1yph" as I see no reference to to G1yph in the statement

Glyph_Upper = Text New(Date, 1600, (high + 5),"CAP "+NumToStr(Year(Date),4) );

Finally you show no consistent naming of your variables or assignments

(Ingress Day of Week = 2 or
Ingress Day of Week 3 or there is no "=" sign How is your variable to get the value 3
Ingress Day-of-Week 4 or Now you add dashes is this a new variable??? again no equal sign
Ingress=Day=of=Week 5)) now "=" signs added except for the assignment of 5

As I said before...I don't know this script language but as a former debugger of VB code this looks weird to me


Last edited by Underexposed; October 1st, 2014 at 01:55 PM. Reason: more potential problems found
Reply With Quote
The following user says Thank You to Underexposed for this post:
 
  #10 (permalink)
Market Wizard
Hamburg Germany
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation, Multicharts.NET, NinjaTrader, MetaTrader
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 1,533 since Apr 2013
Thanks: 231 given, 855 received
Forum Reputation: Legendary


You can upload the working ELD here, as this will include the functions then, and I will take a look. The code you posted here won't verify let alone even give one trendline. Maybe something just went wrong with posting it, but there are so many issues in it that I doubt anyone is willing to fix those before getting to helping you with your actual problem.

Regards,
ABCTG


RGButzArchInc View Post
The spaces are where the scan of the code did not recognize a dash or an equal sign, for example.


Reply With Quote

Reply



futures io > > > > > Trend Line plots once

Thread Tools Search this Thread
Search this Thread:

Advanced Search



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

Jigsaw Trading: TBA

Elite only

FuturesTrader71: TBA

Elite only

NinjaTrader: TBA

Jan 18

RandBots: TBA

Jan 23

GFF Brokers & CME Group: Futures & Bitcoin

Elite only

Adam Grimes: TBA

Elite only

Ran Aroussi: TBA

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
trend line indicator sehgasan NinjaTrader 8 February 6th, 2016 10:04 PM
EL Trend Line based on Pivot Phillo82 EasyLanguage Programming 1 October 14th, 2013 11:45 AM
Drawn trend line automatically on other charts, How? hector24 NinjaTrader 4 November 2nd, 2011 01:32 PM
Copy Trend Line NT7 AR01 Traders Hideout 2 September 21st, 2010 01:48 PM
trying to create a Trend Line Rejection Indicator Eric NinjaTrader Programming 5 October 27th, 2009 03:45 PM


All times are GMT -4. The time now is 11:05 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-16 in 0.14 seconds with 19 queries on phoenix via your IP 54.226.34.209