Volume Weighed Average Price Opimal Execuion Enzo Bussei Sephen Boyd Sepember 28, 2015 Absrac We sudy he problem of opimal execuion of a rading order under Volume Weighed Average Price (VWAP) benchmark, from he poin of view of a risk-averse broker. The problem consiss in minimizing mean-variance of he slippage, wih quadraic ransacion coss. We devise muliple ways o solve i, in paricular we sudy how o incorporae he informaion coming from he marke during he schedule. Mos relaed works in he lieraure eschew he issue of imperfec knowledge of he oal marke volume. We insead incorporae i in our model. We validae our mehod wih exensive simulaion of order execuion on real NYSE marke daa. Our proposed soluion, using a simple model for marke volumes, reduces by 10% he VWAP deviaion RMSE of he sandard saic soluion (and can simulaneously reduce ransacion coss). 1 Inroducion Mos lieraure on opimal execuion focuses on he Implemenaion Shorfall (IS) objecive, minimizing he execuion price wih respec o he marke price a he momen he order is submied. The seminal papers [BL98], [AC01] and [OW05] derive he opimal schedule for various risk preferences and marke impac models. However mos volume on he sock markes is raded wih Volume Weighed Average Price (VWAP) orders, benchmarked o he average marke price during he execuion horizon [Mad02]. Using his benchmark makes he problem much more compelling from a sochasic conrol sandpoin and promps he developmen of a richer model for he marke dynamics. The problem of opimal rade scheduling for VWAP execuion has been sudied originally [Kon02] in a saic opimizaion seing (he schedule is fixed a he sar of he day). This is inuiively subopimal, since i ignores he new informaion coming as he schedule progresses. Some recen papers [HJ11] [MK12] [FW13] exend he model and incorporae he new informaion coming o he marke bu rely on he crucial assumpion ha he oal marke volume is known beforehand. Oher works [BDLF08] ake a differen roue and focus on he empirical modeling of he marke volumes. A recen paper [GR13] sudies he sochasic conrol problem including a marke impac erm, while he work by Li [Li13] akes a differen approach and sudies he opimal placemen of marke and limi orders for a VWAP objecive. Our approach maches in 1
complexiy he mos recen works in he lieraure ([FW13], [GR13]) wih a key addiion: we don assume ha he oal marke volume is known and insead rea i as a random variable. We also provide exensive empirical resuls o validae our work. We define he problem and all relevan variables in 2. In 3 we derive a saic opimal rading soluion. In 4 we develop a dynamic soluion which uses he informaion coming from he marke during he schedule in he bes possible way: as our esimae of he oal marke volume improves we opimize our rading aciviy accordingly. In 5 we deail he simulaions of rading we performed, on real NYSE marke daa, using our VWAP soluion algorihms. We conclude in 6. 2 Problem formulaion We consider, from he poin of view of a broker, he problem of execuing a rading order issued by a clien. The clien decides o rade C Z + shares of sock k over he course of a marke day. By assuming C > 0 we resric our analysis o buy orders. If we were insead ineresed in sell orders we would only need o change he appropriae signs. We don explore he reasons for he clien s order (i could be for rebalancing her porfolio, making new invesmens, ec.). The broker acceps he order and performs all he rades in he marke o fulfill i. The broker has freedom in implemening he order (can decide when o buy and in wha amoun) bu is consrained o cumulaively rade he amoun C over he course of he day. When he order is submied clien and broker agree on an execuion benchmark price which regulaes he compensaion of he broker and he sharing of risk. The broker is payed by he clien an amoun equal o he number of shares raded imes he execuion benchmark, plus fees (which we neglec). In urn, he broker pays for his rading aciviy in he marke. Some choices of benchmark prices are: sock price a he sar of he rading schedule. This gives rise o implemenaion shorfall execuion ([BL98], [AC01]), in which he clien akes no risk (since he benchmark price is fixed); sock price a day close. This ype of execuion can misalign he broker and clien objecives. The broker may ry o profi from his execuions by pushing he closing price up or down, using he marke impac of his rades; Volume Weighed Average Price (VWAP), he average sock price hroughou he day weighed by marke volumes. This is he mos common benchmark price. I encourages he broker o spread he execuion evenly across he marke day, minimizing marke impac and deecabiliy of he order. I assigns mos risk associaed wih marke price movemens o he clien, so ha he broker can focus exclusively on opimizing execuion. In his paper we derive algorihms for opimal execuion under he VWAP benchmark. 2
2.1 Definiions We work for simpliciy in discree ime. We consider a marke day for a given sock, spli in T inervals of he same lengh. In he following T is fixed o 390, so each inerval is one minue long. Volume We use he word volume o denoe an ineger number of raded shares (eiher by he marke as a whole or by a single agen). We define m R + for = 1,..., T, he number of shares of he sock raded by he whole marke in inerval, which is non-negaive. We noe ha in realiy he marke volumes m are ineger, no real numbers. This approximaion is accepable since he ypical number of shares raded is much greaer han 1 (if he inerval lengh is 1 minue or more) so he ineger rounding error is negligible. These marke volumes are disribued according o a join probabiliy disribuion f m1:t (m 1,..., m T ). In 5.2 we propose a model for his join disribuion. We also define he oal daily volume V = T =1 m We call u R + he number of shares of he sock ha our broker rades in inerval, for = 1,..., T. (Again we assume ha he volumes are large enough so he rounding error is negligible.) By regulaions hese mus be non-negaive, so ha all rades performed by he broker as par of he order have he same sign. Price Le p R ++ for = 1,..., T be he average marke price for he sock in inerval. This is defined as he VWAP of all rades over inerval. (If during inerval here are N > 0 rades in he marke, each one wih volume ω i Z ++ and price π i R ++, hen p = N i=1 ω iπ i / N i=1 ω i.) If here are no rades during inerval hen p is undefined and in pracice we se i equal o he las available period price. We model his price process as a geomeric random walk wih zero drif. The iniial price p 0 is a known consan. Then he price incremens η p p 1 p 1 for = 1,..., T are independen and disribued as η N (0, σ ), where N is he Gaussian disribuion. The period volailiies σ R + for = 1,..., T are consans known from he sar of he marke day. We define he marke VWAP price as p VWAP = T =1 m p. (1) V 3
Transacion coss We model he ransacion coss by inroducing he effecive price ˆp, defined so ha he whole cos of he rade a inerval is u ˆp. Our model capures insananeous ransacion coss, in paricular he cos of he bid-ask spread, no he cos of long-erm marke impac. (For a deailed lieraure review on ransacion coss and marke impac see [BFL09].) Le s R ++ be he average fracional (as raio of he sock price) bid-ask spread in period. We assume he broker rades he volume u using an opimized rading algorihm ha mixes opimally marke and limi orders. The cos or proceeding per share of a buy marke order is on average p (1 + s /2) while for a limi order i is on average p (1 s /2). Le u LO and u MO be he porions of u execued via limi orders and marke orders, respecively, so ha u LO + u MO = u. We require ha he algorihm uses rades of he same sign, so u LO, u MO, and u are all non-negaive (consisenly wih he consrain we inroduce in 2.3). We assume ha he fracion of marke orders over he raded volume is proporional o he paricipaion rae, defined as u /m. So u MO u = α 2 where he proporionaliy facor α R + depends on he specifics of he rading algorihm used. This is a reasonable assumpion, especially in he limi of small paricipaion rae. The whole cos or proceedings of he rade is which implies ( ( u ˆp = p u LO 1 s 2 u m ) + u MO ( ( ˆp = p 1 s 2 + αs 2 u m 1 + s 2 )) ). (2) We hus have a simple model for he effecive price ˆp, linear in u. This gives rise o quadraic ransacion coss, a reasonable approximaion for he sock markes ([BFL09], [LFM03]). 2.2 Problem objecive Consider he cash flow for he broker, equal o he paymen he receives from he clien minus he cos of rading T Cp VWAP u ˆp. In pracice here would also be fees bu we neglec hem. The rading indusry usually defines he slippage as he negaive of his cash flow. I represens he amoun by which he order execuion price misses he benchmark. (The choice of sign is convenional so ha he opimizaion problem consiss in minimizing i). We insead define he slippage as =1 S T =1 u ˆp Cp VWAP Cp VWAP, (3) 4
normalizing by he value of he order. We need his in order o compare he slippage beween differen orders. By subsiuing he expressions defined above we ge ( T ( S = [u p 1 s )] )/ 2 + αs u T =1 C m p Cp VWAP = 2 m =1 V T [ p ( u p =1 VWAP C m ) ] T ( p s + α u2 u ) V 2p =1 VWAP Cm C T 1 [ ( τ=1 η m τ τ=1 +1 u )] T ( τ s + α u2 u ) (4) V C 2 Cm C =1 where we used he wo approximaions (boh firs order, reasonable on a rading horizon of one day) p p 1 p p 1 = η (5) p VWAP p 1 p s s. (6) p VWAP We model he broker as a sandard risk-averse agen, so ha he objecive funcion is o minimize E S + λ var(s) for a given risk-aversion parameer λ 0. These expecaion and variance operaors apply o all sources of randomness in he sysem, i.e., he marke volumes m and marke prices p, which are independen under our model. The expeced value of he slippage is E m,p S = E m E p S = E m [ T =1 s 2 ( α u2 u Cm C =1 ) ] (7) since he price incremens have zero mean. Noe ha we leave expressed he expecaion over marke volumes. The variance of he slippage is [ ( ) ] 2 ( ) 2 var S = E S E S = E S 2 E S = m,p m,p m,p m,p m,p ( 2 E E S 2 E E S) E (E m p m p m p S)2 + E(E S) 2 = E var(s) + var (E S). (8) m p m p m p The firs erm is E var (S) = E E m p m p ( T 1 =1 η +1 ( τ=1 m V τ=1 u ) ) 2 = C 5 [ T 1 E m =1 σ 2 +1 ( τ=1 m τ=1 u ) 2 ] V C (9)
which follows from independence of he price incremen. The second erm is ( T ( var (E s S) = var α u2 u ) ). (10) m p m 2 Cm C =1 We drop he second erm and only keep he firs one, so ha he resuling opimizaion problem is racable. We moivae his by assuming, as in [FW13], ha he second erm of he variance is negligible when compared o he firs. This is validaed ex-pos 1 by our empirical sudies in 5. We hus ge T E S + λ var(s) m,p m,p =1 E m s 2 ( α u2 u ) + λσ 2 Cm C ( 1 τ=1 m V ) 1 τ=1 u 2. (11) C We noe ha he objecive funcion separaes in a sum of erms per each ime sep, a key feaure we will use o apply he dynamic programming opimizaion echniques in 4. 2.3 Consrains We consider he consrains ha apply o he opimizaion problem. The opimizaion variables are u for = 1,..., T. We require ha he execued volumes sum o he oal order size C T u = C. (12) We hen impose ha all rades have posiive sign (buys) =1 u 0, = 1,..., T. (13) (If we were execuing a sell order, C < 0, we would have all u 0.) This is a regulaory requiremen for insiuional brokers in mos markes, essenially as a precauion agains marke manipulaion. I is a sandard consrain in he lieraure abou VWAP execuion. 2.4 Opimizaion paradigm The price incremens η and marke volumes m are sochasic. The volumes u insead are chosen as he soluion of an opimizaion problem. This problem can be cas in several differen ways. We define he informaion se I available a ime I {(p 1, m 1, u 1 ),..., (p 1, m 1, u 1 )}. (14) 1 In he res of he paper we derive muliple ways o solve he opimizaion problem of minimizing he objecive (11). For hese differen soluion mehods, he empirical value of (10) is beween 1% and 5% of he value of (9), so our approximaion is valid. The resuls are deailed in 5.6. 6
By causaliy, we know ha when we choose he value of u we can use, a mos, he informaion conained in I. In 3 we formulae he opimizaion problem and provide an opimal soluion for he variables u in he case we do no access anyhing from he informaion se I when choosing u. The u are chosen using only informaion available before he rading sars. We call his a saic soluion (or open loop in he language of conrol). In 4 insead we develop an opimal policy which can be seen as a sequence of funcions ψ of he informaion se available a ime u = ψ (I ). We develop i in he framework on dynamic programming and we call i dynamic soluion (or closed loop). 3 Saic soluion We consider a procedure o solve he problem described in 2 wihou accessing he informaion ses I. We call his soluion saic since i is fixed a he sar of he rading period. (I is compued using only informaion available before he rading sars.) This is he same assumpion of [Kon02] and corresponds o he approach used by many praciioners. Our model is however more flexible han [Kon02], i incorporaes variable bid-ask spread and a sophisicaed ransacion cos model. Sill, i has an exremely simple numericaly soluion ha leverages convex opimizaion [BV09] heory and sofware. We sar by he opimizaion problem wih objecive funcion (11) and he wo consrains (12) and (13) minimize u E m,p S + λ var m,p (S) s.. T =1 u = C u 0, = 1,..., T. We remove a consan erm from he objecive and wrie he problem in he equivalen form [ ( ( 1 ) )] 2 minimize T s u =1 2C (αu2 κ u ) + λσ 2 1 τ=1 u C 2M τ=1 u C s.. T =1 u (15) = C u 0, = 1,..., T where M and κ are he consans [ 1 ] τ=1 M = E m [ ] 1, κ = E m V m m for = 1,..., T. In his form, he problem is a sandard quadraic program [BV09] and can be solved efficienly by open-source solvers such as ECOS [DCB13] using a symbolic convex opimizaion suie like CVX [GB14] or CVXPY [DCB14]. 7
3.1 Consan spread We consider he special case of consan spread, s 1 = = s T, which leads o a grea simplificaion of he soluion. The convex problem (15) has he form ( minimize T T ) s u =1 2C (αu2 κ u ) + λ =1 σ2 (U 2 2M U /C) φ(u) + λψ(u) s.. u C where U = 1 τ=1 u /C for each = 1,..., T, and C is he convex feasible se. We separae he problem ino wo subproblems considering each of he wo erms of he objecive. The firs one is minimize u φ(u) s.. u C which is equivalen o (since he spread is consan and α > 0) minimize u s.. T =1 u2 κ u C The opimal soluion is ([BV09], Lagrange dualiy) u = C 1/κ T =1 1/κ, = 1,..., T. We approximae κ = E m [1/m ] 1/E m [m ] and hus The second problem is u C E m[m ] T =1 E m[m ] C E m [ m V ], = 1,..., T. minimize u ψ(u) T =1 σ2 (U 2 2M U /C) u C we choose he U such ha σ 2 (U M ) = 0 so U = M for = 1,..., T. The values of u 1,..., u T 1 are hus fixed, and we choose he final volume u T so ha u T = C CU T. The firs order condiion of he objecive funcion is saisfied, and hese values of u 1,..., u T are feasible (since M is non-decreasing in and M T 1). I follows ha his is an opimal soluion, i has values u = C E m [m /V ] for = 1,..., T. Consider now he original problem. Is objecive is a convex combinaion (apar from a consan facor) of he objecives of wo convex problem above and all hree have he same consrains se. Since he wo subproblems share an opimal soluion u, i follows ha u is also an opimal soluion for he combined problem. Thus, an he opimal soluion of (15) in he case of consan spread is u = C E m [ m V ] 8 = 1,..., T. (16)
This is equivalen o he soluion derived in [Kon02] and is he sandard in he brokerage indusry. In our model his soluion arises as he special case of consan spread, in general we could derive more sophisicaed saic soluions. We also noe ha we inroduced he approximaion κ = E m [1/m ] 1/E m [m ]. (In pracice, esimaing E m [1/m ] would require a more sophisicaed model of marke volumes han E m [m /V ]). We hus expec o lose some efficiency in he opimizaion of he rading coss. However, wih respec o he minimizaion of he variance of S (if λ or s = 0), his soluion is indeed opimal. In he following we compare he performances of (16) and of he dynamic soluion developed in 4. 4 Dynamic soluion We develop a soluion of he problem ha uses all he informaion available a he ime each decision is made, i.e., a sequence of funcions ψ (I ) where I is he informaion se available a ime (as defined in (14)). We work in he framework of Dynamic Programming (DP) [Ber95], summarized in 4.1. In paricular we fi our problem in he special case of linear dynamics and quadraic coss, described in 4.2. However we can apply sandard DP because he random shocks affecing he sysem a differen imes are no condiionally independen (he marke volumes have a join disribuion). We insead use he approximae procedure of [SBZ10], summarized in 4.3. In 4.4 we finally wrie our opimizaion problem, defining he sae, acion and coss, and in 4.5 we derive is soluion. 4.1 Dynamic programming We summarize here he sandard formalism of dynamic programming, following [Ber95]. Suppose we have a sae variable x X defined for = 1,..., T + 1 wih x 1 known. Our decision variables are u U for = 1,..., T and each u is chosen as a funcion of he curren sae, u = µ (x ). (We use he same symbol as he volumes raded a ime since in he following hey coincide.) The randomness of he sysem is modeled by a series of IID random variables w W, for = 1,..., T. The dynamics is described by a series of funcions a every sage we incur he cos x +1 = f (x, u, w ), g (x, u, w ), and a he end of he decision process we have a final cos g T +1 (x T +1 ). Our objecive is o minimize [ T ] J = E g (x, u, w ) + g T +1 (x T +1 ). =1 9
We solve he problem by backward inducion, defining he cos-o-go funcion v a each ime sep v (x) = min E[g (x, u, w ) + v +1 (f (x, u, w ))], = 1,..., T. (17) u This recursion is known as Bellman equaion. The final condiion is fixed by v T +1 ( ) = g T +1 ( ). I follows ha he opimal acion a ime is given by he soluion u = argmin E[g (x, u, w ) + v +1 (f (x, u, w ))]. (18) u In general, hese equaions are no solvable since he ieraion ha defines he funcions v requires an amoun of compuaion exponenial in he dimension of he sae space, acion space, and number of ime seps (curse of dimensionaliy). However some special forms of his problem have closed form soluions. We see one in he following secion. 4.2 Linear-quadraic sochasic conrol Whenever he dynamics funcions f are sochasic affine and he cos funcions are sochasic quadraic, he problem of 4.1 has an analyic soluion [BLR12]. We call his Linear- Quadraic Sochasic Conrol (LQSC). We define he sae space X = R n, he acion space U = R m for some n, m > 0. The disurbances are independen wih known disribuions and belong o a general se W. For = 1,..., T he sysem dynamics is described by x +1 = f (x, u, w ) = A (w )x + B (w )u + c (w ), = 1,..., T wih marix funcions A ( ) : W R n n, B ( ) : W R n m, and c ( ) : W R n. The sage coss are g (x, u, w ) = x T Q (w )x + q (w ) T x + u T R (w )u + r (w ) T u wih marix funcions Q ( ) : W R n n, q ( ) : W R n, R ( ) : W R m m, and r ( ) : W R m. The final cos is a quadraic funcion of he final sae g T +1 (x T +1 ) = x T T +1Q T +1 x T +1 + q T T +1x T +1. The main resul of he heory on linear-quadraic problems [Ber95] is ha he opimal policy µ (x ) is a simple affine funcion of he problem parameers and can be obained analyically µ (x ) = K x + l, = 0,..., T 1, (19) where K R m n and l R m depend on he problem parameers. In addiion, he coso-go funcion is a quadraic funcion of he sae v (x ) = x T D x + d T x + b (20) where D R n n, d R n, and b R for = 1,..., T. We derive hese resuls solving he Bellman equaions (17) by backward inducion. These are known as Riccai equaions, repored in Appendix A.1. 10
4.3 Condiionally dependen disurbances We now consider he case in which he disurbances are no independen, and we can apply he Bellman ieraion of 4.1. Specifically, we assume ha he disurbances have a join disribuion described by a densiy funcion f w ( ) : W W [0, 1]. One approach o solve his problem is o augmen he sae x, by including he disurbances observed up o ime. This causes he compuaional complexiy of he soluion o grow exponenially wih he increased dimensionaliy (curse of dimensionaliy). Some approximae dynamic programming echniques can be used o solve he augmened problem [Ber95] [Pow07]. We ake insead he approximae approach developed in [SBZ10], called shrinkinghorizon dynamic programming (SHDP), which performs reasonably well in pracice and leads o a racable soluion. (I can be seen as an exension of model predicive conrol, known o perform well in a variey of scenarios [Bem06] [KH06] [MWB11] [BMOW13]). We now summarize he approach. Assume we know he densiy of he fuure disurbances w,..., w T condiioned on he observed ones f w (w,..., w T ) : W W [0, 1]. (If = 1 his is he uncondiional densiy.) We derive he marginal densiy of each fuure disurbance, by inegraing over all ohers, ˆf w (w ),..., ˆf wt (w T ). We use he produc of hese marginals o approximae he densiy of he fuure disurbances, so hey all are independen. We hen compue he cos-o-go funcions wih backwards inducion using he Bellman equaions (17) and (18), where he expecaions over each disurbance w τ are aken on he condiional marginal densiy ˆf wτ. The equaions (17) for he cos-o-go funcion become (noe he subscrip ) v τ (x) = min u E [g τ (x, u, w τ ) + v τ+1 (f τ (x, u, w τ ))], (21) ˆf wτ for all imes τ =,..., T, wih he usual final condiion. Similarly, he equaions (18) for he opimal acion become u = argmin u E [g (x, u, w ) + v +1 (f (x, u, w ))] (22) ˆf w for all imes τ =,..., T. We only use he soluion u a ime. In fac when we proceed o he nex ime sep + 1 we rebuild he whole sequence of cos-o-go funcions v +1 +1 (x),..., v T +1 (x) using he updaed marginal condiional densiies and hen solve (22) o ge u +1. Wih his framework we can solve he VWAP problem we developed in 2. 11
4.4 VWAP problem as LQSC We now formulae he problem described in 2 in he framework of 4.2. For = 1,..., T +1 we define he sae as: ( 1 x = τ=1 u ) τ 1 τ=1 m, (23) τ so ha x 1 = (0, 0). The acion is u, he volume we rade during inerval, as defined in 2. The disurbance is ( ) m w = (24) V where he second elemen is he oal marke volume V = T =1 m. Wih his definiion he disurbances are no condiionally independen. In 4.5 we sudy heir join and marginal disribuions. We noe ha V, he second elemen of each w, is no observed afer ime. (The heory we developed so far does no require he disurbances w o be observed, he Bellman equaions only need expeced values of funcions of w.) For = 1,..., T he sae ransiion consiss in ( ) u x +1 = x +. So ha he dynamics marices are A (w ) = B (w ) = c (w ) = m ( ) 1 0 I, 0 1 ( ) 1 e 0 1, ( ) 0. The objecive funion (11) can be wrien as E T m =1 g (x, u, w ) where each sage cos is given by g (x, u, w ) = s ( α u2 u ) ( 1 ) + λσ 2 x T 1 C 2 CV 2 Cm C 1 1 x. CV V 2 The quadraic cos funcion erms are hus ( ) Q (w ) = λσ 2 1 1/CV C 2 1/CV 1/V 2 q (w ) = 0 R (w ) = αs 2Cm r (w ) = s 2C for = 1,..., T. The consrain ha he oal execued volume is equal o C imposes he las acion T 1 u T = µ T (x T ) = C u, K T x + l 12 m =1
wih K T = e T 1 l T = C. This in urn fixes he value funcion a ime T v T (x T ) = E g T (x T, K T x + l, w ), (25) so we can rea x T as our final sae and only consider he problem of choosing acions up o u T 1. We are lef wih he consrain u 0 for = 1,..., T. Unforunaely his can no be enforced in he LQSC formalism. We insead ake he approximae dynamic programming approach of [KB14]. We allow u o ge negaive sign and hen projec i on he se of feasible soluions. For every = 1,..., T we compue max(u, 0) and use i, insead of u, for our rading schedule. This complees he formulaion of our opimizaion problem ino he linear-quadraic sochasic conrol framework. We now focus on is soluion, using he approximae approach of 4.3. 4.5 Soluion in SHDP We provide an approximae soluion of he problem defined in 4.4 using he framework of shinking-horizon dynamic programming (summarized in 4.3). Consider a fixed ime = 1,..., T 1. We noe ha (unlike he assumpion of [SBZ10]) we do no observe he sequence of disurbances w 1,..., w 1, because he oal volume V is no known unil he end of he day. We only observe he sequence of marke volumes m 1,..., m 1. If f m (m 1,..., m T ) is he join disribuion of he marke volumes, hen he join disribuion of he disurbances is f w (w 1,..., w ) = f m (e T 1 w 1,..., e T 1 w T ) 1 {e T 2 w 1 =V } 1 {e T 2 w T =V } 1 {V = T τ=1 et 1 wτ } where e 1 = (1, 0), e 2 = (0, 1), and he funcion 1 { } has value 1 when he condiion is rue and 0 oherwise. We assume ha our marke volumes model also provides he condiional densiy f m (m,..., m T ) of m,..., m T given m 1,..., m 1. The condiional disribuion of V given m 1,..., m 1 is f V (V ) = f m (m,..., m T )1 {V = T τ=1 mτ }dm dm T (where he firs 1 marke volumes are consans and he ohers are inegraion variables). Le he marginal densiies be ˆf m (m ),..., ˆf mt (m T ). 13
The marginal condiional densiies of he disurbances are hus ˆf wτ ( ) = ˆf mτ ( ) f V ( ) (26) for τ =,..., T. We use hese o apply he machinery of 4.3, solve he Bellman equaions and obain he subopimal SHDP policy a ime. We compue he whole sequence of cos-o-go funcions and policies a imes τ =,..., T. The cos-o-go funcions are v τ (x τ ) = x T τ D τ x τ + d τ x τ + b τ (27) for τ =,..., T 1. The only difference wih equaion (20) is he condiion in he subscrip, because expeced values are aken over he marginal condiional densiies ˆf wτ ( ). Similarly, he policies are µ τ (x τ ) = K τ x τ + l τ (28) for τ =,..., T 1. We repor he equaions for his recursion in Appendix A.2. A every ime sep we compue he whole sequence of cos-o-go and policies, in order o ge he opimal acion u = µ (x ) = K τ x τ + l τ. (29) We hen move o he nex ime sep and repea he whole process. If we are no ineresed in compuing he cos-o-go v (x ) he equaions simplify somewha (we disregard large par of he recursion and only compue wha we need). We develop hese simplified formulas in Appendix A.3. 5 Empirical resuls We sudy he performance of he saic soluion of 3 versus he dynamic soluion of 4 by simulaing execuion or sock orders, using real NYSE marke price and volume daa. We describe in 5.1 he daase and how we process i. The dynamic soluion requires a model for he join disribuion of marke volumes, here we use a simple model, explained in 5.2. (We expec ha a more sophisicaed model for marke volumes would improve he soluion performance significanly.) In 5.3 we describe he rolling esing framework in which we operae. Our procedure is made up of wo pars: he hisorical esimaion of model parameers, explained in 5.4, and he acual simulaion of order execuion, in 5.5. Finally in 5.6 we show our aggregae resuls. 5.1 Daa We simulae execuion on daa from he NYSE sock marke. Specifically, we use he K = 30 differen socks which make up he Dow Jones Indusrial Average (DJIA), on N = 60 marke days corresponding o he las quarer of 2012, from Sepember 24 o December 20 (we do no consider he las days of December because he marke was eiher closed or had reduced 14
rading hours). The 30 symbols in ha quarer are: MMM, AXP, T, BA, CAT, CVX, CSCO, KO, DD, XOM, GE, HD, INTC, IBM, JNJ, JPM, MCD, MRK, MSFT, PFE, PG, TRV, UNH, UTX, VZ, WMT, DIS, AA, BAC, HPQ. We use raw Trade and Quoes (TAQ) daa from Wharon Research Daa Services (WRDS) [TAQ]. We processe he raw daa o obain daily series of marke volumes m Z + and average period price p R ++, for = 1,..., T where T = 390, so ha each inerval is one minue long. We clean he raw daa by filering ou rades meeing any of he following condiions: correcion code greaer han 1, rade daa incorrec; sales condiion 4, @4, C4, N4, R4, derivaively priced, i.e., he rade was execued over-he-couner (or in an exernal faciliy like a Dark Pool); sales condiion T or U, exended hours rades (before or afer he official marke hours); sales condiion V, sock opion rades (which are also execued over-he-couner); sales condiion Q, O, M, 6, opening rades and closing rades (he opening and closing aucions). In oher words we focus exclusively on he coninuous rading aciviy wihou considering marke opening and closing nor any over-he-couner rade. In Figure 1 we plo an example of marke volumes and prices. 5.2 Marke volumes model We have so far assumed ha he disribuion of marke volumes f m (m 1,..., m T ) is known from he sar of he day. In realiy a broker has a parameric family of disribuions and each day (or less ofen) selecs he parameers for he disribuion wih some saisical procedure. For simpliciy, we assume such procedure is based on hisorical daa. We found few works in he lieraure concerned wih inraday marke volumes modeling ([BDLF08]). We hus develop our own marke volume model. This is composed of a parameric family of marke volume disribuions and an ad hoc procedure o choose he parameers wih hisorical daa. For each sock we model he vecor of marke volumes as a mulivariae log-normal. If he superscrip (k) refers o he sock k (i.e., m (k) is he marke volume for sock k in inerval ), we have f m (k)(m (k) 1,..., m (k) T ) ln N (µ + 1b(k), Σ) (30) where b (k) R is a consan ha depends on he sock k (each sock has a differen ypical daily volume), µ R T is an average volume profile (normalized so ha 1 T µ = 0) and 15
200 Sock CVX on day 2012-10-09 118.4 150 118.2 Volume (shares, x1000) 100 50 118.0 117.8 117.6 117.4 Price ($) 0 0 50 100 150 200 250 300 350 ime (minues) 117.2 Figure 1: Example of a rading day. The blue bars are he marke volumes raded every minue (in number of shares) and he red line is he period price p. Σ S T ++ is a covariance marix. The volume process hus separaes ino a per-sock deerminisic componen, modeled by he consan b (k), and a sochasic componen wih he same disribuion for all socks, modeled as a mulivariae log-normal. We repor in Appendix B he ad hoc procedure we use o esimae he parameers of his volume model on hisorical daa and he formulas for he condiional expecaions E [1/V ], E [m τ ], E [1/m τ ] for τ =,..., T (which we need for he soluion (29)). The procedure for esimaing he volume model on pas daa requires us o provide a parameer, which we esimae wih cross-validaion on he iniial secion of he daa. The deails are explained in Appendix B. 5.3 Rolling esing We organize our simulaions according o a rolling esing or moving window procedure: for every day used o simulae order execuion we esimae he various parameers on daa from a window covering he preceding W > 0 days. (I is commonly assumed ha he mos recen hisorical daa are mos relevan for model calibraion since he sysems underlying he observed phenomena change over ime). We hus simulae execuion on each day i = W + 1,..., N using daa from he days i W,..., i 1 for hisorical esimaion. In his way every ime we es a VWAP soluion algorihm, we use model parameers calibraed on hisorical daa exclusively. In oher words he performance of our models are esimaed ou-of-sample. In addiion since all he order simulaions use he same amoun of hisorical daa for calibraion i is fair o compare hem. 16
We fix he window lengh of he hisorical esimaion o W = 20, corresponding roughly o one monh. We se aside he firs W CV = 10 simulaion days for cross-validaing a feaure of he volume model, as explained in Appendix B.2. In Figure 2 we describe he procedure. In he nex wo secions we explain how we perform he esimaion of model parameers and simulaion of orders execuion. order simul. (cross. val.) W = 20 days order simul. (cross. val.) W = 20 days. W CV = 10 days W = 20 days order simul. W = 20 days. order simul. Figure 2: Descripion of he rolling esing procedure. We ierae over he daase, simulaing execuion on any day i = W + 1,..., N and esimaing he model parameers on he preceding W = 20 days. The firs W CV = 10 days used o simulae orders are reserved for cross validaion (as explained in Appendix B.2). The aggregae resuls from he remaining W + W CV + 1,..., N days (30 days in oal) are presened in 5.6. 5.4 Models esimaion We describe he esimaion, on hisorical daa, of he parameers of all relevan models for our soluion algorihms. We append he superscrip (i, k) o any quaniy ha refers o marke day i and sock k. We sar by he marke volumes per inerval as a fracion of he oal daily volume (which we need for (16)). We use he sample average E [ m V ] i 1 j=i W K k=1 m(j,k) /V (j,k) W K for every = 1,..., T. An example of his esimaion (on he firs W = 20 days of he daase) is shown in Figure 3. The dynamic soluion (29) requires an esimae of he 17
3.5 Hisorical values of m /V (in percenage) 3.0 2.5 % of oal volume 2.0 1.5 1.0 0.5 0.0 10:00 11:00 12:00 13:00 14:00 15:00 Time Figure 3: Esimaed values of E [ ] m V using he firs W = 20 days of our daase, shown in percenage poins. volailies σ, we use he sample average of he squared price changes i 1 ( ) 2 K σ 2 j=i W k=1 (p (j,k) +1 p (j,k) )/p (j,k) W K for every = 1,..., T. In Figure 4 we show an example of his esimaion (on he firs W days of he daase). We hen choose he volume disribuion f m (m 1,..., m T ) among he parameric family defined in 5.2 (using he ad hoc procedure described in Appendix B.1). We esimae he expeced daily volume for each sock as he sample average i 1 E[V (i,k) j=i W ] V (j,k) W for every k = 1,..., K. We use his o choose he size of he simulaed orders. Finally, we consider he parameers s 1,..., s T, and α of he ransacion cos model (2). We do no esimae hem empirically since we would need addiional daa, marke quoes for he spread and proprieary daa of execued orders for α (confidenial for fiduciary reasons). We insead se hem o exogenous values, kep consan across all socks and days (o simplify comparison of execuion coss). We assume for simpliciy ha he fracional spread is consan in ime and equal o 2 basis poins, s 1 = = s T = 2 b.p. (one basis poin is 0.0001). Tha is reasonable for liquid socks such as he ones from he DJIA. We choose he parameer α following a rule-of-humb of ransacion coss: rading one day s volume coss approximaely on day s volailiy [KGM03]. We esimae empirically over he firs 20 days 18
16 Hisorical values of σ (in basis poins) 14 12 10 b.p. 8 6 4 2 10:00 11:00 12:00 13:00 14:00 15:00 Time Figure 4: Esimaed values of he period volailiies, ˆσ using he firs W = 20 days of our daase. For each period of one minue hese are he esimaed sandard deviaion of he price incremens, shown in basis poins (one basis poin is 0.0001). of he daase he open-o-close volailiy for our socks, equal o approximaely 90 basis poins, and hus from equaion (2) we se α = 90. 5.5 Simulaion of execuion wih VWAP soluion algorihms For each day i = W + 1,..., N and each sock k = 1,..., K we simulae he execuion of a rading order. We fix he size of he order equal o 1% of he expeced daily volume for he given sock on he given day C (i,k) = E[V (i,k) ]/100. Such orders are small enough o have negligible impac on he price of he sock [BFL09], as we need for (2) o hold. We repea he simulaion wih differen soluion mehods: he saic soluion (16) and he dynamic soluion (29) wih risk-aversion parameers λ = 0, 1, 10, 100, 1000,. We use he symbol a o index he soluion mehods. For each simulaion we solve he appropriae se of equaions, seing all hisorically esimaed parameers o he values obained wih he procedures of 5.4. For each soluion mehod we obain a simulaed rading schedule u (i,k,a), = 1,..., T where he superscrip a indexes he soluion mehods. We hen compue he slippage incurred 19
by he schedule using (4) S (i,k,a) = T =1 p(i,k) u (i,k,a) C (i,k) p (i,k) VWAP + C (i,k) p (i,k) VWAP T =1 s 2 ( α (u(i,k,a) ) 2 C (i,k) m (i,k) ) u(i,k,a). (31) C (i,k) Noe ha we are simulaing he ransacion coss. Measuring hem direcly would require o acually execue u (i,k,a). This es of ransacion coss opimizaion has value as a comparison beween he saic soluion (16) and he dynamic soluion (29). Our ransacion coss model (2) is similar o he ones of oher works in he lieraure (e.g., [FW13]) bu involves he marke volumes m. The saic soluion only uses he marke volumes disribuion known before he marke opens, while he dynamic soluion uses he SHDP procedure o incorporae real ime informaion and improve modeling of marke volumes. In he following we show ha he dynamic soluion achieves lower ransacion coss han he saic soluion, such gains are due o he beer handlng of informaion on marke volumes. In pracice a broker would use a differen model of ransacion coss, perhaps more complicaed han ours. We hink ha a good model should incorporae he marke volumes m as a key variable [BFL09]. Our es hus suggess ha also in ha seing he dynamic soluion would perform beer han he saic soluion. We show in Figure 5 he resul of he simulaion on a sample marke day, using he saic soluion (16) and he dynamic soluion (29) for λ = 0 and. We also plo he marke volumes m (i,k). 5.6 Aggregae resuls We repor he aggregae resuls from he simulaion of VWAP execuion on all he days reserved for orders simulaion (minus he ones used for cross-validaion). For any day i = W + W CV + 1,..., N, sock k = 1,..., K, and soluion mehod a (eiher he saic soluion (16) or he dynamic soluion (29) for various values of λ) we obain he simulaed slippage S (i,k,a) using (31). Then, for each soluion mehod a we define he empirical expeced value of S as N K E[S (a) i=w +W ] = CV +1 k=1 S(i,k,a) (N W W CV )K and he empirical variance var(s (a) ) = N K i=w +W CV +1 k=1 (S(i,k,a) ) 2 E[S (a) ] 2. (N W W CV )K 1 In Figure 6 we show he values of hese on a risk-reward plo. (We show he square roo of he variance for simpliciy, so ha boh axes are expressed in basis poins). We observe ha he dynamic soluion improves over he saic soluion on boh VWAP racking (variance of S) and ransacion coss (expeced value of S), and we can selec beween he differen behaviors by choosing differen values of λ. 20
1.0 0.8 Comparison of VWAP soluions and marke volumes. Sock JPM on day 2012-11-27 Saic soluion Dynamic soluion, λ = Dynamic soluion, λ =0 Marke volumes cum. fracion of oal volume 0.6 0.4 0.2 0.0 10:00 11:00 12:00 13:00 14:00 15:00 Time Figure 5: Simulaion of order execuion on a sample marke day. We repor all volume processes as cumulaive fracion of heir oal. A every ime τ we plo τ =1 m V for he marke volumes m and τ =1 u C for he various soluions u. We only show he dynamic soluion for λ = 0 and λ = since for all oher values of λ he soluion falls in beween. We inroduced in 2.2 he approximaion ha he value of (10) is negligible when compared o (9). The empirical resuls validae his. For he saic soluion he empirical average value of (9) is 4.45e 07 while (10) is 6.34e 09, abou 1%. For he dynamic soluion wih λ = he average value of (10) is 3.60e 07 and (9) is 1.92e 08, abou 5%. For he dynamic soluion wih λ = 0 insead he average value of (10) is 4.76e 07 and (9) is 5.50e 09, abou 1%. The dynamic soluions for oher values of λ si in beween. Thus he approximaion is generally valid, becoming less igh for high values of λ. In fac in Figure 6 we see ha he empirical variance of S for he dynamic soluion wih λ = is somewha larger han he one wih λ = 10000, probably because of he conribuion of (9). (We can inerpre his as a bias-variance radeoff since by going from λ = o λ = 10000 we effecively inroduce a regularizaion of he soluion.) 6 Conclusions We sudied he problem of opimal execuion under VWAP benchmark and developed wo broad families of soluions. The saic soluion of 3, alhough derived wih similar assumpions o he classic [Kon02], 21
7.0 6.8 λ =0 λ =1 Opimal fronier of dynamics soluions vs. saic soluion Saic soluion Dynamic soluions Sd. Dev. (sample) of S, b.p. 6.6 6.4 λ =10 Saic 6.2 λ =100 λ =1000 λ = 6.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 Expeced value (sample average) of S, b.p. Figure 6: Risk-reward plo of he aggregae resuls of our simulaions on real marke daa. Each do represens one soluion mehod, eiher he saic soluion (16) or he dynamic soluion (29) wih risk-aversion parameers λ = 0, 1, 10, 100, 1000,. We show he sample average of he simulaed slippages, which represens he execuion coss, and he sample sandard deviaion, i.e., he roo mean square error (RMSE) of racking he VWAP. The orders have size equal o 1% of he expeced daily volume. The dynamic soluion improves over he saic soluion in boh dimensions, we can choose he preferred behaviour by fixing he risk-aversion parameer λ. is more flexible and can accommodae more sophisicaed models (of bid-ask spread and volume) han he comparable saic soluions in he lieraure. By formulaing he problem as a quadraic program i is easy o add oher convex consrains (see [MS12] for a good lis) wih a guaraneed sraighforward fas soluion [BV09]. The dynamic soluion of 4 is he bigges conribuion of his work. One one side, we manipulae he problem o fi i ino he sandard formalism of linear-quadraic sochasic conrol. On he oher, we model he uncerainy on he oal marke volume (which is eschewed in all similar works we found in he lieraure) in a principled way, building on a recen resul in opimal conrol [SBZ10]. The empirical ess of 5 are based on simulaions wih real daa designed wih good saisical pracices (he rolling esing of 5.3 ensures ha all resuls are obained ou- 22
of-sample). We compare he performance of he saic soluion, sandard in he rading indusry, o our dynamic soluion. The dynamic soluion is buil around a model for he join disribuion of marke volumes, we provide a simple one in 5.2 (along wih ad hoc procedures o use i). This is supposed o be a proof-of-concep since in pracice a broker would have a more sophisicaed marke volume model, which would furher improve performance of he dynamic soluion. Even wih our model for marke volumes our dynamic soluion improves he performance of he saic soluion significanly. The resul validaes all he approximaions involved in he derivaion of he dynamic soluion and hus shows is value. Our simulaions quanify he improvemens of our dynamic soluion over he sandard saic soluion. On one side we can reduce he RMSE of VWAP racking by 10%. This is highly significan and could improve wih a more sophisicaed marke volume model. On he oher we can lower he execuion coss by around 25%. In our es his corresponds o 50$ of savings for an order of a million dollars (he VWAP execuions are worh billions of dollars each day). 23
Appendices A Dynamic programming equaions A.1 Riccai equaions for LQSC We derive he recursive formulas for (19) and (20). We know he final condiion v T +1 (x T +1 ) = g T +1 (x T +1 ), so D T +1 = Q T +1, d T +1 = d T +1, and b T +1 = 0. Now for he inducive sep, assume v +1 (x +1 ) is in he form of (20) wih known D +1, d +1, and b +1. Then he opimal acion a ime is, according o (18), wih u = argmin E[g (x, u, w ) + v +1 (A (w )x + B (w )u + c (w ))] = K x + l, u E[B (w ) T D +1 A (w )] K = (E R (w ) + E[B (w ) T D +1 B (w )] l = E r + 2 E[B (w ) T D +1 c(w )] + d T +1 E B (w ). 2(E R (w ) + E[B (w ) T D +1 B (w )] I follows ha he value funcion a ime is also in he form of (20), and i has value v (x ) = E [g (x, K x + l, w ) + v +1 (A (w )x + B (w )(K x + l ) + c (w ))] = wih D = E Q (w ) + K T E [ R (w ) + B (w ) T D +1 B (w ) ] K + E[A (w ) T D +1 A (w )] + K T E[B (w ) T D +1 A (w )] + E[A (w ) T D +1 B (w )]K d = E q (w ) + K T E r (w ) + 2 E K T R (w )l + E[A (w ) + B (w )K ) T (d +1 + 2D +1 (B (w )l + E c(w ))] b = b +1 + E R (w )l 2 + E r (w )l + E[(B (w )l + c(w )) T D +1 + d T +1)(B (w )l + c(w ))]. x T D x + d T x + b We hus compleed he inducion sep, and so he value funcion is quadraic and he policy affine a every ime sep = 1,..., T. The recursion can be solved as long as we know he funcional form of he problem parameers and he disribuion of he disurbances w. 24
A.2 SHDP Soluion We derive he recursive formulas for (27) and (28). These are equivalen o he Riccai equaions we derived in Appendix A.1, bu he expeced values are aken over he marginal condiional densiies ˆf wτ ( ). We wrie E o denoe such expecaion. In addiion, hese equaions are somewha simpler since our problem has A (w ) = I, B (w ) = e 1, q = 0, and r (w ) = r for = 1,..., T. The final condiions are fixed by (25) And he recursive equaions are for τ =,..., T 1. D T = E Q T (w T ) + e 1 E R T (w T )e T 1 d T = r T e T 1 2C E R T (w T )e T 1, b T = r T C. e T 1 D τ+1 K τ = E R τ (w τ ) + e T 1 D τ+1 e 1 l τ = r τ + d T τ+1 e 1 + 2e T 1 D τ+1 E c(w τ ) 2(E R τ (w τ ) + e T 1 D τ+1 e 1 ) ) D τ = E Q τ (w τ ) + Kτ (E T [R τ (w τ )] + e T1 D τ+1 e 1 K τ + D τ+1 + K T τ e T 1 D τ+1 + D τ+1 e 1 K τ = E Q τ (w τ ) + D τ+1 + K T τ e T 1 D τ+1 d τ = K T τ r τ + 2K T τ E R τ (w τ )l τ + (I + e 1 K τ ) T (d τ+1 + 2D τ+1 (e 1 l τ + E c(w τ ))) = d τ+1 + 2D τ+1 (e 1 l τ + E c(w τ )) b τ = b τ+1 + r τ l τ + E R τ (w τ )l 2 τ + E [c(w τ )D τ+1 c(w τ )] + d T τ+1 (e 1 l τ + E c(w τ )) + l τ e T 1 D τ+1 (e 1 l τ + 2 E c(w τ )) = b τ+1 + E [c(w τ )D τ+1 c(w τ )] + d T τ+1 E c(w τ ) A.3 SHDP simplied soluion (wihou value funcion) Pars of he equaions derived in Appendix A.2 are superfluous in case we are no ineresed in he cos-o-go funcions v τ (x ) for τ =,..., T 1. (In fac, we only wan o compue he opimal acion (29).) We disregard he consan erm b τ, and we only compue he hree scalar elemens ha we need from D τ and d τ. For any = 1,..., T and τ =,..., T 1 25
we define e 1D τ e 1 β τ e 1D τ e 2 = e 2D τ e 1 γ τ e 1d τ δ τ where e 1 = (1, 0) and e 2 = (0, 1) are he uni vecors. The final values are The policy β T = λ σ2 T C 2 + αs T 2C E [1/m T ] γ T = λ σ2 T C E [1/V ] δ T = s T 2C αs T E [1/m T ]. (β τ+1, γ τ+1 ) K τ = (αs τ /2C) E [1/m τ ] + β τ+1 l τ = s τ/(2c) + δ τ+1 + 2γ τ+1 E m τ 2((αs τ /2C) E [1/m τ ] + β τ+1 ) We resric he Riccai equaions o hese hree scalars. They are independen from he res of he recursion and we obain β τ = λ σ2 τ C βτ+1 2 + β 2 τ+1 = (αs τ /2C) E [1/m τ ] + β τ+1 λ σ2 τ C + (αs τ/2c) E [1/m τ ]β τ+1 2 (αs τ /2C) E [1/m τ ] + β τ+1 γ τ = λ σ2 τ C E [1/V ] β τ+1 γ τ+1 + γ τ+1 = (αs τ /2C) E [1/m τ ] + β τ+1 λ σ2 τ C E [1/V ] + (αs τ/2c) E [1/m τ ]γ τ+1 (αs τ /2C) E [1/m τ ] + β τ+1 δ τ = δ τ+1 + 2β τ+1 l τ + 2γ τ+1 E m.. A.3.1 Negligible spread We sudy he case where s = 0 for all = 1,..., T, equivalen o he limi λ. From he equaions above we ge ha for all = 1,..., T and τ =,..., T β τ = λ σ2 τ C 2 γ τ = λ σ2 τ C E[1/V ] δ τ = 0. 26
So for every = 1,..., T µ (x ) = K x + l = (β τ+1, γ τ+1 )x E m γ τ+1 β +1 = C E [1/V ] ( 1 ) 1 m τ + E m u τ. In oher words, a every poin in ime we look a he difference beween he fracion of order volume we have execued and he fracion of daily volume he marke has raded (using our mos recen esimae of he oal volume). We rade he expeced fracion for nex period C E [1/V ] E m, plus his difference. τ=1 τ=1 B Volume model We explain here he deails of he volume model (30), which we use for he dynamic VWAP soluion. In B.1 we describe he ad hoc procedure we use o esimae he parameers of he model on hisorical daa. Then in B.2 we deail he cross-validaion of a paricular feaure of he model. Finally in B.3 we derive formulas for he expeced values of some funcions of he volume, which we need for he soluion (29). B.1 Esimaion on hisorical daa We consider esimaion of he volume model parameers b (k), µ and Σ using daa from days i W,..., i 1 (we are solving he problem a day i). We append he superscrip (i, k) o any quaniy ha refers o marke day i and sock k. Esimaion of b k We firs esimae he value of b (k) for each sock k, as: ˆb(k) = i 1 T j=i W =1 log m(j,k) T W We show in Table 1 he values of ˆb (k) obained on he firs W days of our daase. Esimaion of µ Since each observaion log m (j,k) 1b (j,k) is disribued as a mulivariae Gaussian we use his empirical mean as esimaor of µ: ˆµ = i 1 K j=i W k=1 log m(j,k) W K We plo in Figure (7) he value of ˆµ obained on he firs W days of our daase. ˆb (k). 27
Sock ˆb(k) Sock ˆb(k) AA 4.338 JPM 4.599 AXP 3.910 KO 4.312 BA 3.845 MCD 4.017 BAC 5.309 MMM 3.701 CAT 4.118 MRK 4.176 CSCO 4.693 MSFT 4.848 CVX 3.986 PFE 4.586 DD 3.990 PG 4.088 DIS 4.055 T 4.566 GE 4.784 TRV 3.546 HD 4.139 UNH 3.902 HPQ 4.577 UTX 3.782 IBM 3.788 VZ 4.225 INTC 4.860 WMT 3.992 JNJ 4.244 XOM 4.260 Table 1: Empirical esimae ˆb (k) of he per-sock componen of he volume model, using daa from he firs W = 20 days. Esimaion of Σ We finally urn o he esimaion of he covariance marix Σ S T ++, using hisorical daa. In general, empirical esimaion of covariance marices is a complicaed problem. Typically one has no access o enough daa o avoid overfiing (a covariance marix has O(N 2 ) degrees of freedom, where N is he dimension of a sample). Many approximae approaches have been developed in he economerics and saisics lieraure. We designed an ad hoc procedure, inspired by works such as [FLM11]. We look for a marix of he form Σ = ff T + S, where f R T and S S T ++ is sparse. We firs build he empirical covariance marix. Le X R T (W K) be he marix whose columns are vecors of he form: log m (j,k) 1ˆb (k) ˆµ for each day j = i W,..., i 1 and sock k = 1,..., K. Then he empirical covariance marix is 1 ˆΣ = W K 1 XXT. We perform he singular value decomposiion of X X = U diag(s 1, s 2,..., s T ) V T, 28
3.0 Hisorical values of µ for he log-normal model 2.5 2.0 1.5 1.0 0.5 0.0 0.5 1.0 10:00 11:00 12:00 13:00 14:00 15:00 Time Figure 7: Empirical esimae ˆµ of he cross-ime componen of he volume model, using daa from he firs W = 20 days. where s R T, s 1 s 2... s T 0, U R T T, and V R (W K) T (because in pracice we have W K > T, since W = 20, K = 30, and T = 390). We have ˆΣ = 1 W K 1 U diag(s2 1, s 2 2,..., s 2 T ) U T. We show in Figure 8 he firs singular values s 1, s 2,..., s 20 compued on daa from he firs W days. I is clear ha he firs singular value is much larger han all he ohers. We hus build he rank 1 approximaion of he empirical covariance marix by keeping he firs singular value and firs (lef) singular vecor f = s 1U :,1, W K 1 so ha ff T is he bes (in Frobenius norm) rank-1 approximaion of ˆΣ. We now need o provide an approximaion for he sparse par S of he covariance marix. We assume ha S is a banded marix of bandwidh b > 0, which is non-zero only on he main diagonal and on b 1 diagonals above and below i (in oal i has 2b 1 non-zero diagonals). The value of b is chosen by cross-validaion, as explained in B.2. The assumpion ha S is banded is inspired by he inuiion ha elemens of log m (j,k) 1b (k) µ are correlaed (in ime) for shor delays. We find S by simply copying he diagonal elemens of he empirical covariance marix: { (ˆΣ ff T ) i,j if j i b S i,j = 0 oherwise. 29
200 Larges singular values of he log-normal volume model 180 160 140 120 100 80 60 40 0 5 10 15 20 Figure 8: Firs 20 singular values of he marix X of observaions log m (j,k) 1ˆb (k) ˆµ. We hus have buil a marix of he form Σ = ff T + S. Noe ha his procedure does no guaranee ha Σ is posiive definie. However in our empirical ess we always go posiive definie Σ for any b = 1, 2,.... B.2 Cross validaion As explained in B.1, we need o choose he value of he parameer b N (used for empirical esimaion of he covariance marix Σ). We choose i by cross-validaion, reserving he firs W CV = 10 esing days of he daase. We show in Figure 2 he way we pariion he daa (so ha he empirical esing is performed ou-of-sample wih respec o he cross-validaion). We simulae rading according o he soluion (29) wih λ = (i.e., he special case of Appendix A.3.1), for various values of b. We hen compue he empirical variance of S, and choose he value of b which minimizes i. (We are mosly ineresed in opimizing he variance of S, raher han he ransacion coss.) In Figure 9 we show he resul of his procedure (we show he sandard deviaions insead of variances, for simpliciy), along wih he resul using he saic soluion (16), for comparison. Since he difference in performance beween b = 3 and b = 5 is small (and we wan o avoid overfiing), we choose b = 3. 30
6.5 Cross validaion of b Sd. dev. of S (pips) 6.4 6.3 6.2 6.1 6.0 5.9 5.8 Dynamic sol. Saic sol. 5.7 1 2 3 4 5 6 7 8 9 b Figure 9: To cross validae he volume model parameer b, we compue he empirical sandard deviaion of S for he dynamic soluion (29) wih λ =, changing he value of b in he volume model. We also show he saic soluion (16), which does no use he volume model, for comparison. From his resul we choose b = 3 (o avoid overfiing). B.3 Expeced values of ineres We consider he problem a any fixed ime = 1,..., T 1, for a given sock k and day i. (We have observed marke volumes m 1,..., m 1.) We obain he condiional [ disribuion of he [ 1 unobserved volumes m,..., m T and derive expressions for E m τ, E m τ ], and E 1 ] V for any τ =,..., T. We need hese for he numerical soluion (29), as developed in Appendix A.3.1. Condiional disribuion We divide he covariance marix in blocks: ( ) Σ1:( 1),1:( 1) Σ Σ = 1:( 1),:T. Then we ge he marginal disribuion Σ :T,1:( 1) Σ :T,:T m :T log N (ν, Σ ) by aking he Schur complemen (e.g., [BV09]) of he covariance marix ν µ :T + b (k) + Σ T 1:( 1),:T Σ 1 1:( 1),1:( 1) (log m 1:( 1) µ 1:( 1) b (k) ) Σ Σ :T,:T Σ T 1:( 1),:T Σ 1 1:( 1),1:( 1) Σ 1:( 1),:T. Noe ha ν 1 = µ + b (k) and Σ 1 = Σ, i.e., he uncondiional disribuion of he marke volumes. We now develop he condiional expecaion expressions. 31
Volumes The expeced value of he remaining volumes m τ ( E m τ = exp (ν ) τ +1 + (Σ ) ) τ +1,τ +1, τ =,..., T. 2 (Because he (τ + 1)-h elemen of ν corresponds o he τ-h volume.) Inverse volumes The expeced value of he inverse of he remaining volumes m τ [ ] ( 1 E = exp (ν ) τ +1 + (Σ ) ) τ +1,τ +1, τ =,..., T. m τ 2 Toal volume We have, since we already observed m 1,..., m 1 1 E V = m τ + τ=1 T E m τ. τ= We also express is variance, which we need laer var(v ) = var T m τ = τ= T T cov(m τ, m τ ) = τ= τ = T T E m τ E m τ (exp((σ ) τ +1,τ +1) 1). τ= τ = Inverse oal volume We use he following approximaion, derived from he Taylor expansion formula. Consider a random variable z and a smooh funcion φ( ), hen So he inverse oal volume E φ(z) φ(e z) + φ (E z) 2 E [ 1 V ] var z. 1 E V + var (V ) E [V ] 3. References [AC01] [BDLF08] Rober Almgren and Neil Chriss. Opimal execuion of porfolio ransacions. Journal of Risk, 3:5 40, 2001. Jedrzej Bia lkowski, Serge Darolles, and Gaëlle Le Fol. Improving vwap sraegies: A dynamic volume approach. Journal of Banking & Finance, 32(9):1709 1722, 2008. 32
[Bem06] Albero Bemporad. Model predicive conrol design: New rends and ools. In Decision and Conrol, 2006 45h IEEE Conference on, pages 6678 6683. IEEE, 2006. [Ber95] Dimiri P Bersekas. Dynamic programming and opimal conrol, volume 1. Ahena Scienific Belmon, MA, 1995. [BFL09] J.P. Bouchaud, J.D. Farmer, and F. Lillo. How markes slowly diges changes in supply and demand, volume 4 of Handbook of financial markes. Norh-Holland, San Diego, CA, 2009. [BL98] Dimiris Bersimas and Andrew W Lo. Opimal conrol of execuion coss. Journal of Financial Markes, 1(1):1 50, 1998. [BLR12] Sephen Boyd, Sanjay Lall, and Ben Van Roy. Ee365: Sochasic conrol. hp://sanford.edu/class/ee365/lecures.hml, 2012. [BMOW13] Sephen Boyd, Mark Mueller, Brendan ODonoghue, and Yang Wang. Performance bounds and subopimal policies for muli-period invesmen. Foundaions and Trends in Opimizaion, 1(1):1 69, 2013. [BV09] Sephen Boyd and Lieven Vandenberghe. Convex opimizaion. Cambridge universiy press, 2009. [DCB13] [DCB14] [FLM11] [FW13] [GB14] [GR13] [HJ11] Alexander Domahidi, Eric Chu, and Sephen Boyd. Ecos: An socp solver for embedded sysems. In Conrol Conference (ECC), 2013 European, pages 3071 3076. IEEE, 2013. Seven Diamond, Eric Chu, and Sephen Boyd. CVXPY: A Pyhon-embedded modeling language for convex opimizaion, version 0.2. hp://cvxpy.org/, May 2014. Jianqing Fan, Yuan Liao, and Marina Mincheva. High dimensional covariance marix esimaion in approximae facor models. Annals of saisics, 39(6):3320, 2011. Chrisoph Frei and Nicholas Wesray. Opimal execuion of a vwap order: a sochasic conrol approach. Mahemaical Finance, 2013. Michael Gran and Sephen Boyd. CVX: Malab sofware for disciplined convex programming, version 2.1. hp://cvxr.com/cvx, March 2014. Olivier Guéan and Guillaume Royer. Vwap execuion and guaraneed vwap. arxiv preprin arxiv:1306.2832, 2013. Mark L Humphery-Jenner. Opimal vwap rading under noisy condiions. Journal of Banking & Finance, 35(9):2319 2329, 2011. 33
[KB14] Arezou Keshavarz and Sephen Boyd. Quadraic approximae dynamic programming for inpu-affine sysems. Inernaional Journal of Robus and Nonlinear Conrol, 24(3):432 449, 2014. [KGM03] [KH06] [Kon02] [LFM03] [Li13] R. Kissell, M. Glanz, and R. Malamu. Opimal Trading Sraegies: Quaniaive Approaches for Managing Marke Impac and Trading Risk. AMACOM, New York, NY, 2003. Wook Hyun Kwon and Soo Hee Han. Receding horizon conrol: model predicive conrol for sae models. Springer Science & Business Media, 2006. Hizuru Konishi. Opimal slice of a vwap rade. Journal of Financial Markes, 5(2):197 221, 2002. F. Lillo, J.D. Farmer, and R.N. Manegna. Maser curve for price-impac funcion. Naure, 421(129):176 190, 2003. Tianhui Michael Li. Dynamic Programming and Trade Execuion. PhD hesis, PRINCETON UNIVERSITY, 2013. [Mad02] Ananh N Madhavan. Vwap sraegies. Trading, 2002(1):32 39, 2002. [MK12] James McCulloch and Vlad Kazakov. Mean variance opimal vwap rading. Available a SSRN 1803858, 2012. [MS12] [MWB11] Ciamac C Moallemi and Mehme Saglam. Dynamic porfolio choice wih linear rebalancing rules. Available a SSRN 2011605, 2012. Jacob Maingley, Yang Wang, and Sephen Boyd. Receding horizon conrol. Conrol Sysems, IEEE, 31(3):52 65, 2011. [OW05] Anna Obizhaeva and Jiang Wang. Opimal rading sraegy and supply/demand dynamics. NBER Working Papers, hp://ideas.repec.org/p/nbr/nberwo/11444.hml 11444, Naional Bureau of Economic Research, June 2005. [Pow07] [SBZ10] Warren B Powell. Approximae Dynamic Programming: Solving he curses of dimensionaliy, volume 703. John Wiley & Sons, 2007. Joëlle Skaf, Sephen Boyd, and Assaf Zeevi. Shrinking-horizon dynamic programming. Inernaional Journal of Robus and Nonlinear Conrol, 20(17):1993 2002, 2010. [TAQ] Wharon Research Daa Services, TAQ Daase. hps: // wrds-web. wharon. upenn. edu/ wrds/. 34