[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: MS: System test w/o "re-investment": How? and "System Testing"



PureBytes Links

Trading Reference Links

In response to both Tim Kruzel and Rudolf Stricker I suggest the use of
the indicator builder to implement your "system" and display your
cumulative profit (equity line) as part of that indicator. You will be
able to test for the high > close+0.5 points, and will be able to
implement a level stake investment.

Below is a simple example, which buys when the close crosses the 3 day
simple moving average, and sells when the high exceeds the previous day's
close by 0.5 points or more.
Each investment, uses a fixed amount, irregardless of previous results.

Note this is not a "real" system and I have made it profitable for
demonstration purposes by selling at 99% of the daily high. (If I could
tell which price is 99% of the daily high, I'd have retired by now)

For information, the quantity of shares bought, and the capital being used
is shown together with the cumulative profit line.

The expert picks up the "long" position and shows these bars in green as
well as displaying buy and sell arrows.

The attached gif file shows the result and the code is in the attached dta
files.

Best regards ... Martin

 rudolf stricker wrote:

> Using Metastock's System Test capabilities, I came across a problem:
> MS, as I understand it, is "re-investing" any money from a profitable
> trade in the next trade(s). So, imo, the result from every single
> trade is  weighted with the results from any trade following vs. time.
> This way, there is  a totally uncontrollable and unpredictable
> immanent weighting mechanism, which imo prevents any reliable rating
> for a sequence of trades, because the rating for every trade is
> different as  it depends from the results of the various trades.
>
> Imo, there should be a capability for a _constant_ investment for
> every single trade, because this is the only way to do a reliable
> rating for a sequence of trades.
>
> So my question is: How can I set-up such a sequence of trades with a
> constant investment for every trade, using Metastock's SystemTest?
>
> Any help is welcome.
> mfg rudolf stricker
> | Disclaimer: The views of this user are strictly his own.

 Tim Kruzel wrote:

MetaStocker's,

There is a type of trading scenario that I would like to test for
in MetaStock. So far I have been unsuccessful in trying to do it.
If any of you out there have succeeded testing the following
scenario (with MetaStock or any other product) I would appreciate
hearing from you.

Imagine the following trade. At some price bar, a buy signal is
triggered and I enter the trade. The entry price is the CLOSE of that
bar. Now, I wish to exit the trade at the first instance that the stock
trades at CLOSE+1/2 (a half point of profit). To do this I must check
the HIGH of each subsequent bar. The CLOSING prices of the subsequent
bars may never achieve a value of CLOSE+1/2, but the HIGH of the very
next bar might very well achieve a value of CLOSE+1/2. As soon as the
HIGH exceeds CLOSE+1/2 I would exit the trade with 1/2 point profit.

The System Tester bundled with MetaStock does not allow for the above
type of scenario. The System Tester requires using the same price on
each bar for both entries and exits (i.e. CLOSE/CLOSE, OPEN/OPEN, etc.).
So, if the FUTURE CLOSES never get above the value of ENTRY CLOSE+1/2
then MetaStock would end up counting the trade as a looser (assuming
that some STOP would take you out). However, the trade may have
actually been a winner because some future HIGH did exceed the value
of CLOSE+1/2.

Because of this limitation in the MetaStock System Tester I have been
trying to program my own system tester using MetaStock's Expert Adviser
and the Indicator Builder programming language. However, due to the
archirecture of the MetaStock programming language it is impossible to
build a system tester for the case that the exit criteria is based
upon the entry criteria. (I have MetaStock support folks looking at
this, however, I am not optimistic.)

Here is a sketch of the trade I described above.

                     HIGH |
                          | <--- CLOSE + 1/2
                          |
                _|_       |
        CLOSE  |   |     _|_
               |   |    |   |
               |   |    |___|
               |___|      |       _|_
                 |       (2)     |   |
                (1)              |   |
                                 |___|
                                   |
                                  (3)

a) A trade is entered at the CLOSE of bar (1). The exit target price
   is CLOSE + 1/2

b) The HIGH of bar (2) exceeds the value of CLOSE + 1/2. The trade
   is exited and counted as profitable (profit of 1/2 point).

c) The MetaStock System Tester looks only at the closing prices of
   bars (2) and (3). The closing prices of bars (2) and (3) do not
   exceed CLOSE + 1/2. If the close of bar (3) triggers a STOP the
   trade is exited and accounted for as a loss.

One would not think that doing this should be very difficult, but so
far I have found it to be impossible.





Attachment Converted: "c:\eudora\attach\wow example.gif"

Attachment Converted: "c:\eudora\attach\Ms65form.dta"

Attachment Converted: "c:\eudora\attach\Ms65expt.dta"