[Fwd: Re: Re: [R-sig-finance] bid-ask bouse]

Adrian Trapletti adrian.trapletti at swiss-systematic.com
Thu Dec 30 18:53:14 CET 2004


This time not as html
Adrian

-------- Original Message --------
Subject: 	Re: Re: [R-sig-finance] bid-ask bouse
Date: 	Wed, 29 Dec 2004 17:16:05 +0100
From: 	Adrian Trapletti <a.trapletti at bluewin.ch>
To: 	Joe Cerniglia <cj5815 at yahoo.com>
CC: 	r-sig-finance at stat.math.ethz.ch
References: 	<200412291140.iBTBcnek014626 at hypatia.math.ethz.ch>




>Message: 2
>Date: Tue, 28 Dec 2004 14:34:03 -0500
>From: David Kane <dave at kanecap.com>
>Subject: Re: [R-sig-finance] bid-ask bouse
>To: Joe Cerniglia <cj5815 at yahoo.com>
>Cc: r-sig-finance at stat.math.ethz.ch
>Message-ID: <16849.46379.161253.806415 at gargle.gargle.HOWL>
>Content-Type: text/plain; charset=us-ascii
>
>I am not sure if this is the appropriate list for your question, but,
>since I don't know a better list, here are my thoughts.
>
>1) In order to provide a decent answer, we need to know *much* more
>about the strategy. Start by telling us the typical holding period,
>the universe of stocks included and the dates for the historical data.
>
>2) Replace "return" in your code with some measure of return adjusted
>for bid/ask spread. If you are using daily returns and a daily holding
>period (which probably wouldn't be such a great idea, but ignore that
>for now), you could just subtract the spread from the return for
>puchases while adding it to returns for shorts. Again, that has
>nothing to do with R, but seems reasonable enough.
>
>3) More sophisticated answers would involve measuring returns from
>offer to bid for buys and bid to offer for shorts. Again, it would be
>helpful to know precisely what sort of data you are working with.
>
>Best of luck. Although your question has nothing to do with R, you are
>wise to be using R for applied finance. There is no better tool.
>
>Dave Kane
>
>  
>
Some more comments based on my experience:

    * Accurate estimation of fill prices from observed prices is maybe
      the most difficult task when simulating trading systems.
    * Slippage (>= 0) is a function of market momentum, number of
      shares, time of the day, market depth, and more specific
      properties such as liquidity of the considered instrument.
    * Some of the above measures may not be observed, in particular no
      history is available, e.g., for market depth.
    * Fill price = signal price +/- slippage (+ for buy orders, - for
      sell orders)
    * Signal price = bid/ask price (bid for sell orders, ask for buy
      orders) at the time an order is generated by the system or trader
    * To get an accurate estimate of the slippage function, a history of
      real trades is necessary.
    * In cases no bid/ask history is available, the slippage function
      may be based on last traded prices.
    * Published bid/ask prices may only be advertising quotes and nobody
      might be willing to trade on those prices.
    * Some markets close trading of shares when limit down is reached.

For some instruments it is possible to come up with a relatively simple 
and accurate slippage function, but this really depends...

Best
Adrian

>Joe Cerniglia writes:
> > 
> > I am trying to test a strategy on small cap stocks in
> > R.  I am concerned that the bid-ask bounce is
> > contributed to the excess return generated by the
> > strategy.  How can I adjust the calculation of the
> > returns on my portfolio to account for the bid-ask
> > spread?
> > 
> > Joe
> > 
> > _______________________________________________
> > R-sig-finance at stat.math.ethz.ch mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-sig-finance
>
>
>
>  
>



-- 
Dr. Adrian Trapletti
Swiss-Systematic Asset Management AG
Militärstrasse 76
8004 Zürich
Switzerland

Phone :   +41 (0) 43 2433904
Fax :     +41 (0) 43 2433907
Mobile :  +41 (0) 76 3705631

Email :   adrian.trapletti at swiss-systematic.com
WWW :     www.swiss-systematic.com


This e-mail message (including any attachments) is confidential and may be privileged. It is intended solely for the use of the individual or entity named on this message. It is provided for informational purposes only and does not constitute an offer or invitation to subscribe for or purchase any services or products. Any form of disclosure, copying, modification or distribution is unauthorised. If you are not the intended recipient, you are requested to please notify the sender immediately and delete the message (including any attachments) from your computer system network. 

E-mail transmission cannot be guaranteed to be secure or error-free as information could be modified. We therefore do not accept responsibility or liability as to the completeness or accuracy of the information contained in this message or any attachments.



More information about the R-sig-finance mailing list