[WARNING CLOSED!] Any newbie question, so as not to clutter up the forum. Professionals, don't go by. Can't go anywhere without you. - page 357

 
Dear Professionals! Please help. I can't figure out where to start and how to do it. The general task is this: 1) Find the oldest bar (Time [-1]) in the window and remember its values High (H-1) and Low (-1). 2) Find the next bar (i) by the values (H-1<Hi) or (L-1>Li). If (H-1<Hi) is found, then draw an indicator line from L-1 to Hi. If (L-1>Li) is found, then draw the indicator line from H-1 to Li. I try to put this problem to Zig Zag indicator, but it is created with two calculated buffers and one indicator. I can not figure it out. Thanks in advance for the help!
 
Guys, help, tried to run through the minutes today and I have them from 17 Nov 09, no later ones(. Do I have to put up with it or is there somewhere to give it away??? Thanks in advance.
 
Dear experts! How do you calculate the time accurately?
 
PLUT >> :
Guys, help, tried to run through the minutes today and I have them from Nov 17, 09, no later ones(. Should I put up with it or is there somewhere I can get them??? Thanks in advance.

1. automatically download quotes history.

Follow this method to get quotes from MetaQuotes.

1. Type Service -> Quotes archive or press F2.
2. Select M1 period of the required currency. Make sure you double-click and "Quote Archive: <selected currency>, M1" is displayed in the window title.
3) Press the "Load" button (on the left) and wait. On normal connection it will take about 5 minutes.
4. The M1 quotes are loaded. Click again on "Download" and we will be offered to re-calculate all TFs. You should agree. If an offer has not appeared and a repeated downloading has started (it happens), wait its completion, close the window "Quotes archive", reopen it and press "Download". The offer should now appear 100%.
5. We wait.
6. All the TFs are recalculated. This can be verified by scrolling the scroll bar of the other TF to the bottom.

2. Manual Downloading of History.

You need to find the archive of quotations for required instruments by yourself.

1. Unzip the downloaded archive.
2. Choose Service -> Quotes archive or just press F2.
3. Select M1 period of the required currency. Make sure you double-click and "Quote Archive: <selected currency>, M1" is displayed in the window title. Click on the "Import" button (on the right side).
4. Find the downloaded *.hst file - do not make a mistake with the currency and TF! Click on "OK".
5. To recalculate all TFs follow the same instructions as in the first case.

 
nikost >> :
>>Dear connoisseurs! How to calculate the time accurately?

Meaning?

 
costy_ >> :

1. automatic download of quote history.

2. Manual download of history.


Thank you so much!!!!!!!
 
costy_ писал(а) >>

I can't understand it.

I'd still need to show what the equals used in the logical conditions are.

 
costy_ писал(а) >>
alert (p) after the last form gives only one value=2, and at the end everything is normal in the loop

>> Strange condition.

int start()  {
   bool find;
   int kolvo=0;
   int pos = iBarShift(NULL,0,iTime(0,1440,2),FALSE );
   double buf_X[201][2000];
   double kolvo_buf[2000];
   
   for(int i= pos; i>=0; i--)  
      for (int r=1; r<=200; r+=1) 
         buf_X[ r][ i] = iMA(NULL, 0, r, 0, 0, 4, i);
     
   for ( r=2; r<=200; r+=1) {
      kolvo=0; 
      find=true;
      for( i= pos; i>=0; i--) {
         if( buf_X[ r][ i+2]!=EMPTY || buf_X[ r][ i+2]!=EMPTY_VALUE) 
            
            if(
               ( buf_X[1][ i+2]> buf_X[100][ i+2]&& buf_X[1][ i+1]< buf_X[100][ i+1])
            || ( buf_X[1][ i+2]< buf_X[100][ i+2]&& buf_X[1][ i+1]> buf_X[100][ i+1])
                                                                              ){
               kolvo++;
            }
         kolvo_buf[ r]= kolvo;

      }
      Print("kolvo_buf[",r,"]=", kolvo_buf[r]);  
   }   
}
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[15]=97
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[14]=97
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[13]=97
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[12]=97
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[11]=97
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[10]=97
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[9]=97
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[8]=97
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[7]=97
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[6]=97
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[5]=97
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[4]=97
2009.12.20 16:32:49 test GBPJPY,M1: buffer kolvo_buf[3]=97
 

On the logical assumption that is laid down

   if((buf_X[1][pos+2]>buf_X[100][pos+2]&&buf_X[1][pos+1]<buf_X[100][pos+1])
   || (buf_X[1][pos+2]<buf_X[100][pos+2]&&buf_X[1][pos+1]>buf_X[100][pos+1])
Everything seems to be fine.
 
Man, don't delete posts or you'll end up with an assistant communicating with a ghost =))
Files:
mavbest.mq4  7 kb