Superficially about the basics of market architecture and algorithmic trading

Many people know that one of the first things they say in a technical university is to forget everything that was held at school. This recommendation is relevant here. It is sometimes useful to start from scratch.

At the moment, all markets are automated. For this reason, some economic explanations of pricing are some rudiments. Steering algorithms + some kind of manual intervention.

The task of each trading algorithm is always the same - to bring money to the owner. The better the algorithm, the more money it is able to bring.

Market Makers


Among the algorithms on the market there are so-called market-making algorithms. You can probably explain on the fingers from a simple example to a more complex one:

Imagine that you have the task of creating a new symbol for trading. Let there be people who for some reason want to trade it. What is required of you? You need at any time to form your symbol from your Level2 applications. Those. fill the symbol with prices and liquidity. At first, you can make a completely dumb MM algorithm - Level2 does not change. That is, the client bought or sold, after which you added liquidity to the original Level2. Obviously, such an algorithm will constantly give the owner money. But the problem is that people are not complete idiots, and they will not trade on a constant symbol - there is not even a potential opportunity to earn money from them.

So you need to somehow make people make deals. The next dumb MM algorithm can be a simple sinusoid - Level2 goes up and down. Many people will also merge, but there are geniuses who see the pattern and begin to bend the owner of the MM algorithm.

It turns out that something needs to be invented so that the MM algorithm has the maximum difference between mergers and earnings. This is where various mats begin to be developed. models that are far from trivial.

Well, on the market, of course, there are many MM algorithms with different owners. There are large owners (non-sickly banks) who also have insiders - they know which traders (because they are their customers) where they stand and how they traded. Therefore mat. Well-designed models. But the task is always the same - to squeeze out as much money as possible from meat (ordinary market participants).

Those. you understand that even you can be a market maker, you only need a good MM algorithm and the solution of some organizational issues.
Let’s try to step by step simulate a closed market (from one FI) on a computer (the simplest option).

Initial data:
- Thousands of robot traders.
- each robot has the same initial capital.
- there is no price and, accordingly, its history.
- no trading costs (commissions, etc.).

How to launch thousands of robots so that they begin to trade among themselves?

We set the initial level (not the price) of the average price - one. First, run the robots that immediately place limit orders. The formation of the price history of Bid and Ask will begin. For some time there will be no deals, but prices will move along any trajectory.

If the trajectories (two) are horizontal lines, this will mean that the market is completely dead. To revive it, we will launch robots that will take the trajectory out of the horizontal. Here we may encounter the fact that the trajectories endlessly rush in one direction. So you need to set (not necessarily explicitly) some boundaries of the trajectories. Now we have a more or less tolerable story. However, no transactions have yet been completed.

We launch robots that, based on the formed history, do their dirty work - they trade. Send deals. Robots that put up limit orders can merge. Then the price will disappear and everything will stall. It will be necessary for certain such robots to give disproportionately high capital (this will significantly increase the initial (50/50) probability of earning), compared with the rest. We will call such robots MM-robots. And in the algorithm we put the guarantee of the presence of their applications. Is it possible to merge with MM robots? Of course have. So you need to somehow guarantee the absence of merging for MM robots.

There are two ways to go. Introduce such trading costs so that they cover the slow drain of the MM robot. Or get insider information about trading other robots and, based on it, simulate and change the price so that there is a positive MO. It is logical to do both.

We enter the initial trading costs for all robots for trading operations, and transfer them to the accounts of MM robots. Initial costs do Koef * MO MM-robots. Of course, Koef> 1. Insider also learned to use, so that MM-robots are slowly merging the rest of the robots.

Can robots trade among themselves endlessly? This cannot be done because certain robots will surely merge, having left the game forever. The profit from the drain will be redistributed between other robots, i.e. average capitalization will increase over time, and the number of market participants will fall.

How to avoid this? There is only one way - the introduction of new robots with new capital. This means that it is always necessary at a certain stage to feed our market with new money and new robots.

Well, it’s like breathing ...

And then people come to whom we show it all and convince that it is all real. They deposit money and start trading. Is it possible to model human trading actions with a robot? It’s hard to say, because there is no limit to perfection, but you can definitely create a behavioral model of a person with a high degree of coincidence. It turns out that again we get to the stage of the presence of only robots. So our market will breathe and live even with people.

What simple conclusions from even such a primitive that was voiced above can be drawn?

- The market is a tool for taking money in favor of MM robots.
- The market is dead without new participants and their new capital.
- The market is dead without insider and trading costs.
- Prices are based on insider prices.


Platform-forming exchange algorithm


It seems, it became clear that everything rests in our automated time on algorithms. There are many types of them. Let's try to consider a purely technical algorithm for creating a trading platform. The simplest algorithm of this type is exchange. We’ll talk about him.

So, there is some kind of symbol that will be traded only on our exchange. And there are many who want to trade it. And this means that there are already ready-made MM algorithms and meat, without which everything is generally meaningless (unprofitable).

The exchange algorithm is purely technical, i.e. It brings profit to its owner by the fact that everyone uses its results, paying a commission. Moreover, even a negative commission, for example, for MM algorithms, can be embedded in the algorithm. The commission grid is again some simple mate. model.

So, there is Level2 (FOREX terminology, it is also called MarketDepth in exchanges) - these are the levels: the purchase / sale price and how much (volume). Each such level (price + volume) is called a gang. The best gangs for selling and buying are called Bid and Ask (some are called Offer, but this is only terminology).

Level2 is formed from client applications (limiters) - these are MM algorithms + some other types of algorithms and meat. The spread is the difference between the current Ask and Bid (in particular, for this reason there is a very inaccurate phrase in its wording that MMs earn on the spread).

An exchange algorithm almost always puts any limit on the corresponding gang in a glass. It is for this reason that by placing a limiter inside the spread, its corresponding narrowing occurs. I won’t explain it on my fingers at all, the setting algorithm is simple (you can google or ask).

If the limiter is set worse than the current corresponding price (for example, SellLimit <= Bid), then the exchange execution algorithm does not execute at a price worse than the market price, but starts to lick (in volume) the gang from the best to the direction of deterioration until the entire limiter is full, or until gangs run out to the level at which this limiter is set.

Of course, there are sometimes unofficial moments in exchange algorithms, when information about your application, before you get into the glass, goes, for example, to the MM algorithm. And it acts in advance (in advance) in a simple way so that you do not get positive slippage from the limiter at a price worse than the current one, but take it to yourself in the form of a net profit. This is some tech. insider, which, of course, is bought, i.e. It has a very clear price tag (money steers). Do not forget about the main task of any algorithm - money. Therefore, there should be nothing surprising - the truth of life.

On exchanges during a trading session, a pre-set limiter is executed in 99% of cases exactly at a price - without slippage. This means that in order to cross your limiter, it must be fulfilled.

Limiters in Level2 are covered by market orders. The types of orders are full, as the exchange wants (will register). This is the same algorithm. For example, MT5 introduced its own types of orders, which the exchange could very well legalize - implement in its exchange execution algorithm. A market order is a derivative of a limit order: a limiter is worse at the price than the current one, and this wisdom is hardly measured. That's how much you need to fulfill with the market - you will get so much, but only with good negative slippage. The main users of market orders are meat.

Obviously, the price can move along almost any trajectory without making transactions - we look at MM algorithms. If the transaction is completed, then its price and volume is called Last. And this info is also broadcast by the exchange. The flow of Last data is called T&S (Time & Sales approx. Ed.).

Some exchanges (by no means all) add a conditional flag to the Last data - the direction of the transaction (Buy or Sell). This marker is a kind of classifier: for passive and active participants. Those. on those whose limit is fulfilled, and those who poured it. Obviously, this classifier is a temporary filter: whose execution of the two sides of the transaction was initiated by a later / earlier trade order.

It is clear that the exchange algorithm must be consistent - i.e. a queue is formed of applications and they are sequentially processed. But there are variants of the so-called snapshots, when orders are accumulated for some relatively short time, and then they are issued once in level2 with the corresponding execution.

Execution of limit orders on the exchange


A correct exchange algorithm does not allow Bid> = Ask in pricing a public situation. In the algorithm itself, as applications are received at the initial stage, a glass is formed in which situations Bid> = Ask often happen. In this situation, the executive part of the exchange algorithm is included, the task of which is to resolve this situation to the Ask> Bid state. And only after the roll-out, the already formed glass with the correspondingly generated Last-data becomes public - accessible to everyone.

SellLimit is always executed at the Bid price; BuyLimit is always executed at the Ask price.
But only these Bid and Ask are non-public prices of the glass formed at the initial stage, as described above.

If you exhibit SellLimit, it is your desire to sell, which is equal to the offer for others to buy from you. For this reason, SellLimit gets into Ask gangs. For example, if you put a SellLimit spread inside the spread, then the best Ask-band is formed with the level and volume of your limiter. Those. setting SellLimit inside the spread, you change the Ask price. If someone wants to buy at the Ask price, then he will fill in your limiter. Saying in this case that SellLimit is executed at an Ask price, or is executed without a spread, is a very vague wording. It’s better to just understand the mechanism, as elsewhere.

I will give an example of execution. You set SellLimit inside the spread, which means Ask is equal to SellLimit. Now you set BuyLimit to Ask. In this situation (see the first paragraph) in the exchange algorithm, it turns out that Bid is equal to BuyLimit. Those. in the end, it turns out that Bid = Ask. That's it, the situation has been resolved until Ask becomes more Bid. Until the algorithm resolves, no one will see the correct glass. For simplicity, let SellLimit and BuyLimit be equal to Vol. It turns out that both limiters collapse, Bid and Ask become equal to the next best bands in the glass, i.e. Ask> Bid. Next, the Last data contains the execution price, which is equal to your SellLimit (== BuyLimit), the volume Vol and the direction BUY (because BuyLimit was sent later than SellLimit).

Note that if, in the same situation, you first send BuyLimit and then SellLimit, then the result will be the same - you will buy / sell yourself, losing on a double commission. But only in the Last data the direction flag will be the opposite - SELL.

Returning to the question of the price at which limiters are executed:

If you look at the bars of small TF on some slightly liquid symbol, you will see that Bid-bars are cut at the bottom (BuyLimits), and Ask-bars - at the top (SellLimits) )

Consider again the situation SellLimit. In the benchmark tester, SellLimit will be executed only when its HighBid> = SellLimit. Please note that HighBid (like LowAsk) are practically not pruned on exchanges. And looking ahead - they don’t cut at all on ECN / STP. Those. if you need to test a strategy with limiters, then for you the main information on the execution of SellLimit is the value of the Bid price, or rather, its High. This may be another argument in favor of the statement that SellLimit is executed at Bid prices.

Distracting a little, we can say that ZigZags with vertices on Bid-data and lowlands on Ask-data are built from the same considerations. And it is on the basis of such a construction that the maximum potential yield is estimated.


Types of traders


The classification of traders can be done indefinitely. But among prof. Market participants (brokers, platform developers, etc.) are divided into two types of traders: clickers (GUI-clickers) and algorithmic traders. The names fully speak about their features. The division into experienced and novice (also use "noobs"), as a rule, is not conducted.
If the task is to attract traders, then the easiest way is to attract clickers and much more difficult algorithmic traders.
Clickers make a nice beautiful GUI, trading conditions are given secondary attention. For this reason, in particular, clickers are on average meat (a source of profit for other market participants). The competition for clickers is high.
Algo traders are very picky about trading conditions, the GUI is not decisive. Competition for algorithmic traders is low, although serious efforts are spent on this.
Mat. expectation of all algorithmic traders is much higher than mat. clicker expectations. The number of algorithmic traders is much smaller, but the turnover is higher.
It so happened that the opinion of algorithmic traders is listened to a much lesser extent than to clickers. Platform developers suffer from this, brokers suffer the same. The opinion of algorithmic traders can even extend to how, for example, the platform is sold to a broker - for a commission on turnover or a monthly fee. Those. All the nuances of a possible change in trading conditions are taken into account.
Most often, market participants are configured to satisfy only one type of trader.

It is obvious from what was written earlier that market makers are algorithmic traders.

Toxic stream


This term is used by market makers. Toxic flow is the systemic profitable flow of trade orders. It comes from the very ones who earn on the imperfection of MM algorithms. In practice, 99% of the toxic flow is accounted for by algo traders.

Models of brokers


  1. Market making.
  2. STP.
  3. ECN / STP.

All three models are absolutely market - it is very important to understand, because there is no fair market or dishonest. Everything is one and interwoven.
The first differs from the other two in that it does not earn on commissions from the turnover of customers, but on their discharge. We will analyze everything with one real example (all data is public), we will miss the names.

A certain broker claims that its turnover is> $ 100 billion / month, while earning $ 80 with myo. Obviously, this is a market maker, because even the most inadequate STPs do not earn more than $ 65 with myo, not to mention such a high monthly turnover.
It turns out that $ 80 per lama is the drain rate of their customers. This means that with an average lot of 0.5, the average client makes a deal with a profit of ~ -0.5 points EURUSD.
If you dodge, then the average deal in lot / pip can be roughly calculated by tickets in MT4. Yes, many tickets will go to canceled postponements and input / output operations, but this can not be compared with the number of market orders - favorites of clickers.

We argue further, once a monthly turnover> 100 yards, then MoneyIn - MoneyOut> $ 8 mio. Those. the broker on the drain of his clients monthly earns $ 8 mio.
The question is, where is it possible to find a monthly number of hamsters. And do not forget that MoneyOut, on average, is about half as much (I invented) MoneyIn. Those. The broker monthly attracts about $ 16 mio of new live money.

How he does it?!
The average hamster carries somewhere around $ 200 (he also came up with it, never heard from anyone). So, even according to the most conservative estimates (MoneyOut = 0), 40,000 hamsters must be robbed monthly.
In fact, hamsters are called that for many times. And they carry their average $ 200 on a schedule - with each RFP, for years. This is a fee for the regular pleasure of feeling like a clicker. Just like they spend every month on movies, beer, etc.

If a toxic stream suddenly occurs among hamsters, then it is quickly and easily detected, after which it is strongly recommended to switch to the STP type or close the account.
Other types of brokers (STP and ECN / STP) are actually beneficial for such a broker. These brokers are not competing market makers. They even do a great good: they explicitly separate ECN for the pros and the Standard for Beginners. Because This allows the customer base on the Standard to eliminate toxicity. It is even beneficial for them that people go to others, because toxicity in the end less. And you can earn more with less risky as a result of MM.

STP and ECN / STP can experience serious problems with a high proportion of toxicity. They need clickers, if only to dilute the toxic in front of their LPs, which are almost always reduced to large market makers. And they act in the image and likeness of small market makers (as described above).
The fact is that on FOREX at this stage the MM algorithms of large owners - banks, prevail. If you make money on FOREX, then this is almost always a loss of these banks, or rather their algorithmic departments, in which millions of budgets are spent on, in particular, so that you do not earn.
You can now profit from the drain of another simple trader basically only indirectly: the trader will merge the MM algorithm, and you will snatch this profit from him. Roughly speaking, making money on FOREX is to rob stolen goods.

But all this sounds strange only if you look through the pink glasses at many events taking place in the world. For a long time the market (stock or FOREX) has become legal instruments for taking money from the population. But it is not all that bad.
Let's get back to our MM broker. Does he have a grand scheme? Not really. The fact is that an MM broker is able to earn even a lot more than $ 80 with myo in a very volatile and trending market. But also go to decent minuses in the long-sluggish market. These are the completely predictable trade patterns of the average hamster. Those. The MM-model of brokerage is a risk model, but it can be very profitable under favorable market conditions.

In order for the MM broker to abandon the MM model, he needs to believe that the STP model is able to give not much less on commissions. And this means that he needs to increase the speed at times. This is almost impossible to do on a huge base of clickers, because Algorithmic traders make a turn. And algorithmic traders will only go when trading conditions are among the best. Well, this, in turn, can happen with serious financial injections into the STP infrastructure.
Moreover, if there is such a huge herd of meat in the form of clickers, then why give them the drain to the snickering MM banks, receiving only a commission from their discharge. If you can take everything completely to yourself. In general, such simple arguments make it clear that an MM broker with a huge meat base becomes a hostage to himself.
Here it can come to a ridiculous point if the base has some kind of national mentality. For example, the number of Russian hamsters decreases by an order of magnitude, if you ask them to fill out a little more fields in the questionnaire, as regulators require. This largely makes MM brokers go to offshore zones.

But then again, not everything is so bad ...

Quanta


Quantums are, as a rule, educated people with an analytical mindset. Unfortunately, in life it happens that a good education, knowledge of the exact sciences, etc. it’s not enough for success. Usually, the more effort spent on learning something, the greater importance is attached to it. Among scientists, a huge number of mediocre personalities who do a good job with the career characteristics of their profession. These are publications in magazines, participation in summits, lecturing, etc. One of the near-scientific topics is a comprehensive study of near-trade activities. Everything is done as taught. Those. Vlob applied mat. apparatus, associations with physics are built, various market models are created, etc. Such scientists are called quanta. The vast majority of them are careerists. But there are exceptions, as in any business.

Cointegration


A different quantum heresy can be induced, giving the term cointegration clear mathematical definitions. But all this has little to do with the practice of trading. For a simple explanation, cointegration is possible. Imagine you have a lot of trade symbols. If there is an opportunity (the amount of each symbol) to buy / sell these symbols in such a way that the profit fluctuates around some not very changing value, then such symbols are co-integrated. Of course, very childish, but the essence conveys 90%. This combination of characters is called a co-integrated portfolio. A classic example of such a portfolio: an asset and futures on it.

Arbitration


Any portfolio has bid and ask prices. Moreover, it has its own Level2 (it is easy to calculate from the Level2 characters included in it). If there is an opportunity for a co-integrated portfolio to complete a transaction so that after its closure there is a positive profit, then this opportunity is called arbitrage. Such a co-integrated portfolio itself is called an arbitrage portfolio (just invented).
The lower the trading costs (quality of execution, commission), the greater the chances of the co-integrated portfolio to become arbitrage.

Marcup


Markup - price deterioration (Level2) by a certain amount. For example, a broker can lower prices to make money on it. It may take a marketing step - zeroing the commission (clickers do not like difficulties), but entering it in the markup. There are positive (profitable) markups for the trader, but their understanding is possible only with a good understanding of pricing, so let’s miss it for now.

Trade arbitrage


Suppose there is a desire to do arbitration. To do this, at least create a co-integrated portfolio. The simplest co-integrated portfolio consists of two symbols of the same name: one from one broker, the second from the other.
Take, for example, the popular EURUSD and give the symbols for convenience the corresponding names: EURUSD1 and EURUSD2. The most important point to be fully aware that EURUSD1 and EURUSD2 are completely different characters. They could even be called girlfriends at brokers, have strongly (an order of magnitude, for example) different prices and other differences. Only one thing is important - they are cointegrated. But for simplicity we will consider an elementary case: EURUSD1 and EURUSD2.
Before comparing prices, an algorithmic markup is made on them in order to add to them all possible trading costs (quality of execution for each broker and commission for each broker). We will further assume that all prices are already marked.
So, in each broker you have trading accounts with certain money. If you look at arbitration very primitively, you need to find the moments Ask1 <Bid2 and Ask2 <Bid1. And at these moments open / close opposite positions in each of the brokers.
This is the simplest and most frontal implementation. Let's make a small digression towards a more generalized and universal vision of such trade.
In this case, the cointegration of the portfolio suggests that Synth = EURUSD1 / EURSD2 fluctuates around unity. This Synth has its own Synth_Bid and Synth_Ask (Synth_Level2) prices. If it is possible to build a ZigZag with tops on Synth_Bid and lowlands on Synth_Ask, then our Synth portfolio is arbitrage. But this is a distraction.
Let us return, however, to a more familiar view of trade for the majority. In fact, in some cases, it is justified to create something high-level for the convenience of trading. And for arbitration, this high-level is done like this:
Marked Level2_1 and Level2_2 are taken and simply combined into Level2_All, which the created artificial high-level symbol EURUSD_All begins to correspond to. Very simple trading functions are written that are able to trade EURUSD_All. For example, if you want to sell EURUSD_ALL, then OrderSend (EURUSD_All, OP_SELL) sends a SELL order to one of the brokers whose Bid price is the highest, i.e. his bid price is on the best gang in Level2_All.
Now I need to say a few words about Level2_All. In his internal representation, gangs now contain not only prices and volume, but also the name of the source of this data.
With such an implementation, you only need to wait for the situation when Ask_All <Bid_All and at that moment simultaneously open multidirectional positions on EURUSD_All. As a result, getting high-level profit and the lack of open positions on EURUSD_All. Convenient, isn't it? An adviser in such a high-level language would occupy 10 lines: see a negative spread, trade it, wait further.
If we go down from a high level of vision of such a trade, we will notice that at the moment when we do not have positions on EURUSD_All, we will have an open position on EURUSD1 and the opposite one on EURUSD2. This in turn will cause the natural skews of Equity1 and Equity2. Yes, roughly speaking, Equity_All = Equity1 + Equity2 will grow as you trade, but we know that Equity1 and Equity2 must be at least positive. And our distortions may well simply cancel the account at one of the brokers, although the other will grow.
How to solve this problem? The first thing that comes to mind is to transfer money from one broker to another. Those. order withdrawals from a broker where there is more money and send them to where there is less. But this is a long, very long time. In addition, it is also extremely expensive - bank and other types of transfers are not free.
But imagine that someone appears who says that all distortions will be leveled for a small fee. This one is clearing.

Simple aggregator


It was easy to notice how convenient it was to trade at a high level. At the same time, it is convenient to trade not only arbitration, but any strategy in general, as EURUSD_All prices, based on their construction, cannot be worse than EURUSD1 and EURUSD2. Those. the artificial symbol is more profitable and the profit on it is obviously higher. And here comes the idea of ​​creating such artificial high-level symbols for any kind of strategy. Moreover, according to the same principle, we should take not two sources (brokers in the example) of co-integrated symbols, but any number of them. Obviously, the more sources, the more profitable (better prices) high-level symbols.
Such high-level entities are called liquidity aggregators. Obviously, this algorithm is a kind of software that allows you to trade like this. Among the companies participating in the life of the market there are software companies that deal with precisely such aggregation algorithms. Giving its customers the opportunity not to bother with low-level trading, but to trade high-level, spending their intellectual strength on other things.
Among these software companies, Currenex and Integral are the most famous. They sell their software for a commission on turnover. For this reason, in particular, some write their own aggregators in order to be more competitive.

Creating a trading platform


You wanted to create a trading platform without much effort. Very rude it looks like this. You come to a well-established soft aggregation company and declare your desire. Those answer that without problems, but some conditions must be met. First, you must have contracts with the source companies that you want to aggregate. Next, you need one single account with the prime broker, who already obviously has agreements with your source companies and is able to organize clearing so that there are no distortions. Clearing is also part of the commission.

Next, the aggregation software company sets up its aggregation software with your sources and a prime broker, with whom he has agreements on the possibility of such activities, and gives you a turnkey trading platform.
Note that the sources can be the same aggregators, their sources are also some kind of aggregators. All this can eventually be intertwined and repeated, which sometimes causes an overestimation (duplication of sources) of volumes on some gangs of your Level2_All. And, of course, at the very ends of this network are banks with their MM algorithms.

PriceTaker and PriceGiver


Market participants are always divided into two categories: creating (PriceGiver) market offers (prices and quantity) and agreeing (PriceTaker) with them.
The market offers themselves are applications: I’m ready to buy / sell so much at a certain price or better. The totality of these orders (Level2) conditionally shows the current market liquidity.

Liquidity provider


Liquidity Provider (LP) - this is how the aggregator calls its price sources, which it combines into one single virtual (high-level) Level2. Obviously LP is PriceGiver. A significant share of PriceGivers is occupied by MM algorithms.

STP


STP is an aggregator where the client is only allowed to be a PriceTaker. This means that customers are not able to form their applications for which anyone could agree. They can only accept offers from PriceGivers.
As mentioned earlier, the aggregator is a kind of high-level virtual trading service. Therefore, all limit requests of STP-aggregator clients are virtual and are stored on the aggregator server.
As a result, if someone takes an STP aggregator as an LP, he will not be able to trade with his clients. Almost all MM algorithms running on an STP aggregator will not yield a positive profit.

Simple STP Aggregator


In a simple STP, all virtual client trading orders come to its PriceGivers as market orders. For example, a customer has SellLimit. As soon as Bid> = SellLimit occurs, the SELL market order is sent to the LP to which Bid corresponds. The response of LP to such a trade order is the result of the execution of the client SellLimit.
Obviously, with such an implementation, slippages occur, the average of which is less than zero. Those. customers incur losses.

Other STP aggregator


Here, all virtual client trading orders come to his PriceGivers as limit orders (a market order is a limiter, the price is decently (determined by the STP aggregator) worse than the current one).
Let us analyze the execution algorithm using the example above:
At the moment Bid> = SellLimit, the virtual SellLimit is frozen (removed from the accounting system by the execution system, the client cannot do anything with it) and the same SellLimit is sent to the corresponding LP. Moreover, all these actions have no effect on pricing. Those. a little later than freezing (for example, by 1 ms), Bid may form better (from other LPs), but it will almost never (in any way) take part in the execution of our client SellLimit.
The LP where SellLimit was sent replies that it executed one part of SellLimit, and for the various reasons it didn’t execute the remaining part - reject. After that, the client receives a high-level open SELL pose for the executed volume and defrosted SellLimit for the remaining one.
The speed and quality of the LP response depends on many factors. The duration of the response can go up to several seconds. Situations are not excluded when the answer does not come from LP.

Note (with this implementation of STP), aggregator client limiters do not slip into the negative zone. Moreover, positive slippages are frequent, which cover a significant part of fixed trading costs - the commission.

Here you can see how the performance and pricing of exchanges and FOREX are very different.

The nuances of execution.

It is very difficult to describe that many subtleties that affect the quality of performance. The simplest thing that aggregators do one of the first is to improve the communication channels between LPs. however, determining the quality of execution (FillRate) are the execution algorithms of the STP aggregator. This is a whole class of constantly improving (not all) interesting algorithms, some of which even affect the pricing of the STP aggregator. They are largely unofficial competitive solutions and are very specific to the trader's guide, so I will most likely not talk about them.
The fact is that two STP aggregators that are in equal conditions can significantly differ in FillRate, thanks to the use of different execution algorithms. This can be especially noticeable with toxicity. Those. indicators of a trading strategy can very much depend on the aggregator used, especially with an increase in trading volumes.

If the trading indicators of two identical vehicles launched under equal conditions on the same aggregator are the same, this is an indirect sign of a very high level of quality of the execution algorithms of this aggregator.


ECN / STP


ECN / STP - as an aggregator, algorithmically identical to STP. The only difference is that a new virtual LP - LP0: requests from aggregator clients is added to aggregation.
Customers of ECN / STP-aggregator also become PriceGivers in such a simple way. This means that clients can make transactions among themselves virtually directly.
The higher the LP0 turnover, the more profitable the ECN / STP aggregator, as unlike other LPs, LP0 does not require a commission for its use by the aggregator. Moreover, the flow of trade orders attributable to LP0 cannot in any way be characterized as toxic. Because it is already trading clients among themselves, even if among them there will be MM algorithms.
It turns out such a hassle-free LP.
But you need to clearly understand that in order to be able to be a PriceTaker for the LP0-PriceGiver ECN / STP aggregator, you need to be his client. Those. customers of other aggregators can sometimes not take advantage of the sometimes excellent (best) price offers LP0.
For example, you trade in two aggregators. In ECN / STP, put a limiter inside the spread, improving Bid or Ask. But in another aggregator you cannot buy / sell at this price on your own, because they are not visible. Those. You will buy / sell, most likely, at a less favorable price than that offered by your limiter.

ECN / STP Metamorphoses


The strength of ECN / STP is the ability to exchange liquidity.
Imagine that some STP aggregator has taken an ECN / STP aggregator as a LP. This automatically means that clients of the STP aggregator become the PriceTakers of the ECN / STP aggregator, in particular (and other LPs from the STP aggregator list). It turns out that in the example above with two aggregators, you would see your application in the STP aggregator placed in another ECN / STP aggregator. And if it turned out to be the best in the final STP-Level2, then you could make a deal with yourself. Those. your application would become available to much more PriceTakers, which means that the likelihood of your application being executed would increase.
You need to understand that each aggregator has its own PriceTakers database, and such a simple technique allows you to exchange these databases, increasing the likelihood of PriceGivers order execution. And it’s also beneficial for PriceTakers, as prices are better.
Of course, if two ECN / STP aggregators make each other their LP, then there will be a serious discrepancy in each Level2 - recursively liquidity will be increased significantly. Therefore, ECN / STP aggregators exchange (more precisely, they can) with each other internal (LP0) liquidity through certain technical arrangements - tags.

Reality.

The LPs of most aggregators are banks with MM algorithms. This means that the toxic problem in most aggregators is extremely urgent. If one of these LPs notices toxicity from the aggregator, it notifies the aggregator about it. And that, in turn, is faced with a choice: turn off LP (because he does not want to incur losses), or turn off his client - the source of the toxic. Most often, the aggregator refuses a profitable customer, because it is less profitable. This is a vicious scheme for traders in most cases.
However, there are exceptions, and this is a serious redistribution of the well-established rules on institutional FOREX. ECN / STP aggregators have emerged that are potentially capable of turning PriceTeker's huge liquidity into PriceGivers liquidity. Those. short-circuit traders, significantly reducing the income of classical banking MM-algorithms. It is worth saying only that, according to conservative estimates, the scattered retail-FOREX has a monthly turnover of more than a trillion USD. And almost all of this turnover is meat from clicker bones, which are currently gnawing at DCs (market-maker scheme) and cans through classic STP and ECN / STP aggregators.


Simple HFT MM algorithm


Obviously, the ECN / STP aggregator has some insider information: who trades through it and how. A competent owner of such information creates a classifier of customer profitability. For example, as a result of the analysis, he finds out that clients of the aggregator stably (and at the right speed) merge onto GBPJPY from 12 to 17 hours of each environment. What does it mean to merge - it means that their money flows into LP, which at that time had the most competitive prices.
The question begs, why give the drain to someone when you can take it to yourself? Some will go according to the gray scheme - turn off ECN / STP for this time and actually turn into DCs according to the market maker scheme. But there is an absolutely mutually beneficial white way - the HFT MM algorithm. Let it be ours.
In our example, every Wednesday from 12 to 17 hours we put our BuyLimit and SellLimit inside the GBPJPY spread at a minimum distance from the external spread (not created by us) and follow all the time (here we need HFT - quick drag and drop of orders) . It improves prices - narrows the spread. And merging customers will make deals at better prices. However (see the mention about the drain rate analysis), their discharge will flow already to us, as they will make deals with us.
Mutually beneficial is that we get profit, and merging customers lose money at a lower rate than if we did not use the HFT MM algorithm. Well, if the owner of such an MM algorithm is the ECN / STP aggregator itself, then, of course, the fee for using its LP0 is zero. And the client also pays the commission for the transaction in full to the aggregator. Those. in fact, for such an owner, the commission is even negative.

Adaptive HFT MM algorithm


It is not necessary to possess the above insider information. You can get it in a simple way yourself - sounding.
To do this, of course, you need to spend money: your spread is created according to the scheme above, but only with a minimum lot. ECN / STP customers will always make transactions with you, thereby you will receive insider information. Further, everything is the same as in the diagram above.
Adaptability lies in the fact that insider information is taken by a sliding window, i.e. adapts (arguably, unconditionally) to the mood of customers and the market.
Note that any HFT MM algorithm will almost never be a toxic, as only PriceTakers takes money, among which there are almost no HFT MM algorithms.
I should probably mention that these elementary HFT MM algorithms were invented by me right away. And the exploited HFT MM algorithms are much more intelligent. However, their essence is approximately transferred.

One of the mutually beneficial options for attracting HFT MM algorithms


An ECN / STP aggregator is always advantageous when among its clients there are HFT MM algorithms, as they provide high turnover. However, for independent HFT MM algorithms, trading costs in the form of a commission are a significant obstacle to fully exploit their capabilities. For this reason, a marketing scheme is created that can have a very clear mate. calculations when the HFT MM algorithm is given a negative commission. Those. the aggregator for all applications of the HFT MM algorithm that were executed on LP0 does not charge a commission from it; moreover, it pays part of the commission taken in full from the other side of the transaction - PriceTaker. A similar scheme was casually mentioned in the description of the exchange algorithm.

HFT MM-algorithms: exchange vs FOREX


On FOREX, not all ECN / STP aggregators provide T&S data. There may be several reasons for this. For example, hide the speed and prevent the toxic coming from ECN / STP explicitly. However, some ECN / STP aggregators still provide this information.
There is T&S on exchanges, but the data on the classification of transactions (PriceGivers or PriceTakers) are far from always of official (exchange) origin. Most often this is an independent algorithmic classification.
In the case of both the exchange and the ECN / STP aggregator, correctly classified T&S data shows when PriceTakers / PriceGivers lose / win. In this case, to create an independent simple HFT MM algorithm, it is not necessary (with proper technical infrastructure - speed) even sounding and any analysis of Level2 dynamics. Because appropriately converted and analyzed T&S data is the aforementioned insider.

Off-market


On institutional FOREX off-market quotes are not uncommon. They become a sore point when transactions are made on them. And especially for patients when these transactions have a high (in absolute) profit, regardless of its sign.
For various reasons, MM-algorithms can fail, giving non-market quotes. In fact, they are quite market-based, since they offer to buy / sell on them. But in the concluded agreements, as a rule, there is a clear loophole when transactions made at off-market quotes can be canceled (and often canceled).
Off-market prices are always determined retroactively through comparison with price histories from several sources. If a strong surge, in comparison with the rest, means a non-market kotira.

Lastlook


The right of a lastluk is to refuse to execute at the price offered by him. This is used by some drugs in the direction of toxic clients: if a request from a toxic agent arrives, do not execute it, if it is a draining request, do it.
Because of this, the quality of performance is greatly reduced, increasing the number of redzhtey. They are fought through algorithmic pricing in some aggregators.
There are sites without a lastluk, but there, with obvious toxicity, what happens as a result of what has already been described earlier: either the site refuses the toxic client, or a drug that suffers from this toxic.

Защита трейдера.

Неподкованного юридически прибыльного трейдера на институциональном FOREX могут легко «раздеть», через механизмы Off-market и LastLook. Поэтому разумно выбирать место для торговли через наиболее продвинутый агрегатор, который соседствует еще с сильным юридическим отделом.
Т.е. помимо того, что трейдер будет анонимно представлен в общем потоке агргегатора. Он еще будет получать бесплатную юридическую профессиональную помощь в разборе проблем с отменой сделок. Бесплатно, т.к. юр. отдел отстаивает не права трейдера, а лицо куда более крупного владельца агрегатора, от имени которого, в частности, совершал сделки этот самый трейдер. Для этого, конечно, должна быть принципиальная позиция владельца.


Виртуальный агрегатор


As already mentioned, an aggregator is a high-level union of co-integrated symbols. Note that there is no restriction on the reality of such symbols.

This means that if there are synthetic co-integrated symbols, then they can not only be created, but also aggregated.

The virtual aggregator does this too - aggregates co-integrated synthetic feeds (price flows) within one platform into one high-level (virtual, of course) symbol that can be traded.

Virtual aggregators have the same property as classic ones - they mask the toxic, create the best prices, increase instant liquidity, increase the liquidity ceiling of vehicles, etc.

Most often, the creation of virtual aggregators falls on the shoulders of algorithmic traders. The most advanced classical aggregators can partially do the same: aggregate not only explicitly existing LP symbols, but also their synthetics.

A primitive example of visualization of the simplest part of a virtual aggregator is the combination of synthetic feeds:
image

The most adequate assessment of any symbol occurs when analyzing its high-level aggregated namesake.

Rough algorithm for getting T & S data from Level2


Imagine that we have a certain sequence of Level2 values ​​- large vectors, where each price level has its own volume (gangs). We number the elements of this sequence from zero (current), towards the past.

ECN (exchanges)

We save each other Level2 [0] and Level2 [1]. If Bid [0]> = Ask [1], then all gangs from Level2 [1] _Ask that are not higher than Bid [0] get into T&S. Similarly, for the situation Ask [0] <= Bid ​​[1]. In other cases, nothing gets into the simulated T&S.
This algorithm is easy to check on lin. links with officially provided exchanges T & S-data. Then bring some improvement through gangs that are uneven across gangs, etc ... In general, the topic always delves into the rough model above.

STP (preferably a lot of drugs)

Vector_Ask [0] = Level2 [0] _Ask - Level2 [1] _Ask. For this vector, all negative values ​​are summed from the best (at the price) gang until the first non-negative gang is met. This amount is entered in T&S [0]. With Bid, it’s the same.

ECN / STP

Here it’s more difficult, because It is necessary to combine two almost conflicting methods for ECN and STP. I will not paint.

Why T&S?

Applicability in MM algorithms has already been described. Also, for example, you can evaluate the price levels of accumulation of serious volumes and analyze their impact on distant (seconds, minutes, hours) price targets.
On FOREX, in order to evaluate the relationships between all symbols, it is sometimes reasonable to use Level2 not symbols, but currency pairs (build synthetic Level2 by yourself).

Order allocation


This is the name of the rule (algorithm) of the distribution of filling (at execution) of limit orders located on the same gang.
For example, on the best gang there are several applications at once, the total volume of which is greater than the received volume of the market order from PriceTaker. It is clear that PriceTaker will receive the full amount of performance at the price of the best gang. The question arises, but how to distribute this volume between applications that were on the gang?
And then each system has its own vision of how to do it right.

Pro-rata

This is a classic allocation rule, when at the time of execution all applications have an execution coefficient corresponding to that part of the volume that applications make in the total volume of the gang.
This means that it doesn’t matter if you break your limiter into pieces, in what order these pieces are sent. The execution will always be the same.

FIFO

Here the time of setting the limiter dominates. Limits are poured by priority: until previously set limiters are completely flooded, other limiters will not be flooded.
With this allocation rule, PriceGivers try to set their limiters ahead of the rest in order to increase the likelihood of their execution. As a result, this causes a narrowing of the spread and a decrease in volumes on gangs, as if someone put up their application for a new gang (reduced the spread), then the other participant does not want to join this gang, because anyway, he will be an outsider to the more sneaky.
When placing an application for a new gang, it is sent either in full, or broken up into pieces in decreasing order, putting them in the same sequence in the queue. This allows, if necessary, to remove part of the volume of your application (by the principle of the stack), without losing the priority of execution.

Volume (Weigth) FIFO

The term composed on the go. Priority is not on the time of issuing, but on the volume of the application (or other custom attribute - Weight).
This allocation encourages PriceGivers to fill the best gangs with maximum liquidity. For PriceTakers, this is one of the best rules.

Weight Pro-Rata

Also, the term composed. This is a modification of Pro-Rata, where applications are no longer given the same distribution weights, but depending on the Weight attribute.
For example, any distribution (mat. Term) by the time of filing applications can be used: the earlier you set it, the higher the weight. In particular, the use of mat. linear time distribution (Time Pro-Rata).
The same is done for Volume and even for more complex features (for example, Weigth = TimeLive * Volume).
With this approach, various mathematically justified methods for optimal submission of bids are already applied - maximizing the probability of the largest bid execution by a market participant in terms of total volume. Those. there are algorithms on how to break an application into pieces and in what sequence to send them to gangs.

What to use and why

Each site comes up with its own rules for allocation, or uses already developed by someone. Depending on the goals that she pursues. It is clear that the main goal is to increase profits, i.e. increase in turnover. And here the non-trivial question arises of choosing an allocation algorithm. In order to motivate PriceGivers and not to reduce the activity of PriceTakers. It all depends on the base of the existing clientele of the site and development prospects.
Most often they don’t bother and choose simple options: Pro-Rata and FIFO.
The only algorithm where no collisions arise with the minimum allowable volume (lot) are FIFO options.

PriceTakers vs PriceGivers


When there is a classification by direction in the T&S data, we can talk about the general indicators of trading PriceTakers, or PriceGivers.
We assume further that the mentioned direction concerns PriceTakers. This is a convention in fact, because PriceGivers destinations are simply reversed.
Recall that each element of the T&S sequence represents data on a transaction made by someone from PriceTakers: price, volume and its direction.
This means that we are quite able to build the dynamics of changes in the total Equity of all PriceTakers for each symbol individually and, accordingly, for any combination of symbols. Moreover, at FOREX, considering all crosses and majors at the same time, you can build the dynamics of changing the overall currency profile of PriceTakers: how much currency is on hand “PriceTakers”.

Level3--

There is such a thing as Level3 - this is complete information about the current state of each of the market participants. Roughly speaking, this is a well-guarded insider. However, as mentioned above, we can come close to it by calculating Equity_PriceTakers.
Let me remind you that the actual purpose of PriceTakers is meat for PriceGivers, among whom there are very strong market participants. Those. Algorithmic pricing itself enriches PriceGivers by draining PriceTakers.
So PriceGivers will do everything to reduce Equity_PriceTakers. Therefore, the use of such an easily computed algorithmic insider seems reasonable from the point of view of the nature of modern electronic fin. market.

Organization of the exchange transition to a new engine


Each exchange operates on a trading engine. Suppose the owner of the exchange realized a serious imperfection (or inhibitory) business imperfection of the current engine. He is faced with the task of writing a new perfect exchange engine.

It may turn out that the new engine is incompatible (this happens) with the old one. How to transfer the exchange to a new engine?

The problem is that all the current liquidation is on the old engine. And if the old one just turn it off and give a new one. Then there will be practically no liquidity on the new one (killing the exchange) - they cannot all be instantly rebuilt.

Therefore, they make an ECN / STP-scheme of the new engine. When the old engine is connected via STP to the new one as the only LP. And the new one also gives its internal ECN.

This allows you to trade immediately through two engines.

After a more advanced engine begins to gain popularity (because it’s more profitable to trade through it - there are fewer trading costs, more opportunities), liquidity flows from it from the old one (it enters the internal ECN of the new engine).

As a result, from the old engine, liquidation almost all goes to the new one. After which the old one closes completely. And there is only a new one left without an external LP. Those. it turns out an updated exchange (ECN) - absolutely everything on a new perfect engine.

It is important to understand that the exchange engine (or the engine of any other trading platform) has nothing to do with the trading APIs. Those. no one except the exchange itself is able to directly influence the operation of this internal engine. This can only be done indirectly.

To do this, the owner of the engine writes bridges between his internal engine and the external trading API. Most often they are limited to only one such real trading API - FIX API (ALMOST obligatory - standard). But there are times when there are several real trading APIs.

Trading platforms with their trading APIs are not real trading APIs of a platform, but their wrapper: sometimes higher level, sometimes less functional, but easier to work with. For example, in almost all trading platforms, the existing trading APIs are actually wrappers. Therefore, trading through them increases trading costs due to latency wrappers.

Exchange takeover


There are a lot of trading floors. On some of them, not only co-integrated FIs can be traded, but generally the same FIs. Those. the same FI is traded at different sites.

In order to absorb these sites (to transfer all their liquidation to their site), you need to create an ECN / STP aggregator, where all victim sites act as LPs. This method creates a new trading platform with more favorable prices - dumping prices.

Thanks also to competent marketing of the promotion of a new platform, first algo-takers, then algo-giver, then again takers, etc. go to it due to dumping. Transfusing liquid like a snowball. From a certain moment, the process becomes irreversible. And the victim sites are completely absorbed.

In the examples above, you can see the main historical significance of ECN / STP schemes. They serve the purpose of centralizing the market, more efficient pricing, increasing liquidity and improving prices.

Match


Matching is the previously described reduction of two multidirectional trading orders within the framework of ECN. Note that STP execution of applications is not a match.

Matching Classifier

In any ECN (exchange), there is the possibility of a statistical classification of the conducted match-up into groups of market participants, within which the largest match-taking occurs. For example, if two market participants, thanks to matching, transfer money to each other through mutual matching, then such a classifier will separate them into a separate group.

Self identification

Any ECN is strategically advantageous so that it has as many brokers as possible (independent customer databases). This is necessary to reduce the likelihood of creating a hypothetical competitor.

A competitor is most often born through the brokers' self-identification, which occurs as follows. Relatively large brokers classify the matching of their customer databases. If it is possible to identify large-turnover groups of such clients within their databases, then the obvious thought arises: why should these clients pay ECN for the match between themselves when it happens anyway between the broker's clients? Of course, this is a pragmatic question.

Dark pool


The answer is to create your own ECN / STP engine, where ECN is used to match intra-brokerage clients, and STP is used to execute on an external ECN (to avoid confusion, we will refer to the external ECN exchange hereinafter (most often it is). This solution provides several advantages (and disadvantages) for both the broker and his clients.

The broker already has its own trading platform, which in relation to the exchange has its own name - dark-pool. Accordingly, the commission from matching their customers now goes to the owner of this site, and not to the owner of the exchange.

Broker's clients sometimes get better execution (than on the exchange), if it occurs inside the ECN, because The latency (technical / computational time delay) of the exchange for broker's clients is always higher than the latency of the broker's client database.

But there are also controversial moments for customers. If an STP transaction is carried out, then guaranteed execution of customers no longer comes out. Those. FillRate (Workmanship) <100%. As already discussed in detail earlier, this is a consequence of the fact that customer orders in the STP scheme are no longer visible in Level2 exchanges. Those. exchange customers cannot respond to them. Roughly speaking, dark-pool customers only become PriceTakers (not PriceGivers) for the exchange.

However, they leave their PriceGivers right inside the dark pool, and this is not enough. Because do not forget that before the creation (and its cause) of the dark-pool, the adequate self-identification described above took place. It must also be said that dark-pool allows you to give its customers anonymity before the exchange, because all STP transactions now go from only one name - the name dark-pool. Moreover, dark-pool, due to its isolation from the exchange, creates additional protection against especially aggressive PriceGivers (MM algorithms and other HFT algorithms trading representatives), which not without reason attracts many market participants to switch from exchange to dark-pools.

The development of dark pools

According to the previously described exchange takeover scheme, a large dark pool is able to absorb the exchange and actually begin to fulfill its role already. At the same time, the regulatory burden of the exchange does not apply to dark-pools, as they are practically pure electronic (virtual) formations. Of course, the regulatory paw will not bypass in the future, and they, as has always happened, when something new gained serious weight.

Centralization vs Decentralization


As you can see, the creation of dark pools is a natural evolutionary process taking place inside the market - its decentralization. The non-zero probability of decentralization forces centralized exchanges to improve their trading conditions. Those. decentralization for exchanges is a kind of mechanism that enhances the effectiveness of this type of market. However, there are also negative aspects of excessive decentralization, which were exemplified by FOREX. There, the same ECN / STP scheme, paradoxically, serves already to centralize the market and improve the trading conditions accordingly.

Those. through ECN / STP-education it is possible to both decentralize the market by creating dark-pools and centralize - the creation of high-level aggregation from the same dark-pools, in particular.

The best trading conditions are somewhere in the middle ground between the paradigms of decentralized and centralized markets.

Real-Time Tester


Any algorithmic trader is faced with the task of transferring the test robot to a combat state, ready to work in the real market.

In fact, there is only one way of literate translation. Fortunately, it is almost universal.

The combat robot is divided into two parts: a tester and a synchronizer.

The tester gives out the trading environment of the tester robot at the current moment of history (to the present).

The synchronizer coordinates this data with the current real trading environment, trying to fit it with the virtual one (obtained in the tester).

For example, the virtual environment shows that now a limiter is at such and such a level. The task of the synchronizer is to make such a limiter at this price level already in the real market.

Types of Synchronizers


There can be no universal synchronizer. But there are only two fundamentally different approaches to synchronization.

  1. Classic - through markets (a la limiters at a price worse than the current one). This is the simplest scheme when the trading environment is copied through the markets. The advantages of this method are its complete repetition and simple visualization. Cons - negative slippage. Those. for vehicles with low mat. waiting is a bad option.
  2. Through limit orders. When, for example, the copied BUY is considered as BuyLimit at the opening price of the copied position. All copied limit orders are also taken into account. The advantage of this method is the leveling of negative slippage. The downside is that limit order edits can distort the results.

The classic version in one form or another is implemented in all signal services that are so popular now. Such a scheme is beneficial to services, because the synchronizer is as simple as possible, and they are little worried about the trading costs of customers.

The second scheme, as far as I know, is not applied anywhere. Perhaps some of the very boring algorithmic traders at home realized ...

Manipulation of signaling services


As I said above, what are the costs of signaling services that are so fashionable now that use a primitive classical synchronization scheme: through market orders.

It is worth mentioning another minus of such synchronization - the manipulation component. The technique described below may remind someone of layering . But still this is different. I will say in advance that the following makes sense only for ECN (exchanges) and ECN / STP sites.

Imagine that you are a provider of signals (better than free ones) and you have subscribers (there will be more of them then) whose traded size is higher than yours. Then from time to time you have the opportunity to include a simple transfer of money from the accounts of your subscribers to your master account:

Put BIG BuyLimit and SellLimit inside the spread and make the “trigger” - a small SELL (sell yourself BuyLimit). This causes an avalanche of SELL orders from your subscribers. Your BuyLimit, i.e. grow BUY posture. What causes an avalanche again, but already BUY orders from your subscribers. Those. Your SellLimit starts to fill up.

As a result, by triggering such recursive avalanches (the basis of which still lies in the latency of signaling services), you receive a transfer of money from your subscribers to your master account. This improves the performance of your master account, attracting even more subscribers.

Of course, it is not necessary to put limiters on the master account. This can be done in your personal other account. Then get an overflow on it. But the master account will have a small drawdown, which may push subscribers away.

There may be other options for such fraud, but their core-idea will be unchanged, as written above.

MM algorithms are almost impossible to profitably synchronize through the classical scheme. Therefore, it is advisable to refer to the previously mentioned alternative synchronization scheme.

Любые торговые действия на ECN (биржи) — всегда перелив денег с одних торговых счетов на другие. Поэтому демонизировать саму технику перелива просто глупо. Нужно просто понимать, что к чему.
Не надо забывать, что задача почти любого ММ-алгоритма — создать взаимовыгодные условия для перелива денег с чужих счетов на свои. Взаимовыгодность заключается в том, что сливающие делают это с меньшей скоростью, чем могли бы, если бы ММ-алгоритма не было. Бывают и исключения — нет взаимовыгодности.

Рыночные закономерности (не HFT)


The market is characterized by the presence of various kinds of patterns at every moment in time. If we designate N (t) as a function of the number of patterns depending on time and construct its graph. Failures will immediately catch your eye - a sharp decrease in the number of market patterns.

These failures almost always correspond to important events,> 90% of which are planned - scheduled economic news.

When searching for market patterns, it is reasonable to discard such periods of N (t) failures, both planned and force majeure, from the analysis. They also throw out periods of apparent absence of the desired patterns - a special automated filter.

Such actions can significantly increase the likelihood of finding patterns.

Therefore, during the trading of found market patterns, any trading activity stops before the scheduled news release and some time after.

PS


Thanks to Sergeyev , with whose filing it was possible to start and systematically continue writing this educational program.

Also popular now: