Performance Evaluation of Trading Strategies in Multi-Agent Systems - Case of A-Trader
Performance Evaluation of Trading Strategies in Multi-Agent Systems - Case of A-Trader
Performance Evaluation of Trading Strategies in Multi-Agent Systems - Case of A-Trader
15439/2018F170
Computer Science and Information Systems pp. 839–844 ISSN 2300-5963 ACSIS, Vol. 15
Abstract—The article presents the problem related to usability is to be selected. The idea is to "set the bar" at such
evaluation of Forex trading strategies in multi-agent systems. a level that it would not be too low, because then the result
The ratios based on financial measures cannot be assumed to would be unsatisfactory, and not too high, because it might
be only evaluation criteria because other aspects determining
effectiveness of the strategies, such as, for instance, investment be unattainable for a trader. Note that in this case, the trader
risk, statistics on winning, and lost transactions, transaction can set the "bar" higher and higher in sequence, which will
costs, should also be taken into consideration. The aim of this bring him closer to the optimal value. Therefore, the ratios
paper is to review the general financial investments based measures cannot be assumed as the only evaluation
performance measures in relation to the performance analysis criterion because other aspects having influence on the
of trading strategies. The characteristics of the commonly used
effectiveness of the strategies, such as, for instance,
performance measures are outlined. The discussion will be
illustrated by solutions developed in the trading support investment risk [12], statistics on winning and lost
system, called A-Trader system. The performance analysis in transactions as well as transaction costs should also be taken
A-Trader is detailed on real FOREX quotations. into consideration.
The aim of this paper is to review the general financial
I. INTRODUCTION investments performance measures in relation to the
c
IEEE Catalog Number: CFP1885N-ART
2018, PTI 839
840 PROCEEDINGS OF THE FEDCSIS. POZNAŃ, 2018
measures based on ratios of excess returns (ratios- E(f) – arithmetic average of the risk-free rate of
based), return,
measures based on systematic risk measured by factor O(r) – standard deviation of rates of return.
models (risk-based),
measures based on endogenous benchmarks derived
from portfolio theory (benchmarks-based). Treynor Ratio
The major differences between these groups, but also 𝐸(𝑟)−𝐸(𝑓)
𝑇= (2)
𝛽(𝑟)
between specific measures refer to the definition of risk. The
next part of the section presents characteristics of particular where:
groups. E(r) – arithmetic average of the rate of return,
E(f) – arithmetic average of the risk-free rate of
A. Measures based on ratios of excess returns return,
Ratio-based performance measures specify the return per (r) – beta coefficient of rates of return.
unit of risk. Ratio-based performance measures are usually
easy to compute and have only low data requirements. These
measures are of high relevance in practical applications and The Kappa ratio
are frequently used in publications [12, 15, 17,18]. 𝐸(𝑟)−𝐸(𝑓)
𝑇= 𝑛 (3)
All ratios of return-based measures follow a similar √𝐿𝑃𝑀(𝑟)
schema: a measure of the return of asset in excess of the where:
return on the benchmark is divided by a measure of the E(r) – arithmetic average of the rate of return,
investment risk of asset. The most popular are the E(f) – arithmetic average of the risk-free rate of
following:: return,
arithmetic rate of return, LPM(r) – lower partial moments of rates of return.
logarithmic rate of return,
the number of transaction,
Omega ratio
gross profit, 𝑛
√𝐻𝑃𝑀(𝑟)
gross loss, Ω= 𝑛 (4)
√𝐿𝑃𝑀(𝑟)
total profit,
where:
the number of profitable transactions, HPM(r) – higher partial moments of rates of return.
the number of profitable transactions in a row, LPM(r) – lower partial moments of rates of return.
the number of unprofitable transactions in a row.
All of them are available in A-Trader.
Average coefficient of variation
B. Measures based on systematic risk measured by factor
models 𝑠
𝑉= ∗ 100%
Risk-based performance measures adjust for risk by |𝐸(𝑟)|
computing the spread between actual returns and a .
hypothetical benchmark return which is determined [17]. (5)
These measures indicate whether the trader was able to where:
beat the benchmark, strictly speaking, they do not allow for V – average coefficient of variation,
comparison of different investment products because risk- s – average deviation of the rates of return,
based performance measures are subject to manipulation by E(r) – arithmetic average of the rates of return.
leverage. For identification of relevant and meaningful risk
factors and computation of “fair” or expected returns, risk- Jensen Model
based performance measures draw heavily from the asset 𝐽𝑀 = 𝐸(𝑟) − (𝐸(𝑓) + (𝑟) ∙ (𝐸(𝑚) − 𝐸(𝑓))). (6)
pricing literature. This group contains measures, such as [17, where:
19]: E(r) – arithmetic average of the rate of return,
E(f) – arithmetic average of the risk-free rate of
Sharpe Ratio return,
E(m) – arithmetic average of the realized return of the
𝐸(𝑟)−𝐸(𝑓) appropriate market index,
𝑆= ∙ 100% (1)
|𝑂(𝑟)| E(f) – arithmetic average of the risk-free rate of
where: return,
E(r) – arithmetic average of the rate of return, (r) – beta coefficient of rates of return.
MARCIN HERNES, JERZY KORCZAK: PERFORMANCE EVALUATION OF TRADING STRATEGIES IN MULTI-AGENT SYSTEMS 841
Value at Risk 𝑇𝑀 = ∑𝑚
𝑗=1 𝐶𝑜𝑣 (𝑤𝑗𝑡, 𝑟𝑗𝑡 ) (10)
The measure known as a value exposed to the risk
- that is the maximum possible loss of the market where:
value that a financial instrument can bear in a specific 𝑤𝑗𝑡 – weight of asset j at time t,
timeframe and at a given confidence level. 𝑟𝑗𝑡 – corresponding excess return of asset j at time t,
total profit (ratio x4), and the agent's efficiency is directly proportional to the
number of profitable transactions (ratio x5), function value.
number of profitable consecutive transactions Figure 1 presents performance evaluation panel in A-
(ratio x6), Trader. The upper part of window presents information
related to open/close positions generated by strategy in a
number of unprofitable consecutive transactions
given period. The profitable ones are marked on green and
(ratio x7),
unprofitable ones are marked on red. The bottom part of
Sharpe ratio (ratio x8) window presents performance evaluation values related to
average coefficient of variation (ratio x9) selected positions (it is possible to mark all positions, or only
Value at Risk (ratio x10) selected positions).
the average rate of return per transaction (ratio Referring to the evaluation analysis related to particular
x11). measures performed in other systems (mentioned in section
There are many ways of defining the performance 1), as previously underlined, these systems only offer the
evaluation function. For the purpose of comparison of the functions calculating the rates of return based ratios. It
agents' performance, the following simple evaluation should be noted that evaluation, in most cases, is performed
function has been proposed: "manually" by the trader. This work has many
𝑦 = (𝑎1 𝑥1 + 𝑎2 𝑥2 + 𝑎3(1− 𝑥3 ) + 𝑎4 𝑥4 + 𝑎5 𝑥5 + 𝑎6 𝑥6 + inconveniences. Due to its time consumption, the trader can
𝑎7 (1 − 𝑥7 ) + 𝑎8 𝑥8 + 𝑎9 (1 − 𝑥9 ) + 𝑎10 (1 − 𝑥10 ) + 𝑎11 𝑥11 use only selected measures of performance, and choice of
(11) these measures may be narrow. Also the trader acting under
where xi denote the normalized values of particular time pressure may select inadequate measures, and, in
performance measures from x1 to x11. It was adopted in the consequence, important financial losses may be generated.
test that coefficients a1 to a11=1/11. In addition, it is very difficult to have valid current
It should be mentioned that these coefficients may be knowledge on online trading (the trader’s knowledge, in
modified with the use of, for instance, an evolution-based very turbulent market conditions, may be outdated or/and
method, or they could be determined by the trader in incomplete). These issues imply that systems operating in
accordance with their preferences (for instance the trader real time are very limited.
may determine whether they are interested in higher rate of As has been mentioned, the evaluation function used in A-
return with accompanying higher risk level or lower risk Trader enables the evaluation of performance of specific
level but accepting a lower rate of return). strategies. These operations are made automatically, in time
The output of the function is a value in the range [0..1], close to real time, by the Supervisor Agent which may then
[21] J. Korczak and M. Hernes, “Deep Learning for Financial Time Series [23] J. Korczak, M. Hernes and M. Bac, “Fuzzy Logic as Agents’
Forecasting in A-Trader System”, [in] Proceedings of the 2017 Knowledge Representation in A-Trader System”, [in] Information
Federated Conference on Computer Science and Information Technology for Management. Federated Conference on Computer
Systems / Ganzha Maria, Maciaszek Leszek, Paprzycki Marcin Science and Information Systems, ISM 2015 and AITM 2015, Lodz,
(eds.), Annals of Computer Science and Information Systems, vol. Poland, Revised Selected Papers / Ziemba Ewa ( red. ), Lecture
11, Polskie Towarzystwo Informatyczne, Institute of Electrical and Notes in Business Information Processing, vol. 243, 2016, Springer,
Electronics Engineers, 2017. DOI: 10.15439/2017F449. ISBN 978-3-319-30527-1, ss. 109-124, 2015.
[22] M. Hernes and J. Sobieska-Karpińska , “Application of the [24] J. Korczak, M. Hernes and M. Bac, “Risk avoiding strategy in multi-
consensus method in a multi-agent financial decision support agent trading system”, [in] Proceedings of the 2013 Federated
system”, Information Systems and e-Business Management 14 (1), Conference on Computer Science and Information Systems / Ganzha
Springer Berlin Heidelberg, 2016, DOI: 10.1007/s10257-015-0280-9. Maria, Maciaszek Leszek, Paprzycki Marcin ( red. ), IEEE, 2013.