MULTICHART CODING - MultiCharts | futures io social day trading
futures io futures trading


MULTICHART CODING
Updated: Views / Replies:930 / 9
Created: by gfdaniels 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
 

MULTICHART CODING

  #1 (permalink)
Elite Member
Roswell
 
Futures Experience: Intermediate
Platform: Multicharts
Favorite Futures: es tf ym nq
 
Posts: 9 since Jul 2015
Thanks: 0 given, 0 received

MULTICHART CODING

dOES ANYONE HAVE ANY CODE THAT I CAN ADD TO MY THREE EXP AVERAGE STATEGEY TO NOT INITIATE A TRADE UNLESS IT IS ABOVE OR BELOW THE 50 EMA?. THIS IS FOR MY AUTOTRADING STATEGY ALSO HOW TO ADD A TIMEFRAME IT CAN TRADE.

Reply With Quote
 
  #2 (permalink)
 Vendor: tradingcode.net 
The Netherlands
 
Futures Experience: None
Platform: MultiCharts, TradingView
Favorite Futures: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 661 received


gfdaniels View Post
dOES ANYONE HAVE ANY CODE THAT I CAN ADD TO MY THREE EXP AVERAGE STATEGEY TO NOT INITIATE A TRADE UNLESS IT IS ABOVE OR BELOW THE 50 EMA?. THIS IS FOR MY AUTOTRADING STATEGY ALSO HOW TO ADD A TIMEFRAME IT CAN TRADE.

Please turn off the Capslock. Then post the code you already have so we can take a look at it. Bonus points if you clarify your question.

Reply With Quote
 
  #3 (permalink)
Elite Member
Roswell
 
Futures Experience: Intermediate
Platform: Multicharts
Favorite Futures: es tf ym nq
 
Posts: 9 since Jul 2015
Thanks: 0 given, 0 received

muticharts coding


inputs: Price( Close ), FastLength(4 ), MedLength(5 ), SlowLength(8) ;
variables: var0( 0 ), var1( 0 ), var2( 0 ) ;

var0 = XAverage( Price, FastLength ) ;
var1 = XAverage( Price, MedLength ) ;
var2 = XAverage( Price, SlowLength ) ;

Condition1 = Price < var0 and var0 < var1 and var1 < var2 ;
condition2 = CurrentBar > 1 and Condition1 and Condition1[1] = false;
if condition2
then
Sell Short ( "MA3CrsSE" ) next bar at market

inputs: Price( Close ), FastLength(4), MedLength( 5), SlowLength(8) ;
variables: var0( 0 ), var1( 0 ), var2( 0 ) ;

var0 = XAverage( Price, FastLength ) ;
var1 = XAverage( Price, MedLength ) ;
var2 = XAverage( Price, SlowLength ) ;

Condition1 = Price > var0 and var0 > var1 and var1 > var2 ;

condition2 = CurrentBar > 1 and Condition1 and Condition1[1] = false;
if condition2
then
Buy ( "MA3CrsLE" ) next bar at market ;


Last edited by gfdaniels; August 13th, 2015 at 10:16 AM. Reason: to add
Reply With Quote
 
  #4 (permalink)
Elite Member
Roswell
 
Futures Experience: Intermediate
Platform: Multicharts
Favorite Futures: es tf ym nq
 
Posts: 9 since Jul 2015
Thanks: 0 given, 0 received

more clarification

I just want to add to not take a trade short if price is above the 50 ema and vice versa

Reply With Quote
 
  #5 (permalink)
 Vendor: tradingcode.net 
The Netherlands
 
Futures Experience: None
Platform: MultiCharts, TradingView
Favorite Futures: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 661 received


gfdaniels View Post
I just want to add to not take a trade short if price is above the 50 ema and vice versa

I assumed that your `SlowLength` input is manually set to 50 since I couldn't find an EMA 50. Here I just added the condition that compares the `Close` value against the `var2` variable, which holds the EMA of the `SlowLength` period:

 
Code
Inputs: 
	Price( Close ), FastLength(4 ), MedLength(5 ), SlowLength(8) ;

variables: 
	var0( 0 ), var1( 0 ), var2( 0 ) ;

var0 = XAverage( Price, FastLength ) ;
var1 = XAverage( Price, MedLength ) ;
var2 = XAverage( Price, SlowLength ) ;

Condition1 = Price < var0 and var0 < var1 and var1 < var2 ;
condition2 = CurrentBar > 1 and Condition1 and Condition1[1] = false;

if (condition2 and Close < var2) then
	Sell Short ( "MA3CrsSE" ) next bar at market;

Condition1 = Price > var0 and var0 > var1 and var1 > var2 ;

condition2 = CurrentBar > 1 and Condition1 and Condition1[1] = false;

if (condition2 and Close > var2) then
	Buy ( "MA3CrsLE" ) next bar at market ;
Is this what you meant?

Reply With Quote
The following user says Thank You to Jura for this post:
 
  #6 (permalink)
Elite Member
Roswell
 
Futures Experience: Intermediate
Platform: Multicharts
Favorite Futures: es tf ym nq
 
Posts: 9 since Jul 2015
Thanks: 0 given, 0 received

code


Jura View Post
I assumed that your `SlowLength` input is manually set to 50 since I couldn't find an EMA 50. Here I just added the condition that compares the `Close` value against the `var2` variable, which holds the EMA of the `SlowLength` period:

 
Code
Inputs: 
	Price( Close ), FastLength(4 ), MedLength(5 ), SlowLength(8) ;

variables: 
	var0( 0 ), var1( 0 ), var2( 0 ) ;

var0 = XAverage( Price, FastLength ) ;
var1 = XAverage( Price, MedLength ) ;
var2 = XAverage( Price, SlowLength ) ;

Condition1 = Price < var0 and var0 < var1 and var1 < var2 ;
condition2 = CurrentBar > 1 and Condition1 and Condition1[1] = false;

if (condition2 and Close < var2) then
	Sell Short ( "MA3CrsSE" ) next bar at market;

Condition1 = Price > var0 and var0 > var1 and var1 > var2 ;

condition2 = CurrentBar > 1 and Condition1 and Condition1[1] = false;

if (condition2 and Close > var2) then
	Buy ( "MA3CrsLE" ) next bar at market ;
Is this what you meant?

You are right i manually plot the 50 ema on the screen however i would like it to leave those conditions the same accept add that it will not take a short trade it it is above the 50 ema and vice versa, where would i inserst 50 at

Reply With Quote
 
  #7 (permalink)
 Vendor: tradingcode.net 
The Netherlands
 
Futures Experience: None
Platform: MultiCharts, TradingView
Favorite Futures: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 661 received


gfdaniels View Post
You are right i manually plot the 50 ema on the screen however i would like it to leave those conditions the same accept add that it will not take a short trade it it is above the 50 ema and vice versa, where would i inserst 50 at

Hm, I believe I already added that to the code (see my previous post + motivation).

Did I misunderstand you or doesn't it work for you?

Reply With Quote
 
  #8 (permalink)
Elite Member
Roswell
 
Futures Experience: Intermediate
Platform: Multicharts
Favorite Futures: es tf ym nq
 
Posts: 9 since Jul 2015
Thanks: 0 given, 0 received

Coding


Jura View Post
Hm, I believe I already added that to the code (see my previous post + motivation).

Did I misunderstand you or doesn't it work for you?

It did not work, i used it and it did not make a difference, so i dont know if i explained myself. I need the three ema that i have to only fire a signal if it is above or below the 50 ema, so i would assume that i have to add that rule somehow to the code that i have, can you do that for me PLEASE. I really appreciate what you done for me so far.

Reply With Quote
 
  #9 (permalink)
 Vendor: tradingcode.net 
The Netherlands
 
Futures Experience: None
Platform: MultiCharts, TradingView
Favorite Futures: ...
 
Jura's Avatar
 
Posts: 774 since Apr 2010
Thanks: 2,347 given, 661 received


gfdaniels View Post
You are right i manually plot the 50 ema on the screen however i would like it to leave those conditions the same accept add that it will not take a short trade it it is above the 50 ema and vice versa, where would i inserst 50 at


gfdaniels View Post
It did not work, i used it and it did not make a difference, so i dont know if i explained myself. I need the three ema that i have to only fire a signal if it is above or below the 50 ema, so i would assume that i have to add that rule somehow to the code that i have

Ah I see, I misunderstood you; I thought you configured the signal to an EMA 50 but now I understand that you plotted the EMA50 on the chart (so an indicator).

I've updated your code to include a 50-period EMA now. The input for it is named `SlowerLength`. Try to see if this works for you:

 
Code
Inputs: 
	Price(Close), 
	FastLength(4), 
	MedLength(5), 
	SlowLength(8),
	SlowerLength(50);

Variables:
	emaQuick(0), emaMed(0), emaSlow(0), emaSlower(0);

emaQuick = XAverage(Price, FastLength);
emaMed = XAverage(Price, MedLength);
emaSlow = XAverage(Price, SlowLength);
emaSlower = XAverage(Price, SlowerLength);

Condition1 = Price < emaQuick and emaQuick < emaMed and emaMed < emaSlow;
condition2 = CurrentBar > 1 and Condition1 and Condition1[1] = false;

if (condition2 and Close < emaSlower) then
	Sell Short ( "MA3CrsSE" ) next bar at market;

Condition1 = Price > emaQuick and emaQuick > emaMed and emaMed > emaSlow;

condition2 = CurrentBar > 1 and Condition1 and Condition1[1] = false;

if (condition2 and Close > emaSlower) then
	Buy ( "MA3CrsLE" ) next bar at market ;

Reply With Quote
 
  #10 (permalink)
Elite Member
Roswell
 
Futures Experience: Intermediate
Platform: Multicharts
Favorite Futures: es tf ym nq
 
Posts: 9 since Jul 2015
Thanks: 0 given, 0 received

Coding



Jura View Post
Ah I see, I misunderstood you; I thought you configured the signal to an EMA 50 but now I understand that you plotted the EMA50 on the chart (so an indicator).

I've updated your code to include a 50-period EMA now. The input for it is named `SlowerLength`. Try to see if this works for you:

 
Code
Inputs: 
	Price(Close), 
	FastLength(4), 
	MedLength(5), 
	SlowLength(8),
	SlowerLength(50);

Variables:
	emaQuick(0), emaMed(0), emaSlow(0), emaSlower(0);

emaQuick = XAverage(Price, FastLength);
emaMed = XAverage(Price, MedLength);
emaSlow = XAverage(Price, SlowLength);
emaSlower = XAverage(Price, SlowerLength);

Condition1 = Price < emaQuick and emaQuick < emaMed and emaMed < emaSlow;
condition2 = CurrentBar > 1 and Condition1 and Condition1[1] = false;

if (condition2 and Close < emaSlower) then
	Sell Short ( "MA3CrsSE" ) next bar at market;

Condition1 = Price > emaQuick and emaQuick > emaMed and emaMed > emaSlow;

condition2 = CurrentBar > 1 and Condition1 and Condition1[1] = false;

if (condition2 and Close > emaSlower) then
	Buy ( "MA3CrsLE" ) next bar at market ;

YOU ARE THE MAN, GOD BLESS YOU, IT WORKS.

Reply With Quote

Reply



futures io > > > > MULTICHART CODING

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
Multichart / Esignal - language - Both same? Sam7768 eSignal 4 May 8th, 2014 09:08 PM
How to individualize MultiChart orders? program MultiCharts 8 September 25th, 2012 03:52 AM
Multichart autotrade Serger Elite EasyLanguage Automated Trading 3 July 21st, 2011 01:16 PM
about multichart coding max-td MultiCharts 3 April 9th, 2010 09:49 AM


All times are GMT -4. The time now is 09:05 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-14 in 0.13 seconds with 19 queries on phoenix via your IP 54.221.73.186