Ronen --
Yes.
Most of the metrics you want are not displayed by Back Test, but by Optimize. But that's Ok.

I just tried this with only two symbols:
run = Optimize("Runs", 1, 1, 2, 1); // make max the number of stocks you wish to test
if((Name() == "QLD" AND run == 1)
    OR (Name() == "QID" AND run == 2)){
// your code goes here
}else Buy = Sell = Short = Cover = 0;

If you have only a few stocks to test this way, you can just type in the code for each stock. However, if you have very many, then make a symbol list using Scan or Explore and export to a spread sheet and/or a good code editor to help generate the code. Then Optimize, and after it finishes, export the results and merge with your numbered list to include the names with your results.

Hope this helps.
-- Keith

On 8/31/2010 18:52, Ronen wrote:

Is there a way to backtest a group of stocks, each individually, and then get that stats for each stock (i.e. Sharpe, win%, Loss%, #trades)?

For example, if my backtest period is 5 years, run the backtest for stock A for the 5 year period, calculate the stats and then move to stock B. So, in other words, I would would see how successful a strategy was for each stock in my universe. Otherwise I would have to manually run the backtest on stock A, mark down the statistics by hand and then run the test on stock B etc...


Reply via email to