Forex
Google
New signals service!

Go Back   Forex Trading > Programming > Metatrader Programming


Register in Forex TSD!
Trading Systems Leaders in this forum (automated trading systems) are winning more than 3000 pips in a month (30000$ investing one lot every time).
Click here to register and get more information

Reply
 
LinkBack Thread Tools Display Modes
  #451 (permalink)  
Old 10-05-2008, 11:14 PM
Senior Member
 
Join Date: Apr 2006
Posts: 131
InTrance is on a distinguished road
Quote:
Originally Posted by streamyx View Post
i am new forex and also learning to write the technical indicators
Hi
i am new here and glad to come across this site with some much news and information about forex trading.

i am currently using interbank FX platform which has most commonly used technical indicators but i am trying to figure out how to get the "6 days moving average for the Williams % Range" indicator

for metastock software the formula is very simple to set
it is : Mov(WillR(14),6,S )

but for metaquotes language, the formula seems much more complicating to understand

i saw the basic metaquotes language for williams % range being :

//----Williams?Percent Range calculation
i = Bars - ExtWPRPeriod - 1;
if(nCountedBars > ExtWPRPeriod)
i = Bars - nCountedBars - 1;
while(i >= 0)
{
double dMaxHigh = High[Highest(NULL, 0, MODE_HIGH, ExtWPRPeriod, i)];
double dMinLow = Low[Lowest(NULL, 0, MODE_LOW, ExtWPRPeriod, i)];
if(!CompareDouble((dMaxHigh - dMinLow), 0.0))
ExtWPRBuffer[i] = -100*(dMaxHigh - Close[i]) / (dMaxHigh - dMinLow);
i--;
}
//----

can anyone here help me to modify the above formula or better still come up with a new formula so that i can get the 6 days moving average for williams % range and also the original williams % range line, both together in the same window so that i can see the crossover of the two lines in the broker platform?

thanks

streamyx
You might be able to do it by first attaching Williams R% and then dragging on to it the Moving Average indicator. Don't forget to select "apply to first indicator's data" in the settings.

Regards
__________________
Need a Professional Programmer? PM me!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #452 (permalink)  
Old 10-06-2008, 05:05 PM
Member
 
Join Date: Dec 2007
Posts: 77
ztdep is on a distinguished road
A ea

Dear frineds:
I have several trades opened, i want to let the EA do the folloing. when the total profit reach a value it can close all the trades.
regards
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #453 (permalink)  
Old 10-10-2008, 09:49 PM
Senior Member
 
Join Date: Feb 2006
Posts: 559
Michel is on a distinguished road
Quote:
Originally Posted by amamil View Post
I am looking for information on how to apply two expert advisors at the same time. Is that possible or can you only put in two indicators.
only one ea per chart, but you may have as many charts of the same symbol. timeframe as you want. Don't forget to use MagicNumbers to differentiate the trades of eas working on the same pair.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #454 (permalink)  
Old 10-12-2008, 12:27 AM
Member
 
Join Date: May 2008
Posts: 30
frankychen is on a distinguished road
Question How can I get other indicator's signal

How can I get other indicator's signal?

For Example:

A indicator
signal=OK

B indicator
If A indicator's signal=OK then ......

Thanks a lot!

Franky
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #455 (permalink)  
Old 10-12-2008, 03:05 AM
Senior Member
 
Join Date: Nov 2006
Posts: 215
luxinterior is on a distinguished road
Didn't you ask the same question yesterday and received an answer?

Lux
__________________
Build An Expert Advisor. FREE E-course As Seen On TV
ForexArea.com
Users of Gap Trader from 'Forex-Assistant' MUST Read This
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #456 (permalink)  
Old 10-13-2008, 09:33 PM
Junior Member
 
Join Date: Sep 2008
Posts: 16
bkr1969 is on a distinguished road
A little help

I have been working on an EA for the last 4 days and my eyes are starting to cross. I can get it to run fine for all pairs in certain time ranges, but there is some error(s) somewhere that makes it break down long term. Is there anyone here willing to try to debug it for me? It's rather lengthy but well commented. I will send you the code and the strategy if you're interested. Thanks.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #457 (permalink)  
Old 10-15-2008, 12:07 AM
matrixebiz's Avatar
Senior Member
 
Join Date: Oct 2006
Posts: 1,174
matrixebiz is on a distinguished road
If I have many OrderSend functions in a row like so;
Ticket = OrderSend(sym1b, OP_BUY........
OrderSend(sym2b, OP_BUY.......
OrderSend(sym3b, OP_BUY.......
OrderSend(sym4b, OP_BUY.......
How do I tell it to continue with the next OrderSend command if the previous one fails?

When one of the orders fails it spits out an error but then doesn't try the next order
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #458 (permalink)  
Old 10-15-2008, 12:13 AM
matrixebiz's Avatar
Senior Member
 
Join Date: Oct 2006
Posts: 1,174
matrixebiz is on a distinguished road
If I have many OrderSend functions in a row like so;
Ticket = OrderSend(sym1b, OP_BUY........
OrderSend(sym2b, OP_BUY.......
OrderSend(sym3b, OP_BUY.......
OrderSend(sym4b, OP_BUY.......
How do I tell it to continue with the next OrderSend command if the previous one fails?

When one of the orders fails it spits out an error but then doesn't try the next order
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #459 (permalink)  
Old 10-17-2008, 12:16 PM
Junior Member
 
Join Date: Dec 2007
Posts: 6
thomasblaesi is on a distinguished road
Stochastic Level

Hi,

in the code of Stochastic i want to build in a Sound if reched the 20% oder 80% Level.
How can i get the Price of this both levels in the code?

Thanks
Thomas
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #460 (permalink)  
Old 10-18-2008, 06:45 AM
Senior Member
 
Join Date: Nov 2006
Posts: 215
luxinterior is on a distinguished road
Look in the help file at the iStochastic function

Lux
__________________
Build An Expert Advisor. FREE E-course As Seen On TV
ForexArea.com
Users of Gap Trader from 'Forex-Assistant' MUST Read This
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Bookmarks

Tags
automated close order, close, eas, forex, learn mql4, learn mql4 video, mql4 learning, OrderCloseBy, profit, reach, secure profit function, T101_v1.11_orest_IBFXm.mq4, learning mql4

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Learning Cycles For New Traders Dan7974 General Discussion 350 01-18-2008 07:04 PM
Learning to code for autotrading GoatT Metatrader Programming 8 01-10-2007 09:55 PM
Self learning expert mrtools Expert Advisors - Metatrader 4 32 10-22-2006 06:29 PM


All times are GMT. The time now is 12:28 PM.



Search Engine Friendly URLs by vBSEO 3.2.0 ©2008, Crawlability, Inc.