PureBytes Links
Trading Reference Links
|
Steve
> I know this has been covered B4, but having searched the archives 4
> 'storing open' I couldn't find the relevant question which is... in MS
> 7.x EOD, how can U store the open on the day that U open a trade.
>
> 'Valuewhen' isn't available in 7.x but I'm sure Henry or Roy have
> answered this question B4. Unfortunately I forgot 2 archive the answer.
> :~{ I just want 2 set up an indicator 2 tell me when a trade has been
> 10% successful so far, so need 2 compare the current low 2 the open on
> the start of the trade.
You can actually use ValueWhen() in 7.2, but it's not a great idea because a second entry signal
before your exit target is met results in the ValueWhen() stored value being set to a new (unwanted)
level.
The best way to manage an exit based on an entry price or entry-derived value is to use a PREV based
latch. A PREV latch can either store the value directly, or to reduce the minimum number of PREVs
from three to two you can store binary values zero and one (minus one is optional). How that works
is a ValueWhen() follows the latch to pick up the entry price to plot for following code.
The beauty of a PREV based latch is that the exits can be entry related or independent of the entry,
users choice. The example that follows doesn't have an independent exit, but it has a 20% gain and
10% loss exit. There are any number of ways this can be configured, but remember that each entry
related exit requires another PREV.
EnterLong:=Cross(Mov(C,15,E),Mov(C,25,E));
CloseLong:=0;
Trade:=If(PREV<=0,EnterLong, {entry}
If(C>=ValueWhen(1,PREV=0,O)*1.2 OR {exit}
C<=ValueWhen(1,PREV=0,O)*0.9 OR {exit}
CloseLong {exit} ,-1,1));
Trade<0; {latch reset}
Abs(Trade)*ValueWhen(1,Trade+Alert(Trade=0,2)=2,O);
Hope this helps some.
Roy
------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/zMEolB/TM
--------------------------------------------------------------------~->
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/Metastockusers/
<*> To unsubscribe from this group, send an email to:
Metastockusers-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|