1 Introduction

High-frequency foreign exchange trading strategies have been the focus of much effort in recent years by both traders and researchers. Fundamental analysis, as it relates to foreign exchange trading, requires that many global and macroeconomic factors be taken into account. To incorporate this wide array of influences into algorithmic trading schemes would be a difficult task. Furthermore, because fundamental factors do not vary significantly over the short time horizons used in algorithmic trading, the task of developing algorithmic trading rules seems to lend itself naturally to technical analysis approaches. On the other hand, technical analysis is the practice by traders of using statistical indicators based on historical price and volume data to identify current price trends, price trend reversals, and other market conditions, and thereby predict future price movements.

In this paper, we perform algorithmic searches for the optimum indicator values and for optimum operator values in a multi-objective optimization framework, focusing on the trading market’s needs. Our approach goes beyond what previous studies have done by incorporating multiple objective functions, thus recognizing the trade-offs that market traders must make daily. By incorporating the three objective functions of profit, deviation, and maximum drawdown, this research work demonstrates the multi-objective optimization application for algorithmic trading strategies in foreign exchange markets. We propose to answer the following research questions:

  1. 1.

    Can we address the importance of multi-objective strategies in algorithmic foreign exchange trading on the continuous time horizon?

  2. 2.

    Can design variables such as trading volume, the time horizon for historical data used, and trading gateways of technical indicators be optimized in real time?

  3. 3.

    How can multi-objective optimization theory be used to provide trading strategies, while showing trade-off relationships among objective functions?

Much research effort into the development of foreign exchange trading strategies has focused on machine learning. Dempster and Jones (2001) used a genetic programming (GP) system to produce trading rules for US Dollar/British Pound intraday spot data, where genetic algorithms require that string length to be fixed (i.e., the number of technical indicators used in all generations of trading rules be the same), genetic programming, by allowing trading rules to vary in length, can probe the solution space more efficiently. For their single-objective function, they used a modified Sterling ratio.

Dunis et al. (1999) used GA to develop trading systems containing two models, a signal model and a position model. The signal model is based on momentum trend indicators and produces price predictions. The position model then generates a trading rule based on comparing the current market price to the predicted price, given the trader’s current position. Initially, the authors used profit as the only fitness criteria. They also develop a “performance index” consisting of (a) the fraction of positions which were profitable; (b) a pessimism ratio; (c) the Sharpe ratio; (d) the annualized cumulative gain; and (e) the 5% probability of ruin. However, the authors did not incorporate their index into a multi-objective GA system. Model results based on this index did not differ significantly from models optimized solely on profit.

Hirabayashi et al. (2009) applied GA to determine optimum market timing based on the best combination of technical indicators. The four technical indicators used were: (a) the relative strength index (RSI), (b) the percent difference from a moving average, (c) the rising/falling rate lagged by 1°h, and (d) an RSI based on an exponentially weighted moving average. Using three different conditional equations created by varying the Boolean operators connecting the indicators, the authors, in effect, varied the length of the strings by which technical indicators were “turned on” through the optimal conditional equation.

Using 10-min time intervals to measure price change and eight different technical indicators, Myszkowski and Bicz (2010) applied GA to generate trading strategies on the EUR/USD currency pair. Using the data from May 2007 to January 2010, they identified time periods of approximately equal lengths, during which the exchange rate for the USD was either falling or rising, or showing no discernible trend. GA was used to find optimal values for maximum tree height or string length, transaction costs, probability of mutation, and probability of crossover. The authors used a single fitness function which consisted of the sum of all profits divided by the sum of all losses and transaction costs.

Zhang and Ren (2010) also used GA to develop trading strategies based on the GBP/USD currency pair, experimenting with ten different technical indicators and incorporating a neutral position trading rule (i.e., the trader neither buys nor sells) into their strategies. For their objective function, they used the Sterling ratio as their single performance criterion.

While most GA research efforts into the development of foreign exchange trading rules, including the ones cited above, use only one objective or fitness function, many real-world problems require the consideration of multiple and conflicting goals. In finance, the classic trade-off is between risk and return. This trade-off is measured in many forms in the literature such as value-at-risk (VaR), the Sharpe ratio, maximum loss, the winning ratio, and chance of ruin. The portfolio optimization theory, suggested by Markowitz (1952), embodies the minimized portfolio variance with a restriction that the portfolio’s weights sum to 1 at a given mean return. Current trading algorithms in academia and industry mainly count on the Sharpe ratio (Return/Risk) that originated from an investment’s return and risk. Consequently, the use of Sharpe ratio in trading algorithms often results in a single-objective optimization viewpoint. Our research paper will address properly conflicting financial goals in foreign exchange trading, while using a genetic algorithm methodology with multi-objective functions.

There are many examples in the literature of problems which incorporate multiple objectives. For example, in developing multi-objective optimization algorithms, Deb et al. (2002) proposed multi-objective evolutionary algorithms (EAs) that use non-dominated sorting and sharing methods. They named the algorithm “non-dominated sorting genetic algorithm II (NSGA-II).” The algorithm is able to find a better spread of solutions and has better convergence properties near the true Pareto optimal frontier in most benchmark tests. It is considered an improved version of NSGA, which originated in 1995 (Srinivas and Deb 1995). The fundamental concept for non-dominated sorting is a ranking selection method, which finds good points in the design pool for maintaining sub-populations of these good points. The main issues in GA algorithms are the high computational load and unexpected local optima. Deb et al. (2002) updated the algorithm (NSGA-II) using a fast non-dominated sorting procedure, an elitist-preserving approach, and a parameter-less niching operator.

In finance applications of multi-objective optimization, many research articles propose unique academic methods. Babaei et al. (2015) formulate the portfolio optimization problem as a multi-objective mixed integer programming problem. For this research, they used Value-at-Risk (VaR) as a risk measure. With their research framework, they tried to shed light on the dependence structure among the financial returns along with the fat-tailed distribution. Another instance of multi-objective optimization in finance, Lwin et al. (2017) suggested an alternative to Markowitz’s mean–variance model in which the variance is replaced with an industry standard risk measure, Value-at-Risk (VaR), for the assessment of market risk exposure, which is closely associated with fluctuated financial data. This research tries to minimize the computational load to a non-convex NP-hard problem which is computationally intractable.

2 Methodology

2.1 Multi-objective optimization

Multi-objective optimization is a technique of analysis involving more than one objective function. This approach has been applied in many fields of science, including engineering, economics, and logistics, where optimal decisions need to be taken in the presence of trade-offs among objective functions. It has also been referred to as multi-objective programming, vector optimization, multi-criteria optimization, or Pareto optimization. Problems of this type generally have an infinite number of optimal Pareto solutions and the optimal Pareto set can be non-convex. Solving multi-objective optimization problems allows a decision maker to identify a manageable set of preferable options among the Pareto optimal solutions. The goal in multi-objective optimization of finding the Pareto optimal set can be expressed mathematically as:

$${\text{Multi-objective}}\;{\text{optimization}}\left\{ {\begin{array}{*{20}l} {{\text{minimize}}\;\left( {f_{1} \left( x \right), \ldots ,f_{\text{k}} \left( x \right)} \right)} \hfill \\ {{\text{subject}}\;{\text{to}}\;x \in X \subset R^{\text{m}} } \hfill \\ \end{array} } \right.,$$
(1)

where x is a vector of design variables (i.e., a point in the design space) and where \(X\) represents a feasible design space defined by constraints (Deb 2005; Miettinen 2008; Miettinen et al. 2008; Srinivas and Deb 1994).

The following sequence of definitions formally defines the solution set, i.e., the Pareto optimal set of points.

Definition 1

Given two vectors x and y \(\in R^{k}\), x dominates y if x ≤ y, for all elements of the vector.

Definition 2

A vector of design variables \(x \in X \subset R^{k}\) is non-dominated in regards to \(X\), if there does not exist another \(x^{\prime} \in X,\) such that \(x^{\prime}\) dominates \(x\).

Definition 3

If \(X\) is non-dominated, the vector of design variables \(x \in X \subset R^{k}\) is a Pareto optimal solution.

Definition 4

The Pareto optimal solutions \(X\) can be defined as the non-dominated set of the feasible solution space, i.e.

$$P = \{ x \in X|x\;{\text{is}}\;{\text{pareto-optimal}}\} .$$

Finally, a Pareto optimal front is the boundary of the Pareto optimal set. Figure 1 illustrates the concept of Pareto optimum solutions and Pareto frontier.

Fig. 1
figure 1

Illustrating the concept of Pareto optimum solutions

2.2 Genetic algorithms

Genetic algorithms use the principle of “survival of the fittest” to find solutions to optimization problems (Goldberg 1989). The genetic algorithm (GA) approach is an artificial search technique that borrows from biology the processes of inheritance, selection, crossover, and mutation, to repeatedly search for better and better solutions. While truly perfect optimization is not guaranteed with GA, near perfect solutions to hard problems in the real world are often the best that can be achieved. One reason that genetic algorithms are efficient techniques for searching difficult solution spaces is that they are population-based algorithms. Instead of the researcher testing one possible solution after another, each generation generated according to the GA algorithm typically includes many potential solutions that are an improvement over prior generations. This large sampling technique allows GA to move more quickly to an optimal solution.

To implement the selection process, potential solutions must be translated into binary strings of finite length. These strings are then scored against a fitness function, so that optimization can be achieved. To initialize the GA algorithm, an initial generation of potential solutions is generated randomly. These solutions are then evaluated against the objective function and ranked according to their fitness values. The second generation is then subjected to the genetic operator called crossover. Crossover occurs when strings in this second generation are paired randomly, after which both strings in each pair are broken at a randomly determined point. The strings of the pair, which stand for design variables, are then swapped, thereby exchanging their genetic information and creating new solutions. Some information may be lost through this crossover mechanism, however. Mutation in GAs helps guard against this through random alterations with small probability, and thus is a random attempt to replace potentially valuable genetic information that was lost prematurely. The GA procedure can be summarized as follows:

Step 1 (Initialization): randomly initialized population of solutions are generated and the objective functions are evaluated.

Step 2 (Selection): during each successive generation, a portion of the existing population is selected to be passed on to the new generation. Individual solutions are selected based on assessment of objective functions.

Step 3 (Crossover): combining parents from existing population to produce the next generation. Using crossover, new solutions in the feasible design space are searched.

Step 4 (Mutation): mutation happens with small probability and it helps prevent premature local optimum.

Step 5 (Loop): go to step 2.

2.3 Non-dominated sorting genetic algorithm II (NSGA-II)

The GA algorithm used in this research is non-dominated sorting genetic algorithm II (NSGA-II) (Deb et al. 2002). This GA algorithm is the updated version of NSGA (Srinivas and Deb 1995) using a fast non-dominated sorting procedure, an elitist-preserving approach, and a parameter-less niching operator. In GA algorithms for single and multi-objective optimizations, both high computational load and local optima are still on-going issues that need to be addressed. In regards to existing problems, NSGA-II shows relatively better performance and has been widely used since its development. In particular, in multi-objective optimization, non-dominated Pareto solutions are well searched by NSGA-II, while saving and minimizing simulation time.

2.4 Technical indicators for trading

There are various technical indicators in the market and they were developed to detect the market trend. Since most trading indicators include similar components and show high correlations among them, this paper adopts the four most popular indicators (Chan 2008; Gencay et al. 2001; Kestner 2003). The technical indicators we use are the price oscillator (PO), relative strength index (RSI), stochastic oscillator (SC), and rate of change (ROC). The details for these technical indicators are provided in the “Appendix”.

3 Data and simulation setting

3.1 Sample data

The data set consists of foreign exchange rates of the US dollar, the Euro, and the Japanese yen from April 1st, 2013 to April 5th, 2013. Specifically, minute-level data of each trading day for 24 h is utilized. To give an idea of the large amount of data, one 24-h interval of currency trading data corresponds to 1-month of equity trading data on a 6–7 h time scale per day, and our data set includes bullish, bearish, and stable market states. Tables 1, 2, 3 show the descriptive statistics of the three currency pairs (JPY/USD, EUR/USD, and EUR/JPY). Figures 2, 3, 4 illustrate the market trend for these three currency rates. The volatilities of the respective currency rates are very different: 1.516 for JPY/USD, 0.006 for EUR/USD, and 2.497 for EUR/JPY. From this result, we observe that the Euro was more volatile than any other currency during the given period. When the returns (log return) of these currencies are examined, all show a clear mean reversion pattern in that the average of each asset approaches zero.

Table 1 Descriptive statistics of JPY/USD
Table 2 Descriptive statistics of EUR/USD
Table 3 Descriptive statistics of EUR/JPY
Fig. 2
figure 2

Market data for JPY/USD exchange rate

Fig. 3
figure 3

Market data for EUR/USD exchange rate

Fig. 4
figure 4

Market data for EUR/JPY exchange rate

3.2 Simulation settings

3.2.1 Genetic algorithm

In this research, there are three categories for the design variables describing the chromosome of length of 5 bits. The first specifies the range for the four technical indicators, which judge the buy, sell, or holding action. While most research for algorithmic trading mandates a specific numerical gateway for the indicators, this research allows the optimization algorithm to choose a variable within the range, the rationale being that the gateways of indicators for trading decisions are not logically clear. The second category is a Boolean operator (0 and 1) connecting the four indicators. The third category is the length of historical data used and the trading volume. This is because the optimal length of tick data and the volume of trading on the moving time axis is ambiguous considering the fluctuating market. This research used NSGA-II for multi-objective optimization and the detailed GA settings are shown in Table 4.

Table 4 Settings for genetic algorithm

3.2.2 Technical indicators

Various technical indicators are utilized in the trading market to forecast future trends. In regards to optimization, an algorithm should specify these gateways to predict the next bullish or bearish market. Table 5 provides the detailed information related to technical indicators and the genetic algorithm. Table 6 shows how the technical indicators and Boolean operators are connected. A holding position will be taken, when the numerical values are not within the buy or sell ranges.

Table 5 Technical indicators and GA
Table 6 Technical indicators and Boolean operators

3.2.3 Historical data and trading volume

In this work, the genetic algorithm optimizes the trading volume and the length of historical data used in calculating the technical indicators. Namely, this is because the recommended numerical values do not take into consideration the rapidly changing trading market. For the historical data used, the range of 1–20 time ticks is considered and the range of 1–20 for the trading volume is allowed as design variables for the genetic algorithm.

3.2.4 Objective functions

Three objective functions are employed: logarithmic profit, profit deviation, and maximum drop of the profit. The deviation and maximum drop are selected to observe a trade-off relationship with the profit. The profit deviation and maximum drop functions were selected to investigate their usefulness as risk management factors. As a benchmark test, a traditional index, the Sharpe Ratio is investigated with a single objective, genetic algorithm, to emphasize the necessity of multi-objective optimization in the trading algorithm. The transaction cost is set to 0.15%.

4 Simulation results

To demonstrate the necessity of multi-objective optimization, this paper provides three results for each preference of objective functions. For the simultaneous multi-optimization of algorithmic trading, we adopt a decision-making attitude for the next transaction, calling it a strategy or preference selection. Naturally, the accumulated profits will be different depending on the selected preference. To illustrate, a risk-taker considers profit critical, while a risk-adverse person will focus on risk management. As another example, some investors might change their position strategies from risk-adverse to risk-taking during trading hours. Such situations all demonstrate the importance of multi-objective optimization.

Figures 5, 6, 7 show logarithmic profits for each time tick on the time axis, thus showing that profit is volatile when the market is moving up from April 4th, 2013. Even though over the entire time period of interest, the exchange rate JPY/USD had a mean of 94.342 Yen and standard deviation of 1.516 Yen, our figures show that our data represents various levels of variability (low, medium, and high) across the signals of interest for the JPY/USD exchange rate. This same observation holds across the other exchange rates, i.e., EUR/USD and EUR/JPY have a mean and standard deviation of (1.286 Euro, 0.006 Euro) (121.341 Euro, 2.407 Euro), however, our figures show a wider range of variability over the time period of interest. As a result, our data sample represents the variability that can exist in these exchange rates and is suitable for our purposes.

Fig. 5
figure 5

Log profits of JPY/USD transaction

Fig. 6
figure 6

Log profits of EUR/USD transaction

Fig. 7
figure 7

Log profits of EUR/JPY transaction

Figures 8, 9, 10 provide a demonstration of the trade-off among the three objective functions. For example, in Fig. 8a, we provide the pairs of Log Profit (on the x-axis) and Standard Deviation of Returns (on the y-axis) that are attainable using our multi-objective optimization GA framework. Notice that the points form a Pareto optimal frontier. With these figures, we observe that non-dominated design points were successfully found using NSGA-II. The red point signifies the point on the frontier that attains the maximum profit. The figure also contains points that are Pareto dominated. The minus sign for the profit objective function is assigned since this relates to maximization, while other objective functions are being minimized. A risk-taking trader will select investment strategies generating the biggest profit such as trading position and trading volume. The results of this research clearly show the trade-off between profit and deviation. The deviation and maximum-drop, as objective functions, have a proportional relation. For the continuous simulation on the time axis, the red circles in Figs. 8, 9, 10 relate to profit maximization. In case of standard deviation and maximum-drop of the profit, the black circles will be selected.

Fig. 8
figure 8

Trade-off in optimization for JPY/USD

Fig. 9
figure 9

Trade-off in optimization for EUR/USD

Fig. 10
figure 10

Trade-off in optimization for EUR/JPY

Figures 11, 12, 13 show the accumulated profit of three currencies for the three objective functions and one objective function optimization as a benchmark test. In particular, in subfigure a, we show the impact of multi-objective GA using different preferences and in subfigure b, we show the result when instead single-objective GA is used. For example, in Fig. 11a, we see that using different preferences over time, we can attain a performance that is significantly better than the Sharpe ratio objective GA results in Fig. 11b. Different trading strategies induce different levels of profit as shown by the results under the optimization conditions of this paper with the profit-preference generating the biggest returns. The one caveat is that in the bearish market, the profit-preference incurs the negative profit, in particular, from April 1st to April 3rd for all three currency pairs. This phenomenon shows the necessity of risk management.

Fig. 11
figure 11

Accumulated profit of JPY/USD

Fig. 12
figure 12

Accumulated profit of EUR/USD

Fig. 13
figure 13

Accumulated profit of EUR/JPY

The preference that calls for minimizing the maximum-drop of profits can be regarded as a stable strategy. The weakness of this preference is that the profit is not relatively low in the bullish market compared against that of the other two preferences. The preference of standard deviation among objective functions shows an intermediate trading performance. In the bearish market, this preference minimizes damage, while still increasing profit. Additionally, the main reason that the profit-preference shows the large fluctuation in profits is that this strategy uses a higher trading volume, when a bullish market is detected. The simulation results show that the users of multi-objective optimization need to minimize the range of trading volume or change preference once a bearish market is continuously detected. In contrast, if a continuous bullish market lasts, the preference should be changed. This paper intentionally does not change these important factors to demonstrate the framework of multi-objective optimization. Using decision theory to optimally change the preferences is not within the scope of this paper.

In the benchmark simulation with the single-objective function of the Sharpe ratio, the accumulated profit is less than the results of the profit-preference and better than the results of the other two objectives. This result indicates that the profit-preference objective function should be employed as a primary strategy in a bullish market and the other two objective functions should be used in a bearish market. Simultaneously, this shows that proper preference changes with multi-objective optimization in the trading frame will obtain higher profits.

5 Conclusions and suggestions for future work

This research verifies the importance of multi-objective optimization by providing a framework for traders and investors to use multi-objective optimization with an evolutionary algorithm. In particular, this work focuses on finding trade-off relations among the three objective functions, in contrast to typical trading methods in the market, which pursue only a single-objective function such as the Sharpe ratio or only profit. Consequently, these methods either expose a high-risk impact in the bearish market or cannot pursue high profits in the bullish market. In addition, the optimization approach described in this paper does not begin with a specific trading volume or length of historical data, but instead allows the genetic algorithm to select the optimized numerical values in the evolutionary process. The fundamental idea behind this approach is that prefixed numbers can be strong constraints in the optimization case study, shrinking the pool of candidate solutions and eliminating good potential optimum values, which the multi-objective optimization approach has identified.

This research shows the advantages that multi-objective optimization provides against a single-objective function in an evolutionary algorithmic framework. In future research, we will extend the research scope as follows:

  1. 1.

    Employing other multi-objective optimization algorithms, not limited to NSGA-II.

  2. 2.

    Comparing simulation results on multi-objective optimization algorithms versus weighted average methods for objective functions.