Last cross of indicator above or below a value (0) - EasyLanguage Programming | futures io social day trading
futures io futures trading


Last cross of indicator above or below a value (0)
Updated: Views / Replies:1,452 / 4
Created: by tozwp 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
 

Last cross of indicator above or below a value (0)

  #1 (permalink)
Trading Apprentice
Milwaukee WI/US
 
Futures Experience: Intermediate
Platform: Multicharts, Tradestation
Favorite Futures: TF
 
Posts: 7 since Feb 2012
Thanks: 2 given, 1 received

Last cross of indicator above or below a value (0)

Trying to figure out how to code something but not quite sure where to start. Part of a strategy needs to find the time or bar number of lowest low or highest high of the oscillator between the current cross and the last cross of the zero line. In other words, if the oscillator is crossing 0 on this bar, go back and find the last cross of 0. Between this bar and the bar that the oscillator last crossed zero, find the bar with the highest high or lowest low. Conceptually it seems easy but I don't have a clue where to start. Would this have to be done in a loop structure working backward to check each bar for a cross or can I use something with the Cross command and a qualifier for the last occurance like [1]?

If anyone can give me an idea of where to start I'd appreciate it. Thanks!

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)
Trading for Fun
London
 
Futures Experience: None
Platform: mc, TS, ninja
Favorite Futures: es
 
Bimi's Avatar
 
Posts: 118 since Mar 2010
Thanks: 42 given, 58 received



tozwp View Post
Trying to figure out how to code something but not quite sure where to start. Part of a strategy needs to find the time or bar number of lowest low or highest high of the oscillator between the current cross and the last cross of the zero line. In other words, if the oscillator is crossing 0 on this bar, go back and find the last cross of 0. Between this bar and the bar that the oscillator last crossed zero, find the bar with the highest high or lowest low. Conceptually it seems easy but I don't have a clue where to start. Would this have to be done in a loop structure working backward to check each bar for a cross or can I use something with the Cross command and a qualifier for the last occurance like [1]?

If anyone can give me an idea of where to start I'd appreciate it. Thanks!

don't look back, look forward.


initialize 2 variables: a bar counter, and a maxvalue.

start with the first cross,

as soon as the osc cross above zero,
barcounter = currentbar ( timecount if you wish)
maxvalue = osc

next bar:
if osc > maxvalue then do the above assignment again.

keep doing this on every bar and you will always know the max value of the osc and the bar number of that occurence.


when the osc cross zero again, the variables will be re-initialized.

Reply With Quote
The following user says Thank You to Bimi for this post:
 
  #4 (permalink)
Trading Apprentice
Milwaukee WI/US
 
Futures Experience: Intermediate
Platform: Multicharts, Tradestation
Favorite Futures: TF
 
Posts: 7 since Feb 2012
Thanks: 2 given, 1 received

Thanks! I hadn't thought of working forward with this. I figured it would be simpler to wait for the event and then work backwards. I think I can manage to put together something using your technique. Appreciate the help!

Reply With Quote
The following user says Thank You to tozwp for this post:
 
  #5 (permalink)
Trading for Fun
London
 
Futures Experience: None
Platform: mc, TS, ninja
Favorite Futures: es
 
Bimi's Avatar
 
Posts: 118 since Mar 2010
Thanks: 42 given, 58 received


tozwp View Post
Thanks! I hadn't thought of working forward with this. I figured it would be simpler to wait for the event and then work backwards. I think I can manage to put together something using your technique. Appreciate the help!

You are welcome.

Please press the "Thanks" button if you like the answer.

Reply With Quote
The following user says Thank You to Bimi for this post:

Reply



futures io > > > > > Last cross of indicator above or below a value (0)

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
macd cross indicator wanted trdr NinjaTrader Programming 8 October 27th, 2012 04:40 PM
CCI Cross Zero Line Indicator Senna NinjaTrader Programming 13 August 23rd, 2012 01:12 PM
Price MA cross help Please tickvix NinjaTrader 2 February 28th, 2012 12:41 PM
TEMA cross cory The Elite Circle 10 December 16th, 2011 06:45 PM
Stochastics Cross Indicator DennisA NinjaTrader 1 March 30th, 2011 07:30 PM


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

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-15 in 0.09 seconds with 19 queries on phoenix via your IP 54.82.56.95