logo
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

3 Pages<123>
Options
Go to last post Go to first unread
jjstein  
#21 Posted : Saturday, March 17, 2012 5:51:47 PM(UTC)
jjstein

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 5/13/2005(UTC)
Posts: 715
Location: Midwest, USA

Was thanked: 1 time(s) in 1 post(s)
This new indicator calls the original formula; it only plots +1, 0 or -1. It does not matter if the original is on the chart or not:

Code:

_Test Signal

FmlVar("_Test","Signal");


It looks like this:
UserPostedImage

indexarb  
#22 Posted : Sunday, March 18, 2012 2:05:40 AM(UTC)
indexarb

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 3/12/2012(UTC)
Posts: 44

works great final one for the weekend... how would i optimise the inputs? thanks mehul
jjstein  
#23 Posted : Sunday, March 18, 2012 11:21:45 AM(UTC)
jjstein

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 5/13/2005(UTC)
Posts: 715
Location: Midwest, USA

Was thanked: 1 time(s) in 1 post(s)
The simple answer is: Copy the code over to the System Tester, and replace all INPUT statements with OPTx variables.

The better answer is: If you do not understand the concepts of "curve-fitting", "in sample" and "out of sample", optimizing is hazardous to your fnancial health.

By "hazardous", I mean like a naked, blind man learning to juggle flaming torches while standing in a pool of gasoline, surrounded by dynamite.

So, go ahead and play with it, satisfy your curiosity, get it out of your system, BUT recognize that just because the software has an "optimize" feature (as do many others), does not turn it into a magical money-making machine, nor will it catch errors of ignorance on your part.

henry1224  
#24 Posted : Monday, March 19, 2012 6:14:49 AM(UTC)
henry1224

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 10/29/2004(UTC)
Posts: 1,394
Location: Glastonbury, CT

Was thanked: 2 time(s) in 2 post(s)
UserPostedImage

this indicator still needs to be filtered with a true trend filter
jjstein  
#25 Posted : Monday, March 19, 2012 9:23:14 AM(UTC)
jjstein

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 5/13/2005(UTC)
Posts: 715
Location: Midwest, USA

Was thanked: 1 time(s) in 1 post(s)
Hi Henry,

Did you use the code I posted? If so, what settings did you use?

VSTpro showed a negative P/R ratio...

henry1224  
#26 Posted : Monday, March 19, 2012 9:35:28 AM(UTC)
henry1224

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 10/29/2004(UTC)
Posts: 1,394
Location: Glastonbury, CT

Was thanked: 2 time(s) in 2 post(s)
Johnathan,

For a long position

My entry was Season=1
My exit was Season<>1

The trender code really needs some sort of trend filter to eliminate trades against the major trend.

a long ,short system has too many whipsaws

A long with uptrend, short with downtrend else out would seem to produce better results
henry1224  
#27 Posted : Monday, March 19, 2012 9:43:12 AM(UTC)
henry1224

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 10/29/2004(UTC)
Posts: 1,394
Location: Glastonbury, CT

Was thanked: 2 time(s) in 2 post(s)
UserPostedImage

If we are able to eliminate the long entries during a downtrend and eliminate the short entries from uptrends , the profits should increase

UserPostedImage

This uses the MTF as a filter
indexarb  
#28 Posted : Wednesday, March 21, 2012 7:54:14 AM(UTC)
indexarb

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 3/12/2012(UTC)
Posts: 44

thanks your your help with the indicator so far was wondering if i could ask some more ... would it be possible to apply it to 3 time frames on averages on once chart, as currently on intraday data it gets "chopped out" of trades when volatility drops. in other words have the indicator look at 1 5 10 min signals and come up with a net indicator which again would be a + or - 1 so if the 1 min signal is +1 5 min signal is -1 10 min signal is +1 the net overall signal is +1 or perhaps same with 3 different sets of paramaters withing the indicator, short medium and longer term? thanks again
henry1224  
#29 Posted : Wednesday, March 21, 2012 8:22:47 AM(UTC)
henry1224

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 10/29/2004(UTC)
Posts: 1,394
Location: Glastonbury, CT

Was thanked: 2 time(s) in 2 post(s)
Dear Indexarb,

you realize that this indicator is just an adjusted MA! It doesn't account anything towards trend

[code] {_Test} Pds:=Input("Period",2,50,10); Sensitivity:=Input("Std Dev",.5,5,1); UseClose:=Input("Use Close",0,1,0); maMP:=mov(mp(),Pds,e); maATR:=mov(ATR(1),Pds,e); ADM:=maMP-maATR/2+Stdev(maATR,Pds)*Sensitivity; Entry:=if(UseClose,Close>ADM,High>ADM); Exit:=if(UseClose,ADM>Close,ADM>Low); { CLEAN - REMOVE REDUNDANT SIGNAL, 1=Buy -1=Sell } Signal:=Cum(IsDefined(entry+exit))=1; { Enough data ? } Signal:=ValueWhen(1,entry-exit<>0 OR Signal,entry); { Current } entry:=Signal*(Alert(Signal=0,2) OR entry*Cum(entry)=1); { Current or 1st } exit:=(Signal=0)*(Alert(Signal,2) OR exit*Cum(exit)=1); { Current or 1st } entry:=(exit=0)*entry; { favor EXIT } Signal:=Entry-Exit; { Signal } Season:=ValueWhen(1,Signal<>0,Entry)*2-1; { Signal active } { PLOT } ADM; *code/* tell me where you would start to retrofit this code? ps I gave you a hint!
wabbit  
#30 Posted : Wednesday, March 21, 2012 9:32:03 AM(UTC)
wabbit

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers, Unverified Users
Joined: 10/28/2004(UTC)
Posts: 3,111
Location: Perth, Western Australia

Was thanked: 16 time(s) in 16 post(s)
I just don't think the code matches the intention in the Trender.pdf as uploaded??

The documents shows the result is a stepwise function, so is going to require a fistful of PREVs to deal with the long and short swings.

As for adding a trend-filter to a trend-filter; doesn't that defeat the purpose?



I need sleep. G'night.



wabbit [:D]

wabbit attached the following image(s):
steps.jpg
indexarb  
#31 Posted : Wednesday, March 21, 2012 9:45:02 AM(UTC)
indexarb

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 3/12/2012(UTC)
Posts: 44

Hi in general the indicator works in fast moving markets, however as the markets get less volotice it begins to produce false signals. ideally i would like a 3 time frame version and follow what 2 of the 3 signal. or to add a condition that says only change signal if the current indicator says change signal AND the security has moved at least "X" points since the last bar. points = ticks as i am using intra day thanks
henry1224  
#32 Posted : Wednesday, March 21, 2012 9:50:13 AM(UTC)
henry1224

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 10/29/2004(UTC)
Posts: 1,394
Location: Glastonbury, CT

Was thanked: 2 time(s) in 2 post(s)
for a long trend it would be Max(trend,ref(trend,-1));
for a short trend it would be Min(trend,ref(trend,-1));

now he has to define what trend is?
wabbit  
#33 Posted : Wednesday, March 21, 2012 9:57:18 AM(UTC)
wabbit

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers, Unverified Users
Joined: 10/28/2004(UTC)
Posts: 3,111
Location: Perth, Western Australia

Was thanked: 16 time(s) in 16 post(s)
indexarb wrote:
ideally i would like a 3 time frame version and follow what 2 of the 3 signal
I'd like a new car but that isn't going to happen without actually doing some work to go and pay for it. So far, I've seen jj and Henry doing all the work. Other than making requests for functionality, where's your coded input? I certainly hope you're sharing any profits of this system with them? wabbit [:D]
henry1224  
#34 Posted : Wednesday, March 21, 2012 10:05:33 AM(UTC)
henry1224

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 10/29/2004(UTC)
Posts: 1,394
Location: Glastonbury, CT

Was thanked: 2 time(s) in 2 post(s)
indexarb, I really believe that this is what you are looking for

http://forum.equis.com/forums/thread/1066.aspx

Kase Dev Stop
henry1224  
#35 Posted : Wednesday, March 21, 2012 10:11:46 AM(UTC)
henry1224

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 10/29/2004(UTC)
Posts: 1,394
Location: Glastonbury, CT

Was thanked: 2 time(s) in 2 post(s)
Wabbit

[code] I certainly hope you're sharing any profits of this system with them? *code/* from the charts posted below, there are no profits to be made!!!
indexarb  
#36 Posted : Wednesday, March 21, 2012 10:40:33 AM(UTC)
indexarb

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 3/12/2012(UTC)
Posts: 44

Thank you, you think better to use independently or with the current indicator? as for Wabbit ... if i can get this to work id be happy to throw a big party to which your all invited. im trying to figure coding out but 3 weeks into a 4 week trial its hard to learn !!!
henry1224  
#37 Posted : Wednesday, March 21, 2012 4:19:44 PM(UTC)
henry1224

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 10/29/2004(UTC)
Posts: 1,394
Location: Glastonbury, CT

Was thanked: 2 time(s) in 2 post(s)
indexarb,

The kase dev stop is more of what you are looking for.
it gives you 6 levels of stops. For more info you can read Trading With the Odds by Cynthia Kase

[code] Per1:=Input("max length",10,100,30); RWH:=(H-Ref(L,-Per1))/(ATR(Per1)*Sqrt(Per1)); RWL:=(Ref(H,-Per1)-L)/(ATR(Per1)*Sqrt(Per1)); Pk:=Mov((RWH-RWL),3,W); {you can change this if your indicator is long} AVTR:=Mov(HHV(H,2) - LLV(L,2),20, S); SD:=Stdev(HHV(H,2) - LLV(L,2),20); Val6:=If(Pk>0,HHV(H-AVTR-(4*SD),20),LLV(L+AVTR+(4*SD),20)); Val5:=If(Pk>0,HHV(H-AVTR-(3*SD),20),LLV(L+AVTR+(3*SD),20)); Val4:=If(Pk>0,HHV(H-AVTR-(2*SD),20),LLV(L+AVTR+(2*SD),20)); Val3:=If(Pk>0,HHV(H-AVTR-SD,20),LLV(L+AVTR+SD,20)); Val2:=If(Pk>0,HHV(H-AVTR,20),LLV(L+AVTR,20)); Val1:=If(Pk>0,HHV(H-AVTR+SD,20),LLV(L+AVTR-SD,20)); Val6;Val5;Val4;Val3;Val2;Val1;
henry1224  
#38 Posted : Wednesday, March 21, 2012 4:32:38 PM(UTC)
henry1224

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 10/29/2004(UTC)
Posts: 1,394
Location: Glastonbury, CT

Was thanked: 2 time(s) in 2 post(s)
Indexarb, now that you have tried Metastock for 3 weeks,I would think that you have made up your mind. You have been asking questions and they have been answered by members who have used Metastock for over 5 years and longer.

Your level of comfort will take more than a few weeks! This forum has answered every possible question ever asked, you just have to do a search of the forum.

What other software were you thinking about?
Many traders have more than one charting software.

jjstein  
#39 Posted : Wednesday, March 21, 2012 4:43:29 PM(UTC)
jjstein

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 5/13/2005(UTC)
Posts: 715
Location: Midwest, USA

Was thanked: 1 time(s) in 1 post(s)
henry1224 wrote:
The kase dev stop is more of what you are looking for.
it gives you 6 levels of stops.


HOLY MACKEREL -- six (6) levels! What's the reasoning behind that? Done any testing?

wabbit  
#40 Posted : Wednesday, March 21, 2012 6:27:14 PM(UTC)
wabbit

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers, Unverified Users
Joined: 10/28/2004(UTC)
Posts: 3,111
Location: Perth, Western Australia

Was thanked: 16 time(s) in 16 post(s)
henry1224 wrote:
Your level of comfort will take more than a few weeks!

Most users start with something simple for their programming project then build up to larger more complex beasts, but in this case the OP has started his "learning to swim" with an attempt at crossing the English Channel!

henry1224 wrote:
This forum has answered every possible question ever asked, you just have to do a search of the forum.

Yes, the Forum search function has it's problems, which Equis assure me they are trying to sort out, but even when the Forum search function isn't working one can still use Google with good results by limiting the scope of the search by including with the criteria:
site:forum.equis.com

henry1224 wrote:
Many traders have more than one charting software.

When the only tool you own is a hammer, then eventually everything looks like a nail!

MS is not the be-all and end-all of charting applications, just as MetaTrader4/5, NinjaTrader, TradeStation and AmiBroker aren't either. If we exploit the capabilities and avoid the limitations of each package then we find ourselves in a better place for making trading decisions.



wabbit [:D]

Users browsing this topic
Guest (Hidden)
3 Pages<123>
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.