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

 
mytarmailS #:

Can't "=="?


The loop I'm copying from Rca sounds like this.

for(i in start_idx:length(char_vec)){

from an arbitrary number (number 3 in the example) to the size of the vector


same here

or(int i = start_idx; i == char_vec.length(); ++i ){

from an arbitrary number until we reach the size of the vector

This is a condition for executing the loop, not for stopping it - you will execute the loop zero times if start_idx != char_vec.length().

 
Aleksey Nikolayev #:

This is a condition for executing the loop, not stopping it - you have a loop that will execute zero times if start_idx != char_vec.length().

I got it, thanks

 
СанСаныч Фоменко #:

It's between two rows of random numbers. And it's between a nominal and a random.

What kind of programme is this? I don't need it.

One should take ONLY R, a specialised statistical system - a benchmark in the field of statistics.

how do you prove your competence in the field of trading?)

send me a direct link to the best R library to determine this relationship.

 

this option already works.

src <-'
IntegerVector  Cfu(int start_idx, CharacterVector char_vec){

IntegerVector my_idx = (0);  

for(int i = start_idx ; i <=  char_vec.length() ; ++i ){
      
        if(char_vec[i] == "a")   my_idx.push_back(i); 
        if(char_vec[i] == "b") {
          my_idx.push_back(i); 
          break;
        }
}
return(my_idx);
}

But because of zero knowledge of C++

functions still give different results.

Rfu(start_idx ,char_vec)
[1] 3 4 5 6
> Cfu(start_idx ,char_vec)
[1] 3 4 5

my head is not working at all (((((

2 days designing/writing functions for one idea, I thought I would rewrite everything in C++ in half a day, and then I got ducked into a swamp))) and got fed up at once)))

====================

Is this the right code? Because in rcc from one and in c++ from zero .

for(int i = start_idx-1 ; i <  char_vec.length() ; ++i ){


Rfu(start_idx ,char_vec)
[1] 3 4 5 6
> Cfu(start_idx ,char_vec)
[1] 2 3 4 5

or am I stupid?

 
mytarmailS designing/writing functions for one idea, I thought I would rewrite everything in C++ in half a day, and then I got into a swamp))) and got fed up at once)))

An important point - in R arrays are numbered from 1 to length, and in C++ from zero to length - 1. You need to reduce start_idx by 1 by writing, for example, --start_idx before the loop (or i = start_idx - 1 at the beginning of the loop), and replace <= with < in the loop condition

 
Maxim Dmitrievsky #:

thank you

 
Aleksey Nikolayev #:

thank you

 
Aleksey Vyazmikin #:

Can you make a sample on the basis of your indicator on quotes from MQ on MT5 for 50 thousand bars?

Just record the date for synchronisation of each bar and, let's say, "1" - up arrow and "-1" - down arrow, "0" - no arrow?

And I'll try to train myself to guess the appearance of the arrow, and maybe even the direction. Let's see what the MO or my predictors are good for.....

How do you do the sampling? I don't understand.

Do I have to put it into an array and then save it? I'm not good at this.

I have a sketch on 4, but it's not a problem to make it on 5.

 
mytarmailS #:

Twenty years ago, when I was developing C, I also stalled at this point. Indexing from scratch, and the cycle is one unit less. But then MKL is easy to master - the same C.

 
Uladzimir Izerski #:

How do you do the sampling? I don't understand.

Do I have to put it into an array and then save it? I'm not good at this.

I have a sketch on 4k, but it's not a problem to make it on 5k.

I need a ";" delimited csv file with columns: "Data", "Target".

In "Target" write the target - that would encode the presence and position of the arrow.

Do you have arrows on the bar opening or what?

Reason: