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

Re: Confused with Optimization results



PureBytes Links

Trading Reference Links

Tomasz, thank you for the formulas which cleared up most of my 
confusion. 

As for your comment about my system being out of the market for most 
of the time, that is not quite the case. I had AB just do the 
optimization on a specific time period during which I intended to be 
fully (100%) invested in a basket of 20 to 40 stocks selected from a 
study group of 600. The goals was to be fully invested in the best 3% 
to 8% of the stocks. Thus all the bars of the selected stocks 
were "in the market" for the whole time (and of course all the bars 
of the non selected stocks were "out of the market" for the whole 
time). The exposure was so low because AB included the bars of the 
non-selected stocks when producing this report. A similar result 
occurs for the Net%Profit column. Is there any way to have AB 
calculate Exposure, and by extension RAR, in such cases where one 
intends to be 100% invested in a small subset of stocks studied in an 
optimation? If there is no way, it is not a major problem since 
other columns provide helpful data for determining the effectiveness 
of the variations on the strategy.

Thanks again for making a very powerful program.

b

--- In amibroker@xxxx, "Tomasz Janeczko" <amibroker@xxxx> wrote:
> Hello,
> 
> First, if your system is mostly out of the market (low Exposure) 
RAR values will be high because
> RAR is calculated from profit divided by the exposure. So the lower 
exposure is - the higher RAR you get.
> 
> 1. Average winning/ 2. average losing trade: The average of 
winning/losing trades (sum of winners/losers divided by a number of 
winning/losing trades) 1. (SumWinners/NumWinners) 2. 
(SumLosers/NumLosers) 
> 
> 
> 3. Exposure: Shows how much you are exposed to the market. It is a 
ratio of bars in the market divided by total number of bars under 
test. (The number of bars in the market is given by total number of 
bars minus bars out of the market) (BarsInMarket/TotalBarsInTest)
> 
> 4. Risk adjusted ann. return: Shows annual return of the system 
(*see note) adjusted (divided) by market exposure. If your system 
gained 10% over one year with the exposure of 50% the adjusted return 
would be 20% (10%/0.5) AnnualReturn/Exposure
> 
> 5. Ratio avg win/avg loss: The absolute value of the ratio of 
average winning trade to average losing trade abs( 
(SumWinners/NumWinners)/(SumLosers/NumLosers) )
> 
> Profit factor: The absolute value of the ratio of the profit of 
winners to loss of losers 
> 
> abs( SumWinners/SumLosers )
> 
> 
> Avg. trade (win & loss): The average trade profit calculated as sum 
of winners and losers divided by the number of trades. ( SumWinners + 
SumLosers )/( NumWinners + NumLosers )
> 
> Hope this helps.
> 
> Best regards,
> Tomasz Janeczko
> ===============
> AmiBroker - the comprehensive share manager.
> http://www.amibroker.com
> 
> ----- Original Message ----- 
> From: <b519b@xxxx>
> To: <amibroker@xxxx>
> Sent: Friday, November 16, 2001 5:53 PM
> Subject: [amibroker] Confused with Optimization results
> 
> 
> > To those with wiser heads than mine:
> > 
> > Up till now, I have had no difficulty interpreting optimization 
> > results, but my optimization has been fairly straight-forward 
since 
> > I just studied strategies on one stock at a time over years of 
buy 
> > and sell signals. For these studies, I found 4 columns on the 
> > optimization report most useful: Net%Profit and RAR along with a 
> > comparison of the #winners and #loosers columns. 
> > 
> > But now I am doing optimization in a new way and am very 
confused. 
> > Instead of testing 1 stock over multiple buy and sell periods, I 
am 
> > testing 600 stocks over a single buy period. The optimization 
steps 
> > are designed to segment the stocks into groups of about 60 each 
and 
> > report the results. I had hoped this would let me understand an 
> > interesting time period more fully and allow me to identify 
clusters 
> > of low risk with reasonable profits. However, some of the columns 
I 
> > used in the past seem to go crazy now. For example, the Net%
Profit 
> > column often reports 1% to 5% profitability even when the winners 
> > outnumber the looser trades and when the average gain colume 
reports 
> > a 25% average gain per trade. My guess is the 90% of the stocks 
that 
> > are not bought are including when calculating the Net%Profit. 
That 
> > also seems to be the case for the Exposure column which is often 
> > below 10%. And the RAR column will can give astronomically high 
> > numbers if the Exposure column is gets below 5%. In short, I know 
I 
> > should be looking at other columns -- unless there is an option 
to 
> > select that will exclude stocks not purchased when calculating 
the 
> > above columens. Is there such an option?
> > 
> > So I am looking at other columns instead. Am I on the right track 
to 
> > be concentrating on the following columns and is my interpreation 
of 
> > them correct. I have read the AB documentation, but I still have 
> > some questions: 
> > 
> > 1. AvgWin/AvgLoss column: This I assume divides the avg gain in 
> > dollars by the average loss in dollars. 
> > 
> > 2. #winners and #loosers: I look at the ratio between these two.
> > 
> > 3. Avg Trade: This column appears to give the average PROFIT in 
> > DOLLARS for all the trades. Since I would find a percentage 
number 
> > to be more understandable, I set the Initial Equity to 100 on the 
> > system settings screen. But does this affect the results if a 
> > stock's price is 51$? In such a case, does AB buy 1.98 shares or 
> > just 1 share? Am I misleading myself by trying to get this column 
to 
> > give percentage results.
> > 
> > 4. Profit factor: This appears to combine the results of the 
> > AvgWin/AvgLoss column with the ratio of #winners to #loosers. If 
my 
> > interpretation is correct, this is a very useful column since it 
> > gives an idea of the system's profit to risk characteristics. 
> > However, it sometimes gives no results if there happen to be no 
> > loosing stocks in an optimization step. 
> > 
> > Am I looking at the right columns? Am I misinterpreting any?
> > 
> > Thanks in advance for any comments.
> > 
> > b
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > Your use of Yahoo! Groups is subject to 
http://docs.yahoo.com/info/terms/ 
> > 
> > 
> >