The Forex Trading System for Speculation with Constant Magnitude of Unit Return

: The main purpose of this article is to investigate a speculative trading system with a constant magnitude of return rate. We consider speculative operations related to the exchange rate given as the quotient of the base exchange medium by the quoted currency. An exchange medium is understood as any currency or any precious metal. The unit return is deﬁned as the return expressed in the quoted currency by the amount of base exchange medium. All possible states of the exchange market form a ﬁnite elemental space. All knowledge about the dynamics of this market is presented as a prediction table describing the conditional probability distributions of incoming exchange rate changes. On the other hand, in the proposed trading system each speculative operation is concluded in such a way that the gross payment is determined by the given magnitude of unit return. The paper contains an analysis of the following evaluation criteria: annual number of transaction, success probability, expected unit payment, expected unit proﬁt, risk index, unit risk premium, return rate, interest rate, and interest risk premium. Both of these indices can be used to select the e ﬀ ective trading systems. E ﬀ ectiveness is considered in the local sense and in the global sense.


Introduction
Speculation is the purchase of an asset with the expectation that it will become more valuable in the near future [1]. Speculation is also the sale of an asset in anticipation of a decline in its price in the near future. In financial markets, the practice of speculation is to make financial transactions that allow speculators' earnings from short-term fluctuations in the market price of a traded financial instrument. The speculators' earnings do not result from the underlying attributes of financial instruments, such as fundamental indices, dividends, interest rates, or risk evaluations.
In this paper, we will focus on the subject of speculation by means of exchange medium given as any currency or any precious metal. This type of speculation is realized by means of speculative operations on the currency market. The Foreign eXchange market (FX) is a financial market characterized by frequent price changes. This is why trading on FX requires the use of high frequency trading (HFT) systems. HFT systems are becoming more popular due to development in the information technologies. Many currency speculators record losses. For example, the Polish Financial Supervision Authority reports that 83% of Polish currency speculators have incurred losses [2]. Similarly, the French Financial Supervision Authority reports that even 89% of French currency speculators have incurred losses [3]. Generally, currency speculators use well-known methods to manage speculative operations. The above data show that this is not an approach to achieving guaranteed profits. Hence, there is demand for a new, fully verifiable method of FX analyses that efficiently support speculative decisions [4].
HFT is also known in scientific literature as Algorithmic Trading. The existing body of literature on HFT is very extensive. It covers many thousands of important items devoted to very different

A General Model of Exchange Market
The scope of the paper will be the market of a change pair BEM/QCR noted in time [0, T], where BEM means the base exchange medium and QCR means the quoted currency. From the base exchange medium (BEM), we understand any base currency denoted by the abbreviation BCR or any precious metal denoted by thy abbreviation XPM. The current value of the exchange rate is noted in two prices: the Bid price (further denoted as Q Bid ) and Ask price (Q Ask ). Ask price of BEM is the unit price of the base exchange medium BEM in the quoted currency QCR. Bid price is the selling price, which reflects how much of the quoted currency QCR will be obtained when we sell one unit of BEM. In each moment of time t ∈ [0, T], we note the Ask price Q Ask (t) and the Bid price Q Bid (t). In this way we determine the exchange rate trends Q Ask : [0, T] → R and Q Bid : [0, T] → R , which describe the dynamics of an exchange pair BEM/QCR. In any moment of time t ∈ [0, T], Ask price is higher than Bid price, which can be shown as The changes on the market are characterized by a unit return, defined as a quotient of a return expressed in QCR by the amount of the BEM. The unit return ur(t , t ) of a BUY transaction opened in time t and closed in time t > t equals ur(t , t ) = Q Ask (t ) − Q Ask (t ). (2) In the further presented trading system, each operation opened in time t ∈ [0, T] will be closed as soon as possible in time t > t , which fulfils the following condition where δ > 0 is a given magnitude of unit return. In such situations, for fixed value δ > 0 the transaction concluded in time t ∈ [0, T] is closed in time t (δ) = t > t , determined by the equation t (δ) = t = min min τ > t : ur(t , τ) = δ , min τ > t : ur(t , τ) = −δ .
Closing the transaction in Equation (5) means the realization of "take profit" strategy (TP) when the Ask price has increased by the unit return δ. Closing the transaction in Equation (6) means the implementation of a "stop loss" strategy (SL) when the Ask price has decreased by the unit return δ.

The Description of FX
FX is the place where the exchange rate of the pair BEM/QCR is traded. All prices quoted on the FX are related to the BEM unit, which is dependent here on the type of BEM. For any base currency except Japanese Yen (JPY), the BEM unit is equal to a monetary unit. For JPY, the BEM unit is equal to 100 JPY. To any precious metal XPM, the BEM unit is equal to1 troy ounce (1 oz) of XPM. Major precious metals traded in the FX are gold recorded by its chemical symbol Au (from Latin aurum) and silver recorded by its chemical symbol Ag (from Latin argentinum). Gold is also marked by its market acronym XAU. Silver is also marked by its market acronym XAG.
On the FX, speculators use 1 lot defined as a standard measure unit for the amount of the base exchange medium BEM. To various BEMs, lots have different values, as described in Table 1. To any BEM, 1 lot has a distinct value expressed in QCR. In FX, a change in an exchange rate is expressed in the unit given as percentage in point (pip). For the main QCR, except JPY, one pip is equal to 0.0001 monetary units of QCR. For JPY, one pip is equal to 0.01 JPY. From the comparison of the lot definition and the pip definition, it follows that the price change by 1 pip causes the change of value of 1 BEM lot by 10 QCR units.
The transactions on the FX market are entered by brokers of the exchange market and speculators. FX brokers set their fees based on commission which equals the spread-the difference between a current Ask and Bid price. On FX of the BEM/QCR pair a speculator can give the broker two orders: BUY and SELL. The BUY order is executed with the Ask price Q Ask and it means buying BEM with QCR. The SELL order is executed with the Bid price Q Bid and it means selling BEM with QCR. Each of the SELL and BUY orders can be an open or close order. The amount of the orders is defined by the speculator and expressed in lots. If the value v of the order is expressed in pips, then it is calculated in the following way where L denotes amount of ordered lots, and Q apl denotes applied price equal to Q Ask or Q Bid . A speculator operating on FX of a BEM/QCR pair wants to achieve a profit due to an accurate prediction of a change of a chosen exchange rate. To achieve that goal, a speculator trades on FX. Each transaction consists of a transaction opening in time t and closing in a following time t > t . The only opening or closing orders can be BUY or SELL orders. A broker accepting an opening order is obliged to undertake the closing order.
In a moment t of opening the transaction the levels of Ask and Bid prices are represented by a pair (Q Ask (t ), Q Bid (t )) = Q Ask , Q Bid . Opening the order is accompanied by determining the value of the spread spr expressed in pips In a moment t of closing the transaction the levels of Ask and Bid prices are represented by a pair of (Q Ask (t ), Q Bid (t )) = Q Ask , Q Bid . The transactions concluded on the FX are settled in QCR. FX allows two positions: going long and going short.
The value of a spread spr depends on the offer of the broker. On the FX, the moment t of closing the transaction generally occurs soon after the moment t of opening the transaction. Therefore, we will assume that spread spr is constant in the time interval [t , t ]. Then, we can write This condition is almost always satisfied. If in the opening moment t the speculator expects the increase of the exchange rate of the BEM/QCR pair then they place a BUY order L lots in Ask price Q Ask . In this way, the speculator takes the long position. Taking a long position means that in a determined closing time t the speculator places a SELL order with a Bid Q Bid price. Due to that transaction the speculator gains the transaction settlement equal to where the settlement value y l is expressed in pips. Taking a long position is profitable only for y l > 0. Then, from Equations (10) and (11), we obtain which is equivalent to the profitability criterion If in opening moment t the speculator expects a decline in the exchange rate of the BEM/QCR pair, then they place a SELL order L lots in a Bid price Q Bid . In this way the speculator takes the short position. Taking a short position means that in a determined closing time t the speculator places a closing BUY transaction with the Ask Q Ask price. Due to that transaction the speculator obtains the transaction settlement equal to where the settlement value y s is expressed in pips. Taking a short position is profitable only for y s > 0. Then, from Equations (9) and (14), we obtain which is equivalent to the profitability criterion in Equation (13). Fulfilling the condition in Equation (5) means that the Ask price has increased by the unit return where ∆ is the assumed magnitude of unit return expressed in pips. Such assumed rise in Ask price is denoted by the symbol I + ∆ . Fulfilling the condition in Equation (6) means that the Ask price has decreased by the unit return It is an opposite event for I + ∆ and it is denoted as I − ∆ . Describing the mechanism of FX, we can distinguish the space S = s j : j = 1, 2, . . . , m of the possible states achieved by this market. Unambiguous definitions of states depend on the adopted method of forecasting changes in an exchange rate. An example of the explicitly defined space of states is given in Section 4. More examples of the explicitly defined different space states are found in previous works [14][15][16][17][18][19].
We observe a continuous trend of the fixed exchange rate noted in time [0, T]. If a single trend observation begins at the moment t , then it ends at the moment t , satisfying the condition in Equation (3). The first trend observation begins at the moment t 0 = 0. We assume that the observation process is continuous. This means that at each moment of ending the observation, we open the next one. Therefore, the sequence (t i ) n−1 i=0 ⊂ [0, T] of observation opening moments is recursively determined as follows: The sequence (t i ) n−1 i=0 defined in this way is a record of the history of observation opening moments. For this reason, the sequence (t i ) n i=0 = Θ is called an observation record Θ for short.
Let us take into account fixed observation record Θ. Each moment t i ∈ Θ of the opening of the observation is related to the observed current state s i = s(t i ) of FX. The total number of these observations is equal to n > 0. In this way we can create a sequence ( s i ) n i=0 of observed FX states. The sequence ( s i ) n i=0 defined in this way is a record of the history of changes in FX states. For this reason, the sequence ( s i ) n i=0 = Ξ is shortly called a state record Ξ. It is shown above that the state record Ξ is dependent on the observation record Θ.
Each state s j ∈ S is possible. Therefore, we can assume that it is observed exactly n j > 0 times.
The sequence n j m j=1 of random numbers is explicitly determined by the state record Ξ. Thanks to this, for each state s j we can establish the conditional probability of the occurrence of state s j .
For any pair (t i , t i+1 ) ⊂ Θ, the symbol I i+1 = I (t i+1 ) denotes the observation of the Ask price change in the time interval [t i , t i+1 ]. If the unit return ur(t i , t i+1 ) satisfies Equation (16) then we put I i+1 = I + ∆ . If the unit return ur(t i , t i+1 ) satisfies Equation (17) then we put I i+1 = I − ∆ . In this way, to each observed state s i we assign an Ask price change I i+1 that it is observed after that the state s i has occurred. The sequence I i+1 n−1 i=0 defined in this way is a record of the history of changes in Ask price trend. For this reason, the sequence I i+1 n−1 i=0 = Ψ is shortly called a trend record Ψ. It is shown above that the trend record Ψ is dependent on the observation record Θ. In the proposed model of trading, the sequence s(t i ), I (t i+1 ) : t i ∈ Θ\{t n } plays a role of training dataset [22].
Let us assume that observations I i+1 are independent. The results of previous pilot studies [14][15][16][17][18][19] are consistent with the above assumption. Therefore, we can say that the trend record Ψ is a Bernoulli sequence. From a financial point view, the trend record Ψ is an observation of a considered unit return process. It implies that the unit return process is stationary. For any state s j ∈ S the subsequent Ψ j = I i+1 : s i = s j ⊂ Ψ is also a Bernoulli sequence. From the symbol n * j we denote the number of elements of sequence I i+1 ∈ Ψ j : I i+1 = I + ∆ . Let us note that the sequence for any state record Ξ, the sequence n * j m j=1 , is a sequence of random numbers. Nevertheless, let us note that the sequence n * j m j=1 is explicitly determined by trend record Ψ. Moreover, for the fixed state record Ξ, the sequence n j m j=1 is a sequence of deterministic numbers. Then, for each state s j we assign a conditional probability of assumed rise in Ask price immediately after that the state s j has occurred. The confidence interval of a sample statistic, as in Equation (21), is given as the Wald confidence interval [23], which will be applied in Section 5. It is a commonly used approach to approximate the binomial confidence interval for success probability estimation with asymptotic normal distribution [23]. This approach is based on the central limit theorem. This means that the proposed approximation is reliable when the sample size is large enough (i.e., greater than 30) and the success probability is not close to 0 or 1 [24]. All results of the pilot studies [14][15][16][17][18][19] are consistent with the above conditions. The set of triples below P(BEM/QCR, ∆, S, Ξ, Ψ) = n j , p s j , p I + ∆ s j : s j ∈ S, = 1, 2, . . . , m = n j , p s j |Ξ , p I + ∆ s j , Ξ, Ψ : s j ∈ S, j = 1, 2, . . . , m forms the prediction table to foresee the changes of the exchange rate of the BEM/QCR pair. In this way, the above prediction table is the image of our knowledge on the market of the BEM/QCR pair. On the other hand, if we take into account fixed prediction table P(BEM/QCR, ∆, S, Ξ, Ψ) then all probabilities are determined by the same records Ξ and Ψ. Then, for greater clarity, we can omit the symbols Ξ and Ψ in determining the probabilities saved in the prediction table P(BEM/QCR, ∆, S, Ξ, Ψ). The method of this omission is indicated in Equation (22). Each state s j can be a prediction premise. The total probability p I + ∆ of rise in Ask price can be determined as The above probability is interpreted as the probability of the assumed rise in Ask price immediately after any state has occurred.
One example FX state space and related prediction table can be found in the next section.

Price Trend Binarization as A Tool for Determining FX State Space
In a previous study [15], a binary representation was proposed in order to perform a more accurate analysis of the exchange rate trend. This kind of representation was inspired by the historical point-symbolic method [25].
The binary representation of the trend Q Ask : [0, T] → R consists of transforming this trend into a binary sequence E = (ε i ) n i=1 of values describing, respectively, ensuing decreases and increases of assumed magnitude of unit return ∆, which is used by Stasiak [15] as the discretization unit. The sequence E is called a binary representation. For the assumed discretization unit ∆, the sequence E = (ε i ) n i=1 is given as follows: One should note that in the case of the binary representation we can define what changes will not be analyzed (the ones lower than the discretization unit). In the general case, the binary representation E depends on the assumed discretization unit ∆, expressed in pips, and the time interval [0, T] of trend observation, which can be written as E(BEM/QCR, ∆, T) for the considered exchange pair. The binary representation defined in this way is a record of the history of changes in the Ask price trend. Therefore, any binary representation E(BEM/QCR, ∆, T) may be applied as a trend record Ψ. It is obvious that any binary representation is compatible with system of short and long positions described in Section 3.
The number n of binary observations contained in the binary representation E(BEM/QCR, ∆, T) = (ε i ) k i=1 depends on the assumed discretization unit ∆ and the length T of the observation interval. In line with Equation (7), with the increase of the discretization unit, the number of binary representations diminishes.
For a set observation range m of the historical observation, we define the state space E c of all c-character binary states as the set of all c-character permutations with repetition from the set {0, 1}. Each state represents a possible observation of the preceding m-element subsequence of the binary representation. The state space E c consists of exactly 2 c states determined as follows where Example 1. In this paper, we will use the following sample state space Each moment of the observation beginning is attributed to an observed state of exchange pair market. In this way we can create a sequence (28) of following observations of market states. Then the set of triples is the prediction table obtained with use of the Equations (16), (19), and (22).

Example 2.
In this paper, all considerations will be illustrated by an example [26] of speculations in exchange pair silver (Ag) quoted in U.S. dollars (XAG/USD). We take into account the space E 4 as a space of all possible states of FX for XAG/USD. Tick data containing quotations of XAG/USD from a five-year time period (5Y) December 31, 2012, to January 1, 2018, are collected by Dukascopy broker. The appointed discretization unit ∆ = 28 pips is justified in a previous study [26]. For this discretization unit, the observation record (18) and (19). The time period from December 31, 2012, to January 1, 2018, contains about 1250 trading days. We see that, on average, we open more than one observation per trading day. If we use tick data, then this situation is almost certain because the frequency of observation opening is determined by dependence on Equation (19). Using the observation record Θ 1 , we determine the state record Ξ 1 . Moreover, we transform quotations of XAG/USD into binary representation given by Equation (24). Table 2 presents a prediction table P(XAG/USD, 28, E 4 , Ξ 1 , Ψ 1 ) The last row in Table 2 shows the following: a total number of observations n and a total probability p I + 28 of assumed rise in Ask price. The probability p I + 28 is calculated using Equation (23). We see that speculation in XAG/USD without any supporting transaction strategy is an unpredictable lottery.
Example 3. Some results obtained for speculations in the XAG/USD pair will be compared with results obtained for speculation in the exchange pair of gold (Au) quoted in US dollar (XAU/USD). Therefore, we use the space E 4 as a space of all possible states of FX for XAU/USD. Tick data containing quotations of XAU/USD from a five-year time period (from December 31, 2012, to January 1, 2018) were obtained from Dukascopy broker. The appointing the discretization unit ∆ = 30 pips is justified in a previous study [24]. For this discretization unit, the observation record (18) and (19). We see that, on average, we open more than fifteen observations per trading day. If we use tick data, then such a situation is possible because the frequency of observation opening is determined by dependence on Equation (19). The observations of FX for XAU/USD are more frequent than the observations of FX for XAG/USD. This phenomenon results from the fact that FX for XAU/USD is more liquid than FX for XAG/USD. Using the observation record Θ 2 , we determine state record Ξ 2 . Moreover, we transform quotations of XAU/USD into binary representation Ψ 2 = E(XAU/USD, 28, 5Y) = {ε i } 18818 i=1 given by (24). For the assumed value of discretization unit ∆ = 30 pips Table 3 presents a prediction table P(XAG/USD, 30, E 4 , Ξ 2 , Ψ 2 ). The last row in Table 3 shows the following: a total number of observations n and a total probability p I + 30 of assumed rise in Ask price. The probability p I + 30 is calculated using Equation (21). We see that speculation in XAU/USD without any supporting transaction strategy is an unpredictable lottery.
Other informal models of binary representation of Ask price trend are shown in previous studies [16,17]. These observations of Ask price trend can also be conducted in another adequate method for a stated magnitude of unit return ∆.

The Proposed Speculative Trading System
Since the market operates 24 hours a day, 5 days a week, placing the orders manually is tiresome, and regarding short-term transactions simply impossible. In such cases, HFT systems are very helpful. HFT is a trading platform that uses powerful computers to transact a large number of orders at very fast speeds, which operate speculative strategies.
In most HFT systems the signals to open or close a particular position are created via the analysis of ratios. A popular trading system places orders when two average lines intersect: short-and long-term average of quotations. The system is based on two decision-making rules: • If the short-term average of quotations intersects with a higher long-term average, then place a BUY order; • If the long-term average of quotations intersects with a higher short-term average, then place a SELL order.
An important reason why systems based on moving averages are popular among practitioners is the fact that they capture over-reactions of market participants to some financial and economics events, which is a well-known stylized fact [27]. On the other hand, investment decisions made in the above-mentioned trading systems are characterized by a lack of explicitly determined potential payments. This causes the systems based on moving averages to be sensitive to non-constant volatility of a price process. This aspect makes the investment strategy analysis and money management more difficult.
In contrast, regulated transactional systems, which have prior stated payments, are devoid of that disadvantage. For each single transaction conducted by a regulated transactional system, one needs to state in advance the following: • The Q TP price, which closes the transaction with a profit (TP rule); • The Q SL price, which closes the transaction with a loss (SL rule). Any regulated transactional system is insensitive to non-constant volatility of a price process. This is the predominance of regulated transactional systems over systems based on moving averages.
The trading systems based on moving averages systems are associated with two well observable decision-making grounds. The proposed regulated transactional system is associated with a greater number of decision-making premises given as well-observable states achieved by FX. An example of such states is presented in Section 4. It causes the situation in which future changes in the exchange rate will be predicted more accurately. This property reduces the investment risk. This is another advantage of the proposed transactional system over systems based on moving averages.
A proposal of a regulated transactional system which satisfies Equation (3) will be presented below. According to that condition and the profitability criterion in Equation (13), the proposed system should also satisfy the following condition We take into account fixed the exchange pair BEM/QCR. In a general case, the proposed transactional system is determined for any prediction table P(BEM/QCR, ∆, S, E, Ψ) where the trend record Ψ is given as a binary representation. This prediction table may be a decision-making premise for any transactional system fulfilling the Equations (3) and (30).
System operation is dependent on assumed threshold Thr ≥ 0.5, which is set by a person using this system. For example, this person may be a speculator. For each state s j ∈ S, the proposed transactional system contains the four following decision-making rules: is satisfied then place a BUY order and go long. (B) If the condition is satisfied then place a SELL order and go short.
(C) If the Equations (31) and (32) are not satisfied then WAIT for the occurrence of another state of FX.
(D) If the transaction was opened with the Ask price C Ask and a current Ask price C Ask satisfies Equation (30), then close the opened transaction.
Each state s j satisfying Equations (31) or (32) is called an acceptable premise. For a given decision threshold Thr ≥ 0.5 a set constitutes a set of all acceptable premises. Let us note that we have D(0.5) = S. The rules (A) and (B) determine the function S · Thr : D Trh ·{BUY, SELL} given by the identity The above function determines the transaction strategy, which together with the transaction-making rules © describes our proposed probabilistic transaction-making (PTM) system. A multiple-use PTM system is a particular type of HFT system. When the opening transaction is determined by the strategy in Equation (34) and this transaction is closed under the condition in Equation (30), then such a transaction is a speculative operation, i.e., a financial operation using short-term price fluctuations to earn a profit.
Let us consider potential payments that are possible to achieve in the PTM system after opening the standard order 1 lot. Therefore, in Equation (14) we substitute L = 1. Let us assume that there is an increase of the Ask price quotation Q Ask > Q Ask . In such a case in the PTM system between the prices Ask and Bid, the following dependencies occur If the speculator placed a SELL order, in this case according to Equation (14) the payment expressed in pips will equal In the case of placing a BUY order, according to Equations (10) and (11) the payment expressed in pips will be as follows Let us assume that there is a decline in the Ask price quotations Q Ask < Q ask . In this case in the PTM system, between the prices Ask and Bid and Equation (35), the following equation occurs If the speculator placed a SELL order, then in this case, according to Equation (14) the payment will be In the case of placing a BUY order, according to Equations (10) and (11) the payment expressed in pips will be as follows Finally, let us note that the value of any payment does not depend on the Ask price Q Ask noted in the moment of opening the order.
Additionally, let us assume that the speculator, when opening the transaction, observes the current decision-making premise s j ∈ D Trh characterized by a conditional probability p I + ∆ s j of the increase in exchange rate by a given magnitude of unit return equal to ∆.
If Equation (31) is satisfied, then the investor places a BUY standard order for 1 lot. According to Equations (38) and (40), the payment is then given as a random variable with the probability distribution If Equation (32) is satisfied, then the investor places a SELL standard order for 1 lot. According to Equations (37) and (41), the payment is then given as a random variable with the probability distribution Let us take into account a PTM system determined for a fixed state space S, where its transaction strategy is dependent on set threshold Thr ≥ 0.5. For this PTM system, we analyze the payment obtained by means of a single speculative operation on 1 lot of base exchange medium BEM. All of the above considerations show that the analyzed payment depends only on the value of spread spr and the magnitude of unit return ∆. To illustrate those facts, the considered PTM system, which initiates a speculative operation with a magnitude of unit return ∆ and bearing the spread spr, will be denoted as PTM Thr, ∆, spr S , where the values of ∆ and spr should be given in pips.
If we are going to use the system PTM Thr, ∆, spr S for speculations in the exchange pair BEM/QCR then it should be linked with the prediction table P(BEM/QCR, ∆, S, Ξ, Ψ), which is the image of our knowledge on the market of the exchange pair BEM/QCR. In this way, we determine the speculative trading (ST) system as the pair ST BEM/QCR, Thr, ∆, spr, S, Ξ, Ψ = PTM Thr, ∆, spr S , P(BEM/QCR, ∆, S, Ξ, Ψ) (44) Example 4. In Example 2, we consider the exchange pair XAG/USD. Then, the mechanism of FX is described by prediction table P(XAG/USD, 28, E 4 , Ξ 1 , Ψ 1 ), presented in Table 2. For the exchange pair XAG/USD, one of the more popular brokers ICMarkets offers the spread spr = 1 pip. This implies that the prediction table P(XAG/USD, 28, E 4 , Ξ 1 , Ψ 1 ) may be linked with the PTM system PTM Thr, 28, 1 E 4 applied on the exchange pair XAG/USD market. In this situation, all following examples will be carried out for the pair of XAG/USD using the ST XAG/USD, Thr, 28, 1, E 4 , Ξ 1 , Ψ 1 system. The subject of the consideration will be the transaction related with the standard order 1 lot XAG =1000 oz Ag. Let the decision-making premise be given as a s 6 state. The probability of a currency exchange rate growth is then given by p(I 28 |s 6 ) = 0.5897 . Then, a BUY order is placed, and according to Equation (42), the probability distribution of payments is as follows: (27 pips; 0.5897), (−29 pips; 0.4103) Let the decision-making premise be given by the state s 8 . The probability of a currency exchange rate growth is then given by p(I 28 |s 8 ) = 0.4146. Then, a SELL order is placed, and according to Equation (43), the probability distribution of payments is as follows: (27 pips; 0.5854), (−29 pips; 0.4146) To enable a more straightforward analysis, closing the order with a positive payment will be considered a success. According to Equations (40)-(43), the probability π s j of successfully finishing the transaction realized due to an observation of a current premise s j equals π s j = max p I + ∆ s j , 1 − p I + ∆ s j .
The probability π s j will be called the success probability. The success probability enables one to assess the expected payment on the entered transactions due to the indications of a given prediction table.
Equations (42), (43), and (45) imply that for any acceptable premise s j ∈ D Trh the payment gained after closing any transaction is given as a random variable with the probability distribution A positive expected payment is identified with an expected profit. Let us establish an infimum π up of success probability π I ∆ s j , which guarantees that the PTM Thr, ∆, spr S trading system will ensure an expected profit. This condition is presented by the following strict inequality π s j ·(∆ − spr) + 1 − π s j ·(−∆ − spr) > 0.
After elementary transformations we get: The value π up is the infimum of acceptable success probability. Obviously, any transaction-making threshold Thr should satisfy the following condition Therefore, the set D π up is the maximal set of acceptable premises.
Let us assume a fixed value α of a significance level. For any acceptable premise s j ∈ D π up , the (1 − α)−level Wald left-hand interval of confidence is given by the equation where z α is the α quantile of a standard normal distribution and the number n j is defined above in Equation (16). Using the Wald confidence intervals, we distinguish the following kind of acceptable premises. For assumed α−level of confidence, if acceptable premise s j ∈ D π up fulfils the condition then it is called a well-justified premise. Other acceptable premises are called ill-justified ones. Any value w j plays the part of critical values for testing a justification of acceptable premise s j . Therefore, it will be called a critical justification line. For any well-justified premise, the probability of placing an erroneous order is less than or equal to an assumed value α of significate level. For ill-justified premises, this probability increases. Undertaking an investment decision under the influence of an ill-justified premise is very risky. Therefore, when it is possible, ill-defined premises should be avoided.

Example 5.
For the speculation in the pair XAG/USD, we can apply the PTM system PTM Thr, 28, 1 E 4 described in Example 4. Then, we have the infimum of acceptable success probability π up = 0.5179. The maximal setD(0.5179) of all accepted premises, the sequence of critical justification values, the distribution of success probability, and the transaction strategy are presented in Table 4. Because 1 − π up = 0.4821, we distinguish ill-justified acceptable premises marked with an asterisk. All of the above results describe the ST system ST(XAG/USD, 0.5179, 28, 1, E 4 , Ξ 1 , Ψ 1 ).

Example 6.
In Example 3, we consider the exchange pair XAU/USD. Then, the mechanism of FX is described by prediction table P(XAG/USD, 30, E 4 , Ξ 2 , Ψ 2 ) presented in Table 3. For the exchange pair XAU/USD, one of the more popular brokers ICMarkets offers the spread spr = 1.5 pip. This implies that the prediction table P(XAG/USD, 30, E 4 , Ξ 2 , Ψ 2 ) may be linked with the PTM system PTM Thr, 30, 1.5 E 4 applied on the exchange pair XAU/USD market. Then, we have the infimum π up = 0.525 of acceptable success probability. The maximal set D(0.525) of all accepted premises, the sequence of critical justification values, the distribution of success probability, and the transaction strategy are presented in Table 5. Because 1 − π up = 0.475, all acceptable premises are well-defined. In this situation, all following examples will be carried out for the pair of XAU/USD using the ST(XAU/USD, 0.525, 30, 1.5, E 4 , Ξ 2 , Ψ 2 ) system. The subject of the consideration will be the transaction related with standard order of 1 lot XAU =100 oz Au.

Local Evaluation of Speculative Trading System
The effectiveness of a financial instrument means the ability to achieve possible large benefits in conditions of possible low risk. The "effectiveness of financial tools" may be equivalently called "financial effectiveness".
HFT systems are specific financial instruments. An important element of each transaction-making process in any market is the proper choice of an effective trading system. The realization of that choice should be accompanied by a set of criteria selected in advance. Garcia et al. [28] and Li et al. [29] point to the HFT system features that should be evaluated. Evaluating any PTM system, we implement their proposals using following notions. We take into account their proposals.
The success probability is a probability that any placed order will be closed with profit. Unit payment is the payment obtained by realization of a single speculative operation on 1 lot of base exchange medium BEM. The expected unit payment is defined as the expected value of the unit payment. Continuous realization of speculative operation means that after closing the transaction, we open the next one with the same value of the base exchange medium BEM. The moment of closing the previous transaction and the moment of opening the next transaction may be separated by a period of waiting. Annual unit profit is the sum of all unit payments obtained during one year by continuous realization of single speculative operation on 1 lot of BEM. The expected unit profit is defined as the expected value of annual unit profit. The above concepts are used as the basis for the following benefit evaluation criteria: • an expected annual number of transactions; • a success probability; • an expected unit payment; • an expected unit profit.
Let the given fixed state record Ξ and binary representation be Ψ = E(BEM/QCR, ∆, T). To evaluating any ST system ST BEM/QCR, Thr, ∆, spr, S, Ξ, Ψ , we can use the following benefit indices: • the expected annual number N Trh of transactions calculated by the formula where n j is a number of annually calculated observations of the state s j collected during construction of the prediction table. • the success probability π D Thr can be presented as π D Thr = s j ∈D(Trh) p s j ·π s j s j ∈D(Trh) p s j ; (53) • the expected unit payment expressed in QCR units † Thr, ∆, spr = 10· π D Thr ·(∆ − spr) + 1 − π D Thr ·(−∆ − spr) = 10· 2·π D Thr − 1 ·∆ − spr ; • the expected unit profit Y Thr, ∆, spr = N Trh · † Thr, ∆, spr .
Remark 1. If we calculate the expected unit payment expressed in JPY then we should remember that for JPY, the QCR unit is equal to 100 JPY.
Equations (52)-(55) evaluate the benefits obtained by the use of the ST BEM/QCR, Thr, ∆, spr, S, Ξ, Ψ system. Along with the increase in the value of the criteria index, the effectiveness of the ST system grows. Equations (52) and (53) are independent of market conditions represented by the spread. This is a drawback of those criteria. Equations (54) and (55), which represent the most comprehensive assessment of the earnings resulting from ST system exploitation, are devoid of those disadvantages. On the other hand, Equation (52) evaluates only a single payment. This is a drawback of this criterion because for any ST system HFT is used many times in a year. In addition, Equation (55) is a substantively justified function of the indices in Equations (52)-(54). This all implies that Equation (55) should be used by the speculators to maximize their benefits.
We understate the term risk as a possibility of negative consequences of performed actions. Risk described this way is, in fact, a phenomenon occurring independently from the existing state of knowledge. In this situation, our risk model cannot be identified with the quantified uncertainty defined by Knight [30] as a specified state of knowledge. From the time of Knight's famous work, the evolution of mathematical instruments implies that the term of uncertainty has also evolved.
In the considered case, we understate the speculator's risk as the possibility of incurring losses as a result of placing an inaccurate order. Each risk occurrence also must have its cause. In general, the speculator's risk is a result a lack of knowledge about the future Ask prices. Here, we consider the risk incurred by a speculator applying any PTM system. Then, incomplete knowledge on future Ask prices is described by Equation (19) as the distribution of conditional probability of assumed rise in Ask price. Then, for each acceptable premise s j ∈ D Trh , the distribution of probability of assumed rise in Ask price is determined as follows where the value π s j is success probability determined by Equation (45). If the acceptable premise s j occurs then the possibility of placing an inaccurate order increases with rise in value ς s j = − π s j · ln π s j + 1 − π s j · ln 1 − π s j (57) of Shannon's entropy [31], determined for the probability distribution in Equation (52). Therefore, if the acceptable premise s j occurs, then the Shannon's entropy may be used as a characteristic of the speculator's risk. On the other hand, here Shannon's entropy is a random variable. For this reason, we determine the risk index as expected Shannon's entropy. A unit risk premium is always determined as the ratio of expected annual unit profit by applied risk index. For each ST BEM/QCR, Thr, ∆, spr, S, Ξ, Ψ system the risk index is calculated as E Thr, ∆, spr = s j ∈D(Trh) p s j ·ς s j ln 2· s j ∈D(Trh) p s j .
In order to normalize the risk index, the value ln 2 is added in the denominator. The effectiveness of any ST system increases along with the decrease of the criterion index in Equation (58). In summary, for each ST BEM/QCR, Thr, ∆, spr, S, Ξ, Ψ system, its effectiveness on the BEM/QCR market should be evaluated by a pair of Y Thr, ∆, spr , E Thr, ∆, spr .
The financial effectiveness increases along with the increase of expected unit profit and with the decrease of systemic risk index. Therefore, the subset of effective ST systems may be distinguished as the Pareto's optimum determined as a two-criteria comparison of maximization expected of unit profit and minimization of risk index. Using the pair in Equation (59), we can evaluate the effectiveness of trading systems used on the fixed BEM/QCR market. This kind of evaluation we will call local evaluation of financial effectiveness. The effectiveness of the system ST BEM/QCR, Thr, ∆, spr, S, Ξ, Ψ can also be simplified by means of unit risk premium B Thr, ∆, spr = Y Thr, ∆, spr E Thr, ∆, spr .
The maximization of the unit risk premium in Equation (60) may be used as a supporting criterion of local choosing of the most effective ST system.

Example 7.
We locally evaluate the effectiveness of the ST system ST(XAG/USD, 0.5179, 28, 1, E 4 , Ξ 1 , Ψ 1 ) described in Example 5. The speculator intends to increase the value of the transaction-making threshold Thr to 0.55. In order to examine the desirability of such a change, we compare the local evaluations of the effectiveness of systems ST(XAG/USD, 0.5179, 28, 1, E 4 , Ξ 1 , Ψ 1 ) and ST(XAG/USD, 0.55, 28, 1, E 4 , Ξ 1 , Ψ 1 ). Complete evaluations of these systems are presented in Table 6. The results collected in the table above illustrate the fact that the increase in the decision-making threshold Thr causes an increase in the success probability and a simultaneous decrease in the expected annual number of transactions. All of this leads to the conclusion that in observed cases, the increase in Thr causes a simultaneous decrease in the expected unit profit and the risk index. This means that in the considered case, both the systems ST(XAG/USD, 0.5179, 28, 1, E 4 , Ξ 1 , Ψ 1 ) and ST(XAG/USD, 0.55, 28, 1, E 4 , Ξ 1 , Ψ 1 ) are locally effective on the market of the exchange pair XAG/USD. We recommend the ST system ST(XAG/USD, 0.5179, 28, 1, E 4 , Ξ 1 , Ψ 1 ) due to its higher unit risk premium. In Example 4, it is proved that the transactional systems ST(XAG/USD, 0.5179, 28, 1, E 4 , Ξ 1 , Ψ 1 ) and ST(XAG/USD, 0.55, 28, 1, E 4 , Ξ 1 , Ψ 1 ) undertake the investment decisions under influence of ill-justified premises, marked with an asterisk.

Example 8.
We compare the effectiveness of the system ST(XAU/USD, 0.525, 30, 1.5, E 4 , Ξ 2 , Ψ 2 ) described in Example 6 with the systemST(XAU/USD, 0.55, 30, 1.5, E 4 , Ξ 2 , Ψ 2 ). The locally evaluated financial effectiveness is a sufficient tool for this comparison. Complete evaluations of these systems are presented in Table 7. The results presented in the table above illustrate the fact that with the increase of the decision-making threshold Thr, we observe an increase in the success probability of transactions, and a simultaneous decrease in the expected annual number of transactions. All of this leads to the fact that in the observed cases, the increase of the Thr causes a simultaneous decrease in the expected unit payment and the risk index. This means that in the considered case, both DST(XAU/USD, 0.525, 30, 1.5, E 4 , Ξ 2 ) and ST(XAU/USD, 0.55, 30, 1.5, E 4 , Ξ 2 , Ψ 2 ) systems are locally effective on the market of the exchange pair XAU/USD. We recommend the ST system ST(XAU/USD, 0.525, 300, 15, E 4 , Ξ 2 , Ψ 2 ) because of it being characterized by higher unit risk premium.
The results obtained in Example 8 cannot be compared with the results obtained in Example 7, because the price of 1 lot of gold usually differs significantly from the price of 1 lot of silver. In the next section, we will return to the problem of comparison of ST systems used for various exchange pairs.
Because the set of acceptable premises D(0.5) ⊂ S is equal to the state space S, any prediction table P(BEM/QCR, ∆, S, Ξ 2 ) may be evaluated by means of evaluation of effectivities of ST system ST(BEM/QCR, 0.5, ∆, 0, S, Ξ 2 ). Thanks to this rating, we can choose the best value ∆ of magnitude unit return or the most suitable kind of state space S.

Global Evaluation of Speculative Trading System
In this chapter we will compare the ST systems used on the markets of different exchange pairs. Let us take into account the systems and For the exchange pair BEM x /QCR x , x ∈ {a, b}, the current value v BEM x /QCR x of 1 lot of base exchange medium BEM x is expressed in quoted currency QCR x . The current lot value v BEM x /QCR x is calculated by means of Equation (8), where applied price is current Ask price Q Ask of BEM x . For the exchange pair, the current lot value v BEM x /QCR x is directly proportional to the value of financial means engaged by the speculator in a single speculative operation on 1 lot of BEM x . The identities in Equations (54) and (55) show that for any ST system, its expected unit payment and unit profit do not depend on current Ask price Q Ask of BEM x . This implies that effectiveness of any ST system decreases with the increase of current lot value v x . It is obvious that the different exchange pairs have different lot values v BEM x /QCR x . Because of this, the expected unit payment in Equation (54) and expected unit profit in Equation (55) cannot be applied for comparison of ST a and ST b systems. Then, for the ST system ST x , the indices in Equations (54)-(56) should be respectively replaced by following characteristics: • the expected return rate where † Thr x , ∆ x , spr x is the expected unit payment calculated by Equation (54) for ST x ; • the expected interest rate where Y Thr x , ∆ x , spr x is the expected unit profit calculated by Equation (55) for ST x ; • the interest risk premium where B Thr x , ∆ x , spr x is the unit risk premium calculated by Equation (60) for ST x .
The index in Equation (63) may be used by speculators to maximize their benefits. In an analogous way as in the previous section, we can justify that the effectiveness of the ST x system can also be globally evaluated by the pair where E Thr x , ∆ x , spr x is the risk index calculated by Equation (64)  Global evaluations of effectiveness of the systems ST(XAG/USD, 0.5179, 28, 1, E 4 , Ξ 1 , Ψ 1 ) and ST(XAG/USD, 0.55, 28, 1, E 4 , Ξ 1 , Ψ 1 ) are presented in Table 8. The FBS broker has also reported that on December 28, 2018, the gold price was $1284.55 per troy ounce [30]. Using Equation (8) we obtain that for Au the current lot value is as follows v XAU/USD = 100 oz·$1284.55 = $128, 455.
In the case of speculation possibilities on different exchange pair markets, the hyperspace of all globally effective ST systems can be obtained as a Pareto optimum in a two-criteria comparison of Equation (64). Among other things, in this way we can choose the optimal BEM/QCR market. Nevertheless, we should remember that global comparison of financial effectiveness achieved on the BEM 1 /QCR 1 market with the financial efficiency achieved on the BEM 2 /QCR 2 market is only valid for a short time, in which the exchange rate QCR 1 /QCR 2 is approximately constant.

Conclusions
In this paper, we proposed a trading system ST dedicated for FX. There, the closing of any open transaction is dependent on the observed unit return. For this reason, the gross payment from ST is determined by unit return. To our best knowledge, from the point of view of quantitative finance, the criterion of the constant magnitude of a unitary return is completely new. Therefore, we can say that the ST system proposed by us is a fully original HFT system for FX.
The ST system proposed in the paper is an intense extension of the HFT system presented in a previous paper [21]. Any ST system is based on the assumption that the considered unit return process is stationary. This assumption is justified in Section 3. Moreover, the proposed ST system is insensitive to the non-constant volatility of a price process. An important advantage of any ST system is a relatively low numeric complexity of an automatic algorithm making the transactional decisions, which is vital due to the fact that all the calculations must be executed in real time.
Any ST system is linked with a given prediction table describing the stochastic mechanism of the fixed exchange market. The parameters of this prediction table may be optimized with use of local efficiency of the linked ST system. In Section 3, we apply some procedure of determining the prediction table using the training data set. Therefore, when obtained in this way the prediction table should be checked using test data set. From the point-of-view of the speculator, the most rational method for this check will be to compare the return rates obtained with the return rates predicted by Equations (54), (55), (63), and (64).
The elaborated criteria of evaluation of financial effectiveness can be useful to choose optimum parameters of effective ST systems. We anticipate that in the future we will compare our transaction system with the existing transactional system. This research attempt is obvious for us. Such comparisons can be made using the universal statistical methods described in a previous study [33]. However, these comparisons must be preceded by the determination of optimal system parameters. Such parameters must be set differently for each exchange rate trend. We are preparing to undertake such labour-intensive research.
In the case of only one exchange pair market, the hyperspace of all locally effective ST systems can be appointed as the Pareto optimum in a two-criteria comparison of Equation (57).
All of those possibilities of the implementation of the proposed trading system assessment criteria constitute the added value of that paper. On the other hand, the proposed evaluation criteria are independent of invested quotes engaged by the speculator in a single speculative operation. Therefore, these criteria cannot be applied for evaluation of money management strategies.
The body of literature on high-frequency trading focuses on the effect of high speed trading around macroeconomic news. In the ST system, the process of opening transactions is not related to the ongoing macroeconomic processes. It is apparently independent. In the ST system, any opening transaction is dependent on a current state of FX. On the other hand, any state of FX is dependent on actual macroeconomic news. Therefore, we can say that the process of opening transactions is implicitly related to the ongoing macroeconomic processes.
Moreover, further research on the considered trading systems should be devoted to the following problems: