Help with EasyLanguage - EasyLanguage Programming | futures.io
futures.io futures trading


Help with EasyLanguage
Started: by yofrankie1 Views / Replies:154 / 12
Last Reply: Attachments:2

Welcome to futures.io.

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

Reply
 2  
 
Thread Tools Search this Thread
 

Help with EasyLanguage

  #1 (permalink)
Trading Apprentice
KS/Olathe
 
Futures Experience: Intermediate
Platform: TradeStation
Favorite Futures: Crude CL
 
Posts: 6 since Jan 2017
Thanks: 0 given, 0 received

Help with EasyLanguage

Hey,

I need some help with EasyLanguage. I am designing a system that will go LONG on a pullback when the CURRENT price crosses the 10 day EMA. My question is this: I can not find a function for CURRENT PRICE. I know about current bid and ask, but is there anyway I put current price instead of the bid and ask? For example: $AMZN is up 30 points in premarket. I wait for a pullback and go long only when the CURRENT price crosses the 10 day EMA on the 30minute chart. How do I code current price into the system? I hope this question made sense.

Thanks in advance!
Frankie.

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)
Elite Member
San Diego, California
 
Futures Experience: Advanced
Platform: MultiCharts
Favorite Futures: ES, NQ
 
Posts: 26 since Mar 2016
Thanks: 0 given, 20 received


Use "close" or "c" for short. That will be the current closing price of your thirty-minute bar. If you use intrabar order generation, it will be the latest tick price, though intrabar order generation may cause many more trades.

Further, you may want to use "c crosses above ema" for your trigger and not "c>ema", as "c crosses above ema" is an event while "c>ema" is a state.

Reply With Quote
The following user says Thank You to chik for this post:
 
  #4 (permalink)
Trading Apprentice
KS/Olathe
 
Futures Experience: Intermediate
Platform: TradeStation
Favorite Futures: Crude CL
 
Posts: 6 since Jan 2017
Thanks: 0 given, 0 received

Hey Chic,

But 'close' wont trigger a buy until the bar closes right? How do I trigger a buy as soon as the price hits the EMA?

Thank you for your reply!
Frankie.

Reply With Quote
 
  #5 (permalink)
 Vendor: abctradinggroup.com 
Hamburg Germany
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation, Multicharts.NET, NinjaTrader, MetaTrader
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 1,189 since Apr 2013
Thanks: 198 given, 679 received

Futures Edge on FIO

Which products do you trade?

 
Frankie,

that depends on your code. When you don't use intrabar order generation you can only issue orders end of the bar.

With intrabar order generation you can trigger orders as soon as your conditions are met (using Close you can access the current last price then).

Regards,

ABCTG

Reply With Quote
 
  #6 (permalink)
Trading Apprentice
KS/Olathe
 
Futures Experience: Intermediate
Platform: TradeStation
Favorite Futures: Crude CL
 
Posts: 6 since Jan 2017
Thanks: 0 given, 0 received

AAAAAAA thats exactly what I needed:

IntrabarOrderGeneration = TRUE;

Thank you for your help! Cha ching problem solved

Reply With Quote
 
  #7 (permalink)
Elite Member
San Diego, California
 
Futures Experience: Advanced
Platform: MultiCharts
Favorite Futures: ES, NQ
 
Posts: 26 since Mar 2016
Thanks: 0 given, 20 received

You can also have a resting stop on the EMA: "buy next bar at EMA stop"

Reply With Quote
 
  #8 (permalink)
Trading Apprentice
KS/Olathe
 
Futures Experience: Intermediate
Platform: TradeStation
Favorite Futures: Crude CL
 
Posts: 6 since Jan 2017
Thanks: 0 given, 0 received

Hey guys,

Take a look at the code below:

inputs: EMAType (10), //Which EMA to use

StopLoss (500),
ProfitTaking (1500);

variables: EMA_Trigger (0),
BullCross (false);


//Main Program

EMA_Trigger = XAverage(Close, EMAType); //EMA
BullCross = CurrentBid crosses under EMA_Trigger;

If (BullCross) then
begin

[IntrabarOrderGeneration = True]
Buy 1000 shares this bar at Close;

end;

SetStopPosition;
SetStopLoss(StopLoss);
SetStopPosition;
SetProfitTarget(ProfitTaking);

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


Why is the buy order not getting executed at Point A in the screenshot? The point when the current price hits the EMA? Isn't that the point of IntrabarOrderGeneration function?

Please keep in mind I am a non programmer

Thank you,
Frankie!

Reply With Quote
 
  #9 (permalink)
Elite Member
San Diego, California
 
Futures Experience: Advanced
Platform: MultiCharts
Favorite Futures: ES, NQ
 
Posts: 26 since Mar 2016
Thanks: 0 given, 20 received

Enable [IntrabarOrderGeneration = True] at the top of the script, above your inputs, not after (BullCross) turns true.

Reply With Quote
 
  #10 (permalink)
Trading Apprentice
KS/Olathe
 
Futures Experience: Intermediate
Platform: TradeStation
Favorite Futures: Crude CL
 
Posts: 6 since Jan 2017
Thanks: 0 given, 0 received


Still the buy order is getting executed at the same place...

Reply With Quote

Reply



futures.io > > > > > Help with EasyLanguage

Thread Tools Search this Thread
Search this Thread:

Advanced Search



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

Anthony Drager: Pulling the trigger with confidence

Elite only
 

Leo Murphy: The Art and Science of Technical Analysis

Elite only
 

FuturesTrader71: Ask Me Anything

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
Easylanguage help Hodon TradeStation 1 January 14th, 2016 12:25 PM
EasyLanguage HELP!! (please) :) andrewfx EasyLanguage Programming 3 July 15th, 2014 04:37 AM
EasyLanguage vs NinjaScript Traderji Platforms and Indicators 2 October 22nd, 2010 02:00 AM
Easylanguage vs. C++ Cogito ergo sum EasyLanguage Programming 10 August 2nd, 2010 03:12 PM


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

no new posts
Page generated 2017-01-23 in 0.13 seconds with 20 queries on phoenix via your IP 174.129.78.73