Machine learning in trading: theory, models, practice and algo-trading - page 3193

 

There is a well-known hypothesis of market efficiency.

There is a well-known objection of some trader against it - if I see a 20-dollar note lying on the ground, I will just pick it up, not looking at the fact that this paper cannot be there according to the hypothesis.

The objection to this objection is that you can pick up even ten pieces of paper, it doesn't contradict the hypothesis, but you can't build a long-lasting winning strategy based on picking up $20 notes from the ground.

For as long as I can remember, this sort of argument has been going on in an endless loop. The problem is that the scientist and the trader are talking about different substances - the former about a random process and the latter about a specific price chart. It does not make much sense to apply the concept of a random process to an already existing chart - it is needed mainly for reasoning about a future price that does not exist yet.

 

I'm not sure if I'm right (let the experts correct me) I've written a simple function for guessing the price by a trader.

a random price of 100 points is generated

the trader's buy entry price is generated randomly

if the entry price turned out to be a minimum and the next 5 prices were higher than the entry price (the price was rising)

then the function returns 1 otherwise 0

simulate_fun <- function(){
x <- rnorm(100) |> cumsum() |> round(3)
sq <- seq(min(x),max(x),by=0.001)
entry <- sample(sq,1)
id <- which(x==entry)[1]
if(is.na(id)) return(0)
if(id>95) return(0)
ifelse(x[id]==min(x[id:(id+4)]), return(1) , return(0))
}

run 100k simulations

iter_res <- sapply(1:100000 ,\(x) simulate_fun())

we get this summary

table(iter_res)

iter_res
    0     1 
99931    69 

probability

99931 / 69 = 1448.275


Total according to these statistics if the market is random a trader needs to make about 1500 trades to guess a small bounce on 5 bars/tic.

One bounce, not 4 in a row like the author of the picture.

So it is unlikely that his trading and mine can be considered random too....



PS

I deliberately reduced the number of decimal places to simplify calculations and as if to create a certain backlash, in my simulation it is assumed that

the trader does not have to guess the price tick to tick, but just something more or less close.

 

Is the market random?

Is the movement of molecules in the air around us random? Sure, no doubt about it, each one is on its own and moves wherever it wants and collides with whatever it wants.

And the thermometer says that the energy of this random motion called temperature is absolutely NOT random. If it changes, it changes from its previous value.

So is the market random?

 

Yes, the theory of efficient markets can be compared to random walk because it assumes that asset prices in the market move randomly and reflect all available information. Therefore, similar to random wandering, prices in the market can change in any direction and at any speed, and it is impossible to predict exactly where they will go at the next moment in time.

chatgpt
 
mytarmailS #:
What was the prompt exactly?

the theory of efficient markets can be compared to random walk?

 
Maxim Dmitrievsky chatgpt

Bing

The theory of efficient markets can be compared to random walk?


Efficientmarkets theory and random walk are two different concepts.Efficient marketstheory assumes that prices in financial markets reflect all available information and therefore it is impossible to make super profits using only thisinformation1. On theother hand, random walk is a mathematical object that describes a path consisting of a sequence of random steps in some mathematicalspace2. However, some researchers believe that prices in financial markets can be described as a random walk with some modifications. Thus, it can be said that these two concepts are related to each other but are not the same thing. 😊


logged out of the chat room and asked a question in a new session

Efficientmarkets theory can be compared to random walk?

Yes, efficient markets theory and random walk can be compared. Theefficient market hypothesis assumes that all relevant information is immediately and fully reflected in the market price ofsecurities1. Random walkis a mathematical object that describes a path consisting of a sequence of random steps in some mathematicalspace2.In finance, the random walk model can be used to describe stock price fluctuations in the stockmarket2. Thus, both theories can be used to analyse and predict the behaviour of financial markets. However, it is worth noting that these theories have different assumptions and may produce different results depending on the situation. 😊



so far these toys can only be used to edit or write code... to ask something is to deceive yourself.

 

Yes, the theory of efficient markets can be compared to random walk. Random walk is a process in which the movement of a particle has no definite goal or direction. The same can be said about the theory of efficient markets. In the stock market, the prices of securities are constantly changing depending on many factors such as news, events and investor sentiment. As a result, it is impossible to accurately predict how the price of a security will change in the future. The efficient markets theory assumes that security prices always reflect all available information, so it is impossible to make a profit by trading based on information that is already known to the market.

However, there are some important differences between efficient markets theory and random walk. Firstly, security prices are not completely random. They are influenced by certain factors such as company fundamentals and economic conditions. Second, there is no perfect competition in the stock market. This means that some investors may have access to information that is not available to other investors. As a result, some investors may make profits by trading based on information that is unknown to the market.

bard

 
Maxim Dmitrievsky #:

bard

Oh, Bard's a dumb dumb dumb dumb.

 
СанСаныч Фоменко temperature is absolutely NOT random. If it changes, it changes from its previous value.

So is the market random?

Good point.

Reflects the duality of the definition of a concept. If the subject knows nothing, everything is random to him. That is, it is random to him exactly until he recognises the subject.

On the other hand, randomness as a physical effect is impossible in principle. If a photon flies to the left, it means someone shined a torch to the right. And if the photon is deflected, it means it passed by an object that has enough force to deflect its trajectory. The photon itself will never deflect, never get tired, never betray its master - the torch.

The mercury in a thermometer will never set at 38 until it passes the 37 mark. But on a digital thermometer, it will. Because there is a delay in preparing the information and transmitting it to the display, the temperature can skip 37 and go straight to 38 under certain physical conditions.


The market is a digital projection of virtual events of buying and selling instruments. The average value of 1.00000 for 1000 candles can turn into 1.60000 in a moment, just like showing 0. It's a matter of technique (money thrown in), or force majeure.

So here we need to introduce additional definitions that describe the context and speak the same language.
Quotes are not random, they are regular. Lawful from the actions of market participants. But for a subject who does not own the orders of all market participants at the moment - this market is random.

In this case, you are all subjects and for you the market is random by definition. But, among this "regular randomness" you can find traces of big players, as hand traders do. Gathering liquidity, false takeouts, going after the big player, etc. And this is the trader's task - to find the regularity in this "random" wandering.

And your task here is to find the regularity of quotes' behaviour, at which you can trace the beginning of the big player's work and follow him.
All the rest is noise from smaller fish, which is impossible to predict, as small traders balance trading 50% up, 50% down, each with their own strategy, which in total give a uniform distribution over the distance.

 
Ivan Butko #:

And your task here is to find regularities of quotes behaviour, at which you can trace the beginning of the big fish and follow it.
All the rest is noise from smaller fish, which is impossible to predict, as small traders balance by trading 50% up, 50% down, each with their own strategy, which in total give an even distribution on the distance.

I agree in general with the logic. Hence the problem - large movements are statistically insufficient to build reliable models.

If you "dilute the market", you can analyse just the statistics of how it has already happened and make a manipulation just as it has not happened for a long time, or in general as it has never happened before. I wonder if the market makers put this into their software....