Inventory prediction in foreign exchange markets Damien Challet - - PowerPoint PPT Presentation

inventory prediction in foreign exchange markets
SMART_READER_LITE
LIVE PREVIEW

Inventory prediction in foreign exchange markets Damien Challet - - PowerPoint PPT Presentation

Inventory prediction in foreign exchange markets Damien Challet CentraleSuplec and Encelade Capital with Mehdi Lallouache, Rmy Chicheportiche, Serge Kassibrakis Mosaic Finance, Capital Fund Management, Swissquote Bank May 12, 2017 with


slide-1
SLIDE 1

Inventory prediction in foreign exchange markets

Damien Challet

CentraleSupélec and Encelade Capital with

Mehdi Lallouache, Rémy Chicheportiche, Serge Kassibrakis

Mosaic Finance, Capital Fund Management, Swissquote Bank

May 12, 2017

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-2
SLIDE 2

Near-prejudices in Finance

Public data: price nearly unpredictable Proprietary data: nearly unaccessible, underexploited Machine learning: nearly useless, too much noise

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-3
SLIDE 3

Foreign exchange market structure

Exchange EUR → USD

BROKER 10,000

  • 30,000

Liquidity Provider Liquidity Provider Liquidity Provider 100,000 1,000,000

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-4
SLIDE 4

Broker inventory

Minimum amount to Liquidity Provider Broker aggregates small amounts → inventory Order matching: save exchange fees

BROKER 10,000

  • 30,000

Liquidity Provider Liquidity Provider Liquidity Provider 100,000 1,000,000 Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-5
SLIDE 5

Inventory management

Set maximum inventory ΦMAX ∈ [100,000, 10,000,000] Random client order flow φt ∼ P(φ) Keep orders in inventory Φt = ∑t′≤t φt Flush inventory to liquidity provider if |Φt| > ΦMAX Random price changes

dPt Pt = trend +noiset

Mathematical Finance: optimise risk as a function of ΦMAX and time horizon T

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-6
SLIDE 6

Big data approach to inventory management

O(104) clients O(107) transactions Number of transactions per client

10-3 10-2 10-1 100 100 101 102 103 104

N P>(N)

Financial markets are predictable with client IDs

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-7
SLIDE 7

Prediction problems = Science + Engineering

Science: flux

1

cluster clients

2

lead-lag networks

3

machine learning

4

ENJOY! Engineering

1

Predict price returns

2

Inventory constraints

3

PROFIT!

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-8
SLIDE 8

Cluster traders

  • 50

100 150 200 −8 −6 −4 −2 2 yday cumsum(strat)

  • 50

100 150 200 −10 −5 5 10 yday cumsum(strat)

  • 50

100 150 200 −2 2 4 6 8 yday cumsum(strat)

  • 50

100 150 200 10 20 30 40 50 yday cumsum(strat)

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-9
SLIDE 9

Unsupervised classification: synchronous actions

Tumminello et al. (2011a)

1

Agent i, statei(t) ∈ {1,··· ,S} si(t) = sign Buy(t)−Sell(t) Buy(t)+Sell(t) ∈ {−1,0,1,2 = / 0} H0 : states of agents i and j are Poisson processes O(N2) pairs → multiple hypothesis correction → NETWORK

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-10
SLIDE 10

Synchronized traders

Challet et al. (2017) EUR.USD SQ daily hourly

  • Links

−1 −1 1 1

  • Links

−1 −1 1 1 2 2

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-11
SLIDE 11

Predictability of order flow

Conditions:

1

Clusters of agents are stable

2

Cluster activity is predictable ≡ persistent lead-lag cluster networks

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-12
SLIDE 12

Cluster stability

1_1 2_1 1_2 1_3 1_15 1_24 1_16 1_17 1_26 1_29 2_37 1_4 2_2 2_3 1_31 1_7 2_8 1_10 2_9 1_8 2_5 2_21 2_10 1_21 1_23 2_27 1_11 2_12 1_22 2_26 2_19 2_36 2_22 2_25 1_20 1_27 2_32 1_30 2_34 2_24 2_28 1_28 2_33 2_29 2_31 1_0 2_17 2_18 2_20 2_23 2_0 3_1 3_2 3_3 3_5 3_7 3_13 3_29 3_10 3_20 3_30 3_14 3_34 3_21 3_27 3_39 3_15 3_19 3_40 3_31 3_37 3_16 3_42 3_32 3_38 3_26 3_28 3_35 3_12 3_25 3_24 3_22 3_36 4_1 4_3 4_2 4_6 4_9 4_13 4_22 4_15 4_25 4_7 4_34 4_14 4_23 4_24 4_30 4_19 4_28 4_33 4_37 4_27 4_11 4_32 4_35 4_36 4_31 4_17 4_21 4_26 4_0 5_1 5_2 5_3 5_7 5_16 5_11 5_30 5_8 5_34 5_10 5_36 5_32 5_29 5_14 5_42 5_47 5_21 5_40 5_31 5_26 5_27 5_22 5_24 5_44 5_48 5_35 5_28 5_37 5_15 5_18 5_45 5_12 5_19 5_49 5_38 5_50 5_46 5_39 5_41 5_20 5_0 6_1 6_2 6_3 6_15 6_18 6_32 6_6 6_30 6_28 6_39 6_33 6_36 6_34 6_13 6_7 6_10 6_16 6_47 6_29 6_45 6_37 6_41 6_19 6_35 6_43 6_38 6_27 6_44 6_31 6_21 6_8 6_42 6_25 6_14 6_23 6_46 6_26 6_20 6_0 7_1 7_2 7_3 7_11 7_4 7_10 7_31 7_27 7_14 7_16 7_36 7_20 7_29 7_32 7_33 7_6 7_17 7_21 7_38 7_37 7_42 7_41 7_35 7_28 7_19 7_30 7_25 7_40 7_24 7_26 7_39 7_23 7_22 7_0 8_1 8_14 8_2 8_5 8_7 8_20 8_15 8_24 8_6 8_12 8_25 8_9 8_27 8_23 8_30 8_21 8_28 8_19 8_31 8_29 8_33 8_32 8_26 8_10 8_22 8_0 9_1 9_6 9_8 9_38 9_37 9_22 9_14 9_23 9_15 9_25 9_10 9_12 9_21 9_19 9_30 9_33 9_27 9_34 9_26 9_28 9_40 9_31 9_35 9_36 9_29 9_24 9_5 9_41 9_39 9_32 9_16 9_18 9_0 10_1 10_9 10_7 10_11 10_5 10_21 10_20 10_16 10_4 10_23 10_22 10_15 10_26 10_30 10_24 10_25 10_29 10_31 10_27 10_32 10_34 10_10 10_18 10_28 10_35 10_33 10_0 11_1 11_4 11_6 11_12 11_10 11_16 11_30 11_25 11_27 11_11 11_17 11_7 11_33 11_32 11_29 11_28 11_18 11_39 11_36 11_34 11_26 11_37 11_38 11_20 11_14 11_35 11_31 11_19 11_2 11_21 11_0 12_1 12_2 12_21 12_3 12_13 12_6 12_12 12_8 12_26 12_9 12_15 12_17 12_24 12_23 12_28 12_22 12_30 12_25 12_20 12_29 12_27 12_14 13_1 13_2 13_4 13_8 13_3 13_13 13_27 13_21 13_5 13_19 13_22 13_24 13_23 13_9 13_17 13_36 13_30 13_34 13_26 13_32 13_28 13_31 13_14 13_18 13_33 13_29 13_35 14_1 14_2 14_4 14_3 14_5 14_8 14_30 14_11 14_18 14_21 14_10 14_22 14_27 14_23 14_19 14_24 14_28 14_25 14_29 14_26 14_0

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-13
SLIDE 13

lead-lag SVNs

Compute p-value of {sg(t),sg′(t +1)}

  • 24

3 22 25 4 11 16 10 7 6 5 17 29 31 2 20 35 12 19 32 37 39 [ −1 −> −1 ] [ −1 −> 1 ] [ −1 −> 2 ] [ 1 −> −1 ] [ 1 −> 1 ] [ 1 −> 2 ] [ 2 −> 2 ]

  • 4

5 2 6 1 3 [ −1 −> −1 ] [ −1 −> 1 ] [ 1 −> −1 ] [ 1 −> 1 ]

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-14
SLIDE 14

Origin of lead-lag

Explicit/implicit communication Delayed reaction

1

faster news

2

same strategy, faster parameters MA(CD) 12, 26, 5 → 10, 25, 4:

3

Master in Finance

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-15
SLIDE 15

Trader-trader: explicit communication

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-16
SLIDE 16

Implicit communication: prices

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-17
SLIDE 17

How to predict order flow

1

Determine groups

2

Determine group state σg,t

3

Learn on-line sign of next global order flow Pt0,t1 =    σ1,t0 σ2,t0 σ1,t0−1 σ2,t0−1 h(t0) . . . . . . . . . . . . . . . σ1,t1 σ2,t1 σ1,t1−1 σ2,t1−1 h(t1)    ∼    ˆ ss(t0 +1) . . . ˆ ss(t1 +1)   

4

∼: vanilla Random Forest (15 seconds / day)

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-18
SLIDE 18

Results

100 200 300 2014−07 2015−01 2015−07 2016−01 Cumulated performance [sign]

Tin

45 50 55 60 65 70 75 80 85 90

SQ EURUSD

0e+00 2e+09 4e+09 6e+09 8e+09 2014−07 2015−01 2015−07 2016−01 Cumulated performance [CHF]

Tin

45 50 55 60 65 70 75 80 85 90

SQ EURUSD

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-19
SLIDE 19

How to predict VWAP

VWAP= Value-Weighted Average Price of next orders

1

Determine groups

2

Determine group state σg,t

3

Learn on-line sign of next VWAP difference Pt0,t1 =    σ1,t0 σ2,t0 σ1,t0−1 σ2,t0−1 h(t0) . . . . . . . . . . . . . . . σ1,t1 σ2,t1 σ1,t1−1 σ2,t1−1 h(t1)    ∼    ˆ ss(t0 +1) . . . ˆ ss(t1 +1)   

4

∼: vanilla Random Forest

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-20
SLIDE 20

Conditions of success

1

VWAP predictable if order flow is predictable

2

Order flow depends on past prices

3

FX traders: systematic strategies

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-21
SLIDE 21

Result: VWAP

200 400 600 2015−01 2015−07 2016−01 Cumulated performance [sign] Tin 45 50 55 60 65 70 75 80 85 90

SQ VWAP EURUSD

1.0 1.5 2.0 2.5 3.0 2015−01 2015−07 2016−01 Cumulated performance Tin 45 50 55 60 65 70 75 80 85 90

SQ VWAP EURUSD

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets

slide-22
SLIDE 22

Summary

1

Order flux OK

2

VWAP OK

3

Trader’s activity is triggered by that of other traders Todo Reverse engineer strategy of groups Other fields Other time horizons ...

Damien Challet CentraleSupélec and Encelade Capital

withMehdi Lallouache, Rémy Chicheportiche,

Inventory prediction in foreign exchange markets