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

Notification

Icon
Error

Options
Go to last post Go to first unread
Andy144  
#1 Posted : Friday, March 3, 2006 8:56:56 AM(UTC)
Andy144

Rank: Member

Groups: Registered, Registered Users
Joined: 10/1/2005(UTC)
Posts: 13

Hi, First Of all I do not know if this is possible within metastock but this is what I want to do. part 1. For use in a stop formula which is a modified timed stop. Can I plot on the chart only after a certain date? I want to input entry date on a daily chart and initial stop loss price. Part 2 Can you count the bars since entry to use in the stop formula (from entry date) The one thing I do not want to do is have it start from Nth expression because my entrys are not always at the exact signal and are usually after a additional confirmation. I also want to have it work in real time. If one of the forum experts could point me in the right direction it would be greatly appreaciated and i will post the formula if it works how I expect. Thanks Andrew
mstt  
#2 Posted : Friday, March 3, 2006 8:03:08 PM(UTC)
mstt

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 7/25/2005(UTC)
Posts: 1,042

Was thanked: 57 time(s) in 54 post(s)
Andrew I think MetaStock can do everything you ask. Whether you can can get a handle on the different techniques reqired is another matter. This is not a put-down but a simple observation that it takes more than a few answers to questions on a forum to be come skilled in MetaStock. A properly functioning timed exit (on that ignores secondary entry signals) requires a PREV-based latch. This device counts the bars since entry to determine the exit point. {Timed Trade Exit} D:=25; {trade length in bars} N:=Fml("Entry Signal"); {entry} X:=0; {independant exit signal} Tr:=If(PREV<=0,N, {set with entry signal} If( X {independant exit} OR BarsSince(PREV=0)>=D, {bars since entry} {OR any other entry related exit} -1 {negative spike signals exit}, 1)); {or trade continues} X:=Tr<0; {exit bar} X; This is one form of the basic structure you will need for an on-chart stop. The System Tester can use the Simulation function for timing trades but that function is not available to other tools. Plotting a signal only from a certain point is easy if you can define that starting point ValueWhen(1, Cum("start signal")>0, "my plot"); A "date filter" formula might be helpful in this respect. The Date Range function from the Forum dll might be useful here also. Hope this gives you something to work on. Roy MetaStock Tips & Tools
Andy144  
#3 Posted : Friday, March 3, 2006 9:13:06 PM(UTC)
Andy144

Rank: Member

Groups: Registered, Registered Users
Joined: 10/1/2005(UTC)
Posts: 13

Thanks Roy I will give this a look on the weekend and see If I can get a handle on it. Your right I would not consider myself skilled in metastock code but still learning and hoping to get there. Thanks again Andrew
Users browsing this topic
Guest (Hidden)
Similar Topics
Formula help for Exploration (Formula Assistance)
by SAINI9466637986 12/24/2023 5:53:23 AM(UTC)
Formula Help please for specific ROC to Highest high (Formula Assistance)
by rjr27 3/21/2012 7:30:45 AM(UTC)
% change formula help needed (Formula Assistance)
by Damuzzdu 12/20/2008 7:05:22 PM(UTC)
Scalping formula help [RESOLVED] (Formula Assistance)
by joshcr 6/19/2006 7:08:02 PM(UTC)
Formula Help for a beginner [RESOLVED] (Formula Assistance)
by kadip 10/12/2005 9:44:12 PM(UTC)
Formula help on volume needed (Formula Assistance)
by CN001532 9/18/2005 2:24:03 AM(UTC)
Fourier Indicator or formula help (Formula Assistance)
by jrsnell 7/1/2005 3:08:52 AM(UTC)
FORMULA HELP (Formula Assistance)
by RUAGOODP 5/31/2005 10:57:19 AM(UTC)
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.