gawdib
25th December 2003, 04:55 PM
in doing a system test in metastock, nothing will work unless something is put outside of things like aa:=lkjsdlfjasldfj;. one has to put then another aa for the program to actually do somehting. I cannot tell from your examples that you do anything like that. so why is something happening. how does it work compared to metastock? how are you able to get metastock to do something, when nothing is outside the := ;? or rather when does one use things outside the =; Ever? thank you
sectorbets
25th December 2003, 05:17 PM
Hi--
I've been reading your questions over the last day or two, and while I have the gist of what you are asking, I think the only way we all can respond to your questions is for you to supply the code you are trying to get working so we can look at it and then we can all address your issues directly rather than trying to figure out exactly what you are asking.
Good luck,
Rick
gawdib
26th December 2003, 04:03 AM
it is nothing specific. it is just that i do not feel sure I understand how you get things to work. I need the rules and principles , since it does not seem that tradesim always follows metastock rules for telling the program to get to work and follow commands.
I am used to being able to create formula back and forth easily between system test, experrts and explortions. An example might be the following:
x:= fml("candles") and
H>Mov(H,2,S) AND L>Mov(L,2,S) AND V>.9*Mov(V,10,S) AND LinRegSlope(Mov(C,12,S),2)>0 AND LinRegSlope(Mov(C,150,S),2)>.01;
state:=If(BarsSince(x)<BarsSince(
(C>1.017* ValueWhen(1,x,C) AND BarsSince(x)>61 AND LinRegSlope(Mov(C,18,S),2)<-.001) OR (C>1.11*ValueWhen(1,x,C) AND LinRegSlope(Mov(C,18,S),2)<-.001) OR (C>1.045* ValueWhen(1,x,C) AND BarsSince(x)>40 AND LinRegSlope(Mov(C,18,S),2)<-.001) OR (C<.98* ValueWhen(1,x,C) AND BarsSince(x)>22
AND LinRegSlope(Mov(C,18,S),2)<-.001) OR BarsSince(x)>60 OR C>1.2*ValueWhen(1,x,C)
),1,0) ;
state>Ref(state,-1) as you see, one has to leave offf the ;
The exit side, of course, would be state<Ref(state,-1) Thanks very much
David Samborsky
29th December 2003, 02:22 PM
it is nothing specific. it is just that i do not feel sure I understand how you get things to work. I need the rules and principles , since it does not seem that tradesim always follows metastock rules for telling the program to get to work and follow commands.
No it won't always match up with your expert or indicator. It doesn't know a good entry from a bad one unless you program this into the formula. Once the RecordTrades function enters into a trade any subsequent entry triggers are ignored until a valid ExitTrigger, Protective stop etc is detected. It is very important to understand this distinction as it is relevant to a real world trading scenario. Please carefully read the chapter "Generating trade data" in the TradeSim User Manual.
It is possble to create an expert or indicator which matches the trades written to the trade database. I don't want to confuse you too much at this stage but if you are interested I suggest you read document TB-1 for more information on how to this.
gawdib
30th December 2003, 03:53 AM
thanks david. i will reread these sections. geoffrey
vBulletin® v3.8.6, Copyright ©2000-2012, Jelsoft Enterprises Ltd.