Forex



Go Back   Forex Trading > Discussion Areas > Suggestions for Trading Systems
Forex Forum Register More recent Blogs Calendar Advertising Others Help






Register
Welcome to Forex-TSD!, one of the largest Forex forums worldwide, where you will be able to find the most complete and reliable Forex information imaginable.

From the list below, select the forum that you want to visit and register to post, as many times you want. It’s absolutely free. Click here for registering on Forex-TSD.

Exclusive Forum
The Exclusive Forum is the only paid section. Once you subscribe, you will get free access to real cutting-edge Trading Systems (automated and not), Indicators, Signals, Articles, etc., that will help and guide you, in ways that you could only imagine, with your Forex trading.
  • Elite Section
    Get access to private discussions, specialized support, indicators and trading systems reported every week.
  • Advanced Elite Section
    For professional traders, trading system developers and any other member who may need to use and/or convert, the most cutting-edge exclusive indicators and trading systems for MT4 and MT5.
See more

View Poll Results: Your trading timeframe
5 Mins 0 0%
10 Mins 0 0%
15 Mins 2 13.33%
30 Mins 6 40.00%
1 Hr 2 13.33%
4 Hrs 5 33.33%
Voters: 15. You may not vote on this poll

Reply
 
Thread Tools Display Modes
  #41 (permalink)  
Old 01-28-2006, 06:37 PM
Member
 
Join Date: Dec 2005
Posts: 58
techinvest is on a distinguished road
Getting my pivots to update at a different closing time.

Here's the indicator. Basicly all it is is a pivot point indicator which used fibonacci #'s to calculate support and resistance instead of the standard pivot calcs. Now, I can only seem to make it update at 00:00 GMT which is exactly what it's asked to do in the code, because I can't figure out a way to make it happen any other way. Check out line 132 as I'm pretty sure that's where you could use the LocalTime() variable to set a cutoff and make the pivot point and retracements/extentions update. I'd be greatful for any help. Thanks!!!

PHP Code:
//+------------------------------------------------------------------+
//|                                                   Pivot_Fibs.mq4 |
//|                            Copyright © 2006, Archer Trading, LLC |
//|                                    http://www.archertrading.net/ |
//+------------------------------------------------------------------+
#property copyright "Archer Trading, LLC"
#property link      "http://www.archertrading.net/"

#property indicator_chart_window
#property indicator_buffers 7
#property indicator_color1 White
#property indicator_color2 Lime
#property indicator_color3 Lime
#property indicator_color4 Yellow
#property indicator_color5 Yellow
#property indicator_color6 Red
#property indicator_color7 Red


double PBuffer[];
double S1Buffer[];
double R1Buffer[];
double S2Buffer[];
double R2Buffer[];
double S3Buffer[];
double R3Buffer[];
double S0Buffer[];
double R0Buffer[];
string Pivot="Pivot Point",FibS1="S 1"FibR1="R 1";
string FibS2="S 2"FibR2="R 2"FibS3="S 3"FibR3="R 3";
int fontsize=10;
double P,R,S1,R1,S2,R2,S3,R3;
double LastHigh,LastLow,x;

//+------------------------------------------------------------------+
//| Custor indicator deinitialization function                       |
//+------------------------------------------------------------------+
int deinit()
  {


   
ObjectDelete("Pivot");
   
ObjectDelete("FibS1");
   
ObjectDelete("FibR1");
   
ObjectDelete("FibS2");
   
ObjectDelete("FibR1");
   
ObjectDelete("FibS3");
   
ObjectDelete("FibR2");   

//----
   
return(0);
  }
//+------------------------------------------------------------------+
//| Custom indicator initialization function                         |
//+------------------------------------------------------------------+
int init()
  {
   
string short_name;


   
SetIndexStyle(0,DRAW_LINE,0,2,White);
   
SetIndexStyle(1,DRAW_LINE,0,2,Lime);
   
SetIndexStyle(2,DRAW_LINE,0,2,Lime);
   
SetIndexStyle(3,DRAW_LINE,0,2,Yellow);
   
SetIndexStyle(4,DRAW_LINE,0,2,Yellow);
   
SetIndexStyle(5,DRAW_LINE,0,2,Red);
   
SetIndexStyle(6,DRAW_LINE,0,2,Red);
   
SetIndexBuffer(0,PBuffer);
   
SetIndexBuffer(1,S1Buffer);
   
SetIndexBuffer(2,R1Buffer);
   
SetIndexBuffer(3,S2Buffer);
   
SetIndexBuffer(4,R2Buffer);
   
SetIndexBuffer(5,S3Buffer);
   
SetIndexBuffer(6,R3Buffer);


//---- name for DataWindow and indicator subwindow label
   
short_name="Fibonacci Pivot Points";
   
IndicatorShortName(short_name);
   
SetIndexLabel(0,short_name);

//----
   
SetIndexDrawBegin(0,1);
//----
 

//----
   
return(0);
  }

//+------------------------------------------------------------------+
//| Custom indicator iteration function                              |
//+------------------------------------------------------------------+
int start()

  {
   
int    counted_bars=IndicatorCounted();

   
int limiti;
//---- indicator calculation
if (counted_bars==0)
{
   
x=Period();
   if (
x>240) return(-1);
   
ObjectCreate("Pivot"OBJ_TEXT00,0);
   
ObjectSetText("Pivot""                 Pivot",fontsize,"Arial",White);
   
ObjectCreate("FibS1"OBJ_TEXT000);
   
ObjectSetText("FibS1""                  Fib S1",fontsize,"Arial",Lime);
   
ObjectCreate("FibR1"OBJ_TEXT000);
   
ObjectSetText("FibR1""                  Fib R1",fontsize,"Arial",Lime);
   
ObjectCreate("FibS2"OBJ_TEXT000);
   
ObjectSetText("FibS2""                  Fib S2",fontsize,"Arial",Yellow);
   
ObjectCreate("FibR2"OBJ_TEXT000);
   
ObjectSetText("FibR2""                  Fib R2",fontsize,"Arial",Yellow);
   
ObjectCreate("FibS3"OBJ_TEXT000);
   
ObjectSetText("FibS3""                  Fib S3",fontsize,"Arial",Red);
   
ObjectCreate("FibR3"OBJ_TEXT000);
   
ObjectSetText("FibR3""                  Fib R3",fontsize,"Arial",Red);
}
   if(
counted_bars<0) return(-1);
//---- last counted bar will be recounted
//   if(counted_bars>0) counted_bars--;
   
limit=(Bars-counted_bars)-1;



for (
i=limiti>=0;i--)


if (
High[i+1]>LastHighLastHigh=High[i+1];
if (
Low[i+1]<LastLowLastLow=Low[i+1];
if (
TimeDay(Time[i])!=TimeDay(Time[i+1]))
   { 
   
P=(LastHigh+LastLow+Close[i+1])/3;
   
LastHigh-LastLow;
   
R1 + (0.382);
   
S1 - (0.382);
   
R2 + (0.618);
   
S2 - (0.618);
   
R3 + (0.99);
   
S3 - (0.99);
   
LastLow=Open[i]; LastHigh=Open[i];

   
ObjectMove("Pivot"0Time[i],P);
   
ObjectMove("FibS1"0Time[i],S1);
   
ObjectMove("FibR1"0Time[i],R1);
   
ObjectMove("FibS2"0Time[i],S2);
   
ObjectMove("FibR2"0Time[i],R2);
   
ObjectMove("FibS3"0Time[i],S3);
   
ObjectMove("FibR3"0Time[i],R3);

   }
   
    
PBuffer[i]=P;
    
S1Buffer[i]=S1;
    
R1Buffer[i]=R1;
    
S2Buffer[i]=S2;
    
R2Buffer[i]=R2;
    
S3Buffer[i]=S3;
    
R3Buffer[i]=R3;
}

//----
   
return(0);
  }
//+------------------------------------------------------------------+ 
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #42 (permalink)  
Old 01-31-2006, 04:53 AM
ShadowWz's Avatar
Member
 
Join Date: Nov 2005
Posts: 94
ShadowWz is on a distinguished road
Talking Some indicators - modified

Hi,

a_ZZ and a_ZZInd - "High_Low v2 (ZigZag)" and others(wich i don't remember now,&))
aDin - "ang_PR (Din)-v2"

What do you think ?

Cheers.

Last edited by ShadowWz; 03-15-2006 at 05:48 AM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #43 (permalink)  
Old 02-02-2006, 11:52 AM
Kalenzo's Avatar
Senior Member
 
Join Date: Dec 2005
Location: Bydgoszcz - Poland
Posts: 724
Kalenzo is on a distinguished road
Coffie

I think the basic use of this indicator can be to provide enter/exit signals like on the screen. Enter on cross of lines, exit when shortSeed will make high/low. But mabye someone can tweak the idea of use of it? Mabye other Seed values will be better? I will be grateful for any comments. A litle feedback please
Attached Images
File Type: gif coffie.gif (15.7 KB, 1097 views)
Attached Files
File Type: mq4 Coffie_v1.mq4 (3.0 KB, 328 views)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #44 (permalink)  
Old 02-02-2006, 02:59 PM
Junior Member
 
Join Date: Jan 2006
Posts: 3
ray4498 is on a distinguished road
Stop loss for EA

Sorry for the above title, what I need is a take profit command. I have no idea how to code but would like to add a Take Profit to this ea. Below is the code please add take profit where necessary. Thanks again
Ray


extern double MaximumRisk =0.02; //%account balance to risk per position
extern double DecreaseFactor =3; //lot size divisor(reducer) during loss streak
extern double Lot.Margin =50; //Margin for 1 lot

extern int Magic =69;
extern string comment ="m icwr ea";

double spread; spread =Ask-Bid;
int slip; slip =spread/Point;

int RequiredWaveHeight,b,s,cnt,ticket;
double rsi,SL,ICWR,ICWRv0,awp1,awp2,active.high,active.lo w,high.c,high.r,low.r,low.c;
datetime awt1,awt2,a.high.shift,a.low.shift,shift;

int init(){return(0);}
int deinit(){return(0);}
int start(){

PosCounter();
rsi=iRSI(Symbol(),1440,14,PRICE_CLOSE,0);

if(Period()==5) {RequiredWaveHeight=40;SL=50*Point;}
if(Period()==240) {RequiredWaveHeight=150;SL=100*Point;}
ICWR=iCustom(Symbol(),Period(),"ICWR",10,5,3,Requi redWaveHeight,0,0);
ICWRv0=iCustom(Symbol(),Period(),"ICWR v0","ZigZag",10,5,3,"ActiveWave",50,RequiredWaveHe ight,0,0);

awt1=ObjectGet("Activewave",OBJPROP_TIME1);
awp1=ObjectGet("Activewave",OBJPROP_PRICE1);
awt2=ObjectGet("Activewave",OBJPROP_TIME2);
awp2=ObjectGet("Activewave",OBJPROP_PRICE2);

if(awp1>awp2) {
active.high=awp1;
a.high.shift=iBarShift(Symbol(),Period(),awt1);
active.low=awp2;
a.low.shift=iBarShift(Symbol(),Period(),awt2);}
else {
active.high=awp2;
a.high.shift=iBarShift(Symbol(),Period(),awt2);
active.low=awp1;
a.low.shift=iBarShift(Symbol(),Period(),awt1);}

if(a.high.shift<a.low.shift) shift=a.high.shift;
else shift=a.low.shift;

high.c=NormalizeDouble(active.low+((active.high-active.low)*0.75),Digits);
high.r=NormalizeDouble(active.low+((active.high-active.low)*0.618),Digits);
low.r=NormalizeDouble(active.low+((active.high-active.low)*0.382),Digits);
low.c=NormalizeDouble(active.low+((active.high-active.low)*0.25),Digits);

if(rsi>50) {
for(int i=0;i<shift;i++) {
if(Close[i]<high.r && Close[i]>low.r && Low[1]>high.c && b==0) {
ticket1=OrderSend(Symbol(),OP_SELL,1.0,Bid,0,Bid+2 0*Point,Bid-30*Point,"expert comment",255,0,CLR_NONE);
OP_BUY,
LotsOptimized(),
Ask,
slip,
Ask-SL,
0,
Period()+comment,
Magic,0,Blue);
if(ticket>0) {
if(OrderSelect(ticket,SELECT_BY_TICKET,MODE_TRADES ))
{ Print(ticket); }
else Print("Error Opening BuyStop Order: ",GetLastError());
return(0);}}}}

if(rsi<50) {
for(int ii=0;ii<shift;ii++) {
if(Close[ii]<high.r && Close[ii]>low.r && High[1]<low.c && s==0) {
ticket=OrderSend(Symbol(),
OP_SELL,
LotsOptimized(),
Bid,
slip,
Bid+SL,
0,
Period()+comment,
Magic,0,Orange);
if(ticket>0) {
if(OrderSelect(ticket,SELECT_BY_TICKET,MODE_TRADES ))
{ Print(ticket); }
else Print("Error Opening SellStop Order: ",GetLastError());
return(0);}}}}

if(b>0) {
for(int c=0;c<shift;c++) {
if(High[1]<low.c) {
OrderClose(ticket,OrderLots(),Bid,slip,0);}}}

if(s>0) {
for(int cc=0;cc<shift;cc++) {
if(Low[1]>high.c) {
OrderClose(ticket,OrderLots(),Ask,slip,0);}}}

comments();

return(0);}
//+---------------------------FUNCTIONS------------------------------+
void PosCounter() {
b=0;s=0;ticket=0;
for(cnt=0;cnt<=OrdersTotal();cnt++) {
OrderSelect(cnt, SELECT_BY_POS, MODE_TRADES);
if(OrderSymbol()==Symbol() && OrderMagicNumber()==Magic) {
if(OrderType()==OP_SELL) {
ticket=OrderTicket();
s++;}
if(OrderType()==OP_BUY) {
ticket=OrderTicket();
b++;} }}}

void comments() {

if(MarketInfo(Symbol(),MODE_SWAPLONG)>0) string swap="longs.";
else swap="shorts.";
if(MarketInfo(Symbol(),MODE_SWAPLONG)<0 && MarketInfo(Symbol(),MODE_SWAPSHORT)<0) swap="your broker. ";

Comment("Last Tick: ",TimeToStr(CurTime(),TIME_DATE|TIME_SECONDS),"\n" ,
"Swap favors ",swap,"\n",
"Daily RSI= ",rsi,"\n",
"Active High: ",active.high,"\n",
"High shift: ",a.high.shift,"\n",
"High Confirm: ",high.c,"\n",
"High Retrace: ",high.r,"\n",
"Low Retrace: ",low.r,"\n",
"Low Confirm: ",low.c,"\n",
"Active Low: ",active.low,"\n",
"Low shift: ",a.low.shift); }

double LotsOptimized() {
double lot;
int orders=HistoryTotal();
int losses=0;
lot=NormalizeDouble(AccountFreeMargin()*MaximumRis k/Lot.Margin,2);
if(DecreaseFactor>0) {
for(int i=orders-1;i>=0;i--) {
if(OrderSelect(i,SELECT_BY_POS,MODE_HISTORY)==fals e) { Print("Error in history!"); break; }
if(OrderSymbol()!=Symbol() || OrderType()>OP_SELL) continue;
if(OrderProfit()>0) break;
if(OrderProfit()<0) losses++; }
if(losses>1) lot=NormalizeDouble(lot-lot*losses/DecreaseFactor,2); }
if(lot<0.01) lot=0.01;
return(lot); }//end LotsOptimized

Last edited by ray4498; 02-02-2006 at 03:20 PM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #45 (permalink)  
Old 02-06-2006, 03:59 AM
SPACECHIMP's Avatar
Member
 
Join Date: Feb 2006
Location: West Michigan, USA.
Posts: 86
SPACECHIMP is on a distinguished road
nevermind...

Nevermind..somehow
i downloaded the TEMPLATE catfx and it all showed up...
I dunno

Last edited by SPACECHIMP; 02-06-2006 at 04:32 AM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #46 (permalink)  
Old 02-06-2006, 04:36 AM
SPACECHIMP's Avatar
Member
 
Join Date: Feb 2006
Location: West Michigan, USA.
Posts: 86
SPACECHIMP is on a distinguished road
quick question..what data INDinverse give you?

I have this graph but can't seem to decipher what info it tells me..
I did a Search but came up short on a description.



THANK U FOR UR SUPPORT
Attached Images
File Type: jpg ScreenHunter_1.jpg (14.4 KB, 1005 views)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #47 (permalink)  
Old 02-08-2006, 01:50 AM
Junior Member
 
Join Date: Jan 2006
Posts: 25
charliev is on a distinguished road
New chart disables EA?

Hello agian,

(This is such a great board, I'll have something to share soon!)

I'm playing around with CodersGuru's "Your First Expert Advisor" example from his MQL4 Course...

I've noticed something that I hope has a solution... After loading the EA on the 30M chart... it Opened a (Short) Order.. I had modified his code to test my Exit strategy (a simple cross on a lower time period)...

The cross came and went (and the printed status, and my code was correct) HOWEVER, I was on the 15M chart at the time... does this mean I de-activated the EA (so my code/logic didn't run)?

If so, is there anyway around this... I'd like to click back and forth to other timeframes... without disabling the EA that is running.

Thanks in advance for the replies.

-charliev
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #48 (permalink)  
Old 02-09-2006, 02:36 AM
TheShanghai's Avatar
Junior Member
 
Join Date: Dec 2005
Posts: 23
TheShanghai is on a distinguished road
System effectiveness proportional to its user growth?

Do you guys believe that a system would gain or lose its effectiveness along with an increasing number of people who apply it?
It seems that many successful traders do not usually share their trading strategies, so there must be a reason for them doing so. Anyone want to crack at this?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #49 (permalink)  
Old 02-09-2006, 08:23 AM
Administrator
 
Join Date: Sep 2005
Posts: 20,083
Blog Entries: 243
newdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud ofnewdigital has much to be proud of
Quote:
Originally Posted by TheShanghai
Do you guys believe that a system would gain or lose its effectiveness along with an increasing number of people who apply it?
It seems that many successful traders do not usually share their trading strategies, so there must be a reason for them doing so. Anyone want to crack at this?
I heard about this idea that many successful traders do not usually share their trading strategies or share some wrong strategies especially. May be. I do not know. Because the forex is money. I think it is nothing with this effectiveness. It is because not so many successful traders and it is something with brokers.

BTW, I think it is personal. One trader can use some trading strategy and I can not because of my character, habits, timezone etc. So it is personal. Anyway we may discover all the strategies as we are doing already here in the forum.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #50 (permalink)  
Old 02-09-2006, 11:28 AM
TheShanghai's Avatar
Junior Member
 
Join Date: Dec 2005
Posts: 23
TheShanghai is on a distinguished road
thank you for the feedback. I'll keep that in mind.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
Reply

Bookmarks

Tags
bartrader, Bartrader EA, bartrader forex, bartrader.ex4, black dog, close the trade, dtosc, dtosc indicator, DTOsc metastock, dtosc metatrader, dtosc mq4, Earlybird V1.ex4, hilbert, makegrid, merdekarama, Merdekarama Ea, Merdekrama, pyratool, raw ideas, reopen, simple verticle, skywalker, SpearmanRankCorr, Stealth Earlybird V1.ex4, systems, trading, v-tbv6


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
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
Looking for some Fresh Ideas Emerald King Metatrader 4 3 01-11-2007 08:30 PM
Mandarine: original request and ideas hellkas Digital Filters 33 11-04-2006 02:46 PM


All times are GMT. The time now is 05:29 PM.



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