MTF timeframe scan output (Scanning Timeframe not Pattern with single timeframe) p2

cheap

Active Member
Re: MTF timeframe scan output (Scanning Timeframe not Pattern with single timeframe)

THINGS NEEDED:
1. BUY CONDITION , WITHOUT THIS NEITHER CAN PLOT ALERTIF NOR PLOT ARROW.
AlertIF( Buy, "SOUND C:\\Windows\\Media\\Ding.wav", "Audio alert", 1 );

PlotShapes( shape, IIf( Buy, colorGreen, colorRed )
Buy = Exrem(Buy,Sell);
Sell =Exrem(sell,Buy);


2. WE NEED TO MAKE BUY CONDITION :
FIND BULLBAR PATTERN BETWEEN 10min. to 15min. AND FIND BULLBAR
PATTERN BETWEEN 1min. to 5min.
if there are bull bar between in both two condition . we make it buy condition .

for(i=1; i<=5; i++) {
bullbar = C > O; [if there is a bullbar, between 1 to 5 min.]
}

HOW DO YOU APPROACH IT? AGAIN KINDLY ANSWER IN CODING WAY.
I guess i tried fully simplify question as much as i can .
Kindly give your suggestion.
Code:
SetOption("NoDefaultColumns", True ); 

AddColumn( Null, "Symbol", 1, colorDefault, colorDefault, 70 );
AddColumn( Null, "DateTime", 1, colorDefault, colorDefault, 150 );
AddColumn( Null, "bar", 1, colorDefault, colorDefault, 70 );



dt = DateTime(); 


for(i=1; i<=60; i++) { 

   TimeframeSet(i * in1Minute);
   
   up= C>O; 


 
   bar= Name() + "\t";
   bar= bar+ DateTimeToStr(LastValue(DateTime()))+ "\t"; 
 

   x= StrFormat("%02g-min", i);
   bar = bar+ WriteIf(up,  x, "\t");

 filter = up;
  if(LastValue(Filter))
    {
        addRow(bar );
    }
  TimeframeRestore();  
 
}
 
Last edited:

cheap

Active Member
Re: MTF timeframe scan output (Scanning Timeframe not Pattern with single timeframe)

I guess i tried fully simplify question as much as i can .
Kindly give your suggestion.
Code:
SetOption("NoDefaultColumns", True ); 

AddColumn( Null, "Symbol", 1, colorDefault, colorDefault, 70 );
AddColumn( Null, "DateTime", 1, colorDefault, colorDefault, 150 );
AddColumn( Null, "bar", 1, colorDefault, colorDefault, 70 );



dt = DateTime(); 


for(i=1; i<=60; i++) { 

   TimeframeSet(i * in1Minute);
   
   up= C>O; 


 
   bar= Name() + "\t";
   bar= bar+ DateTimeToStr(LastValue(DateTime()))+ "\t"; 
 

   x= StrFormat("%02g-min", i);
   bar = bar+ WriteIf(up,  x, "\t");

 filter = up;
  if(LastValue(Filter))
    {
        addRow(bar );
    }
  TimeframeRestore();  
 
}
Question code is there.

How do we compare a output that comes from addrow() ,
addcolumn(),addrow() can't be compared?
i.e. if there is close c or moving average ma that can be compared. Can we compared a timeframe output ?
In reverse we always used to compare, but this is different one?

can we compare addRow(bar ); ?

i is timeframe , x converted it to minute bar ,
writeif(up, x) is nothing without if(LastValue(Filter)
If you do say writeif(up, x) showing timeframe of bar, I ask where? yes, on last bar, so without if(LastValue(Filter)
when this upbar is incomplete without if(LastValue(Filter) , How do we even compare that? IS IT EVER BEEN DONE IN ANY AFL BEFORE?
How do you even compare that?
 
Last edited:

trash

Well-Known Member
Re: MTF timeframe scan output (Scanning Timeframe not Pattern with single timeframe)

Question code is there.

How do we compare a output that comes from addrow() ,
addcolumn(),addrow() can't be compared?
i.e. if there is close c or moving average ma that can be compared. Can we compared a timeframe output ?
Yes we can. See reply #5
http://amibrokerforum.proboards.com/thread/14/addrow-function-vrs-5-91?page=1&scrollTo=580

i is timeframe , x converted it to minute bar ,
writeif(up, x) is nothing without if(LastValue(Filter)
If you do say writeif(up, x) showing timeframe of bar, I ask where? yes, on last bar, so without if(LastValue(Filter)
when this upbar is incomplete without if(LastValue(Filter) , How do we even compare that? IS IT EVER BEEN DONE IN ANY AFL BEFORE?
How do you even compare that?
Once again, if your output is solely done via Addrow then using Filter var makes no sense!!

Once again No. 2, if your output is solely done via Addrow then Filter is set to ZERO. Zero is equal to false. Filter variable (being non zero) is used if you want to create output via AddColumn.

So what does it mean if you add a line like the second one

Code:
Filter = 0;

if(LastValue(Filter))
    Addrow(...);
Since filter is false it means that no output of AddRow will ever occur.
So remove that nonsense line if(LastValue(Filter)). It makes no sense in regards to AddRow.


Don't listen to people who give wrong advice.

That refers to TimeFrame functions also. Always use TimeFrameExpand. That's the only proper way. Don't listen to people who don't understand that a code has to properly work under any circumstances. That's only achieved by using correct expanding. TimeFrameExpand always follows after using restore. TimeframeExpand has three different expanding modes. Use the proper one.

TimeFrameExpand is not supported for N-range and N-Volume bars though.

http://amibrokerforum.proboards.com/...rame-functions


As for the actual "problem", it is actually three loops since it is three dimensions. All loops are outside of time frame procedure. There is no loop within timeframeset... timeframerestore in this case. First loop iterates through time frames (so it is the loop you already have in place), second loop that follows after expanding iterates through patterns (see dynamic variables, alternatively you may use switch statement within timeframeset..timeframerestore) and third loop iterates (partial) barcount.

Also there are no multiple lines of WriteIf() being used! Do you want to tell me that you would write 100 lines of Writeif if you want to output 100 patterns or other comparisons? Are you kidding? We don't want to create amateurish code. We want to create intelligent code.

Also once again there is just one line required that does the expanding of all available patterns. Why? Because we do like intelligent code, don't we.
Also it's needless to say that Addrow follows at the end outside of time frame procedure.

As aside there are also examples where there are actually 4 dimensions applied as seen in 2nd picture here http://amibrokerforum.proboards.com/...1&scrollTo=580
There 1st dimension is bar number, 2nd dimension (column) is period of indicator, 3rd dimension is time frame and 4th dimension is the indicator version.

Long story short I have gone through it "all". I know how AddRow works and how you get any output presented by it. Don't listen to people who haven't ever used it and don't know how it works but give improper advice just leading to nothing else but problems sooner or later.

Study it! Use the several debugging methods being available in order to investigate what happens when you do this or do that http://amibrokerforum.proboards.com/...arty-tutorials

Rome wasn't built after one day too.
 

cheap

Active Member
Re: MTF timeframe scan output (Scanning Timeframe not Pattern with single timeframe)

Yes we can. See reply #5
http://amibrokerforum.proboards.com/thread/14/addrow-function-vrs-5-91?page=1&scrollTo=580



Once again, if your output is solely done via Addrow then using Filter var makes no sense!!

Once again No. 2, if your output is solely done via Addrow then Filter is set to ZERO. Zero is equal to false. Filter variable (being non zero) is used if you want to create output via AddColumn.

So what does it mean if you add a line like the second one

Code:
Filter = 0;

if(LastValue(Filter))
    Addrow(...);
Since filter is false it means that no output of AddRow will ever occur.
So remove that nonsense line if(LastValue(Filter)). It makes no sense in regards to AddRow.


Don't listen to people who give wrong advice.

That refers to TimeFrame functions also. Always use TimeFrameExpand. That's the only proper way. Don't listen to people who don't understand that a code has to properly work under any circumstances. That's only achieved by using correct expanding. TimeFrameExpand always follows after using restore. TimeframeExpand has three different expanding modes. Use the proper one.

TimeFrameExpand is not supported for N-range and N-Volume bars though.

http://amibrokerforum.proboards.com/...rame-functions


As for the actual "problem", it is actually three loops since it is three dimensions. All loops are outside of time frame procedure. There is no loop within timeframeset... timeframerestore in this case. First loop iterates through time frames (so it is the loop you already have in place), second loop that follows after expanding iterates through patterns (see dynamic variables, alternatively you may use switch statement within timeframeset..timeframerestore) and third loop iterates (partial) barcount.

Also there are no multiple lines of WriteIf() being used! Do you want to tell me that you would write 100 lines of Writeif if you want to output 100 patterns or other comparisons? Are you kidding? We don't want to create amateurish code. We want to create intelligent code.

Also once again there is just one line required that does the expanding of all available patterns. Why? Because we do like intelligent code, don't we.
Also it's needless to say that Addrow follows at the end outside of time frame procedure.

As aside there are also examples where there are actually 4 dimensions applied as seen in 2nd picture here http://amibrokerforum.proboards.com/...1&scrollTo=580
There 1st dimension is bar number, 2nd dimension (column) is period of indicator, 3rd dimension is time frame and 4th dimension is the indicator version.

Long story short I have gone through it "all". I know how AddRow works and how you get any output presented by it. Don't listen to people who haven't ever used it and don't know how it works but give improper advice just leading to nothing else but problems sooner or later.

Study it! Use the several debugging methods being available in order to investigate what happens when you do this or do that http://amibrokerforum.proboards.com/...arty-tutorials

Rome wasn't built after one day too.
Yes,
TimeFrameExpand( array, interval, mode = expandLast )
('interval' must match the value used in TimeFrameCompress or TimeFrameSet)
Available modes:
expandLast - the compressed value is expanded starting from last bar within given period (so for example weekly close/high/low is available on Friday's bar)
expandFirst - the compressed value is expanded starting from first bar within given period (so for example weekly open is available from Monday's bar)
expandPoint - the resulting array gets not empty values only for the last bar within given period (all remaining bars are Null (empty)).


Yes output is done by addrow() , addcolumn is used too but it's for adding column, so i guess it doesn't count? if we have some value than Null, then also it doesn't count?

Code:
SetOption("NoDefaultColumns", True ); 

AddColumn( Null, "Symbol", 1, colorDefault, colorDefault, 70 );
AddColumn( Null, "DateTime", 1, colorDefault, colorDefault, 150 );
AddColumn( Null, "bar", 1, colorDefault, colorDefault, 70 );



dt = DateTime(); 
[B] filter = 0; //outside the loop
[/B]

for(i=1; i<=60; i++) { 

   TimeframeSet(i * in1Minute);
   
   up= C>O; 


 
   bar= Name() + "\t";
   bar= bar+ DateTimeToStr(LastValue(DateTime()))+ "\t"; 
 

   x= StrFormat("%02g-min", i);
   bar = bar+ WriteIf(up,  x, "\t");

  
        addRow(bar );
    
  TimeframeRestore();  
[B]m1 = TimeFrameExpand(up,in1Minute);
[/B]
}
Changed
1. made filter =0 and made it outside of loop as mentioned before.
2. removed filter statement iflastvalue
3. added timeframeexpand, but i don't know whether it's right or wrong?
I've used timeframexpand after timeframerestore();
TimeframeExpand(array,from_interval,mode=expandLast):


PATTERN BETWEEN 10min. to 15min. AND find bar
PATTERN BETWEEN 1min. to 5min. putting arrow on 1 min. timeframe.

for plotting arrow, we need buy condition it can't be possible i guess. I made these two as buy condition
In case it's forming bar, only for checking on historical data.take it as repainting.

I mean, what variable do we use that help us to put arrow on chart, Is it possible to make buy sell arrow from exploration?

we have to use two loops and we have to use AND statement for this.

for(i=1; i<=5; i++) {
up= C > O; //[if there is a bar, between 1 to 5 min.]
}

for(i=10; i<=15; i++) {
up= C > O; //[if there is a bar, between 10 to 15 min.]
}

now what variable do we use that satisfy this condition and add it?
AND operator gonna be used?
or we do it like this ?

for(i=1; i<=5; i++) {
up= C > O; //[if there is a bar, between 1 to 5 min.]
}
m2= TimeFrameExpand(up, in1minute)

for(i=10; i<=15; i++) {
up= C > O; //[if there is a bar, between 10 to 15 min.]
}
//m3 = TimeFrameExpand(up, in1minute) //or do we need to write in10minutes,('interval' must match the value used in TimeFrameCompress or TimeFrameSet)

m3 = TimeFrameExpand(up, in10minute);
Buy = m2 AND m3; // m2 + m3;
//first we need to make right buy condition then plotting arrow on 1minute base timeframe.
1. IS THIS CONDITION IS RIGHT WAY OF CODING?
2. what do we use TO PLOT ARROW ON BASETIMEFRAME.

 
Last edited:

Striker

Active Member
Re: MTF timeframe scan output (Scanning Timeframe not Pattern with single timeframe)

Yes,
TimeFrameExpand( array, interval, mode = expandLast )
('interval' must match the value used in TimeFrameCompress or TimeFrameSet)
Available modes:
expandLast - the compressed value is expanded starting from last bar within given period (so for example weekly close/high/low is available on Friday's bar)
expandFirst - the compressed value is expanded starting from first bar within given period (so for example weekly open is available from Monday's bar)
expandPoint - the resulting array gets not empty values only for the last bar within given period (all remaining bars are Null (empty)).


Yes output is done by addrow() , addcolumn is used too but it's for adding column, so i guess it doesn't count? if we have some value than Null, then also it doesn't count?

Code:
SetOption("NoDefaultColumns", True ); 

AddColumn( Null, "Symbol", 1, colorDefault, colorDefault, 70 );
AddColumn( Null, "DateTime", 1, colorDefault, colorDefault, 150 );
AddColumn( Null, "bar", 1, colorDefault, colorDefault, 70 );



dt = DateTime(); 
[B] filter = 0; //outside the loop
[/B]

for(i=1; i<=60; i++) { 

   TimeframeSet(i * in1Minute);
   
   up= C>O; 


 
   bar= Name() + "\t";
   bar= bar+ DateTimeToStr(LastValue(DateTime()))+ "\t"; 
 

   x= StrFormat("%02g-min", i);
   bar = bar+ WriteIf(up,  x, "\t");

  
        addRow(bar );
    
  TimeframeRestore();  
[B]m1 = TimeFrameExpand(up,in1Minute);
[/B]
}
1. made filter =0 and also outside as mentioned before.
2. removed filter statement iflastvalue
3. added timeframeexpand, but i don't know whether it's right or wrong?
Hmm I don't know
 

cheap

Active Member
Re: MTF timeframe scan output (Scanning Timeframe not Pattern with single timeframe)

Yes,
TimeFrameExpand( array, interval, mode = expandLast )
('interval' must match the value used in TimeFrameCompress or TimeFrameSet)
Available modes:
expandLast - the compressed value is expanded starting from last bar within given period (so for example weekly close/high/low is available on Friday's bar)
expandFirst - the compressed value is expanded starting from first bar within given period (so for example weekly open is available from Monday's bar)
expandPoint - the resulting array gets not empty values only for the last bar within given period (all remaining bars are Null (empty)).


Yes output is done by addrow() , addcolumn is used too but it's for adding column, so i guess it doesn't count? if we have some value than Null, then also it doesn't count?

Code:
SetOption("NoDefaultColumns", True ); 

AddColumn( Null, "Symbol", 1, colorDefault, colorDefault, 70 );
AddColumn( Null, "DateTime", 1, colorDefault, colorDefault, 150 );
AddColumn( Null, "bar", 1, colorDefault, colorDefault, 70 );



dt = DateTime(); 
[B] filter = 0; //outside the loop
[/B]

for(i=1; i<=60; i++) { 

   TimeframeSet(i * in1Minute);
   
   up= C>O; 


 
   bar= Name() + "\t";
   bar= bar+ DateTimeToStr(LastValue(DateTime()))+ "\t"; 
 

   x= StrFormat("%02g-min", i);
   bar = bar+ WriteIf(up,  x, "\t");

  
        addRow(bar );
    
  TimeframeRestore();  
[B]m1 = TimeFrameExpand(up,in1Minute);
[/B]
}
Changed
1. made filter =0 and made it outside of loop as mentioned before.
2. removed filter statement iflastvalue
3. added timeframeexpand, but i don't know whether it's right or wrong?
I've used timeframexpand after timeframerestore();
TimeframeExpand(array,from_interval,mode=expandLast):


PATTERN BETWEEN 10min. to 15min. AND find bar
PATTERN BETWEEN 1min. to 5min. putting arrow on 1 min. timeframe.

for plotting arrow, we need buy condition it can't be possible i guess. I made these two as buy condition
In case it's forming bar, only for checking on historical data.take it as repainting.

I mean, what variable do we use that help us to put arrow on chart, Is it possible to make buy sell arrow from exploration?

we have to use two loops and we have to use AND statement for this.

for(i=1; i<=5; i++) {
up= C > O; //[if there is a bar, between 1 to 5 min.]
}

for(i=10; i<=15; i++) {
up= C > O; //[if there is a bar, between 10 to 15 min.]
}

now what variable do we use that satisfy this condition and add it?
AND operator gonna be used?
or we do it like this ?

for(i=1; i<=5; i++) {
up= C > O; //[if there is a bar, between 1 to 5 min.]
}
m2= TimeFrameExpand(up, in1minute)

for(i=10; i<=15; i++) {
up= C > O; //[if there is a bar, between 10 to 15 min.]
}
//m3 = TimeFrameExpand(up, in1minute) //or do we need to write in10minutes,('interval' must match the value used in TimeFrameCompress or TimeFrameSet)

m3 = TimeFrameExpand(up, in10minute);
Buy = m2 AND m3; // m2 + m3;
//first we need to make right buy condition then plotting arrow on 1minute base timeframe.
1. IS THIS CONDITION IS RIGHT WAY OF CODING?
2. what do we use TO PLOT ARROW ON BASETIMEFRAME.

Code:
[B]_SECTION_BEGIN("Formula 41");
SetOption("NoDefaultColumns", True ); 

AddColumn( Null, "Symbol", 1, colorDefault, colorDefault, 70 );
AddColumn( Null, "DateTime", 1, colorDefault, colorDefault, 150 );
AddColumn( Null, "bar", 1, colorDefault, colorDefault, 70 );



dt = DateTime(); 
[COLOR="Blue"] filter = 0; //outside the loop
[/COLOR]

for(i=1; i<=60; i++) { 

   TimeframeSet(i * in1Minute);
   
   up= C>O; 



   bar= Name() + "\t";
   bar= bar+ DateTimeToStr(LastValue(DateTime()))+ "\t"; 
 

   x= StrFormat("%02g-min", i);
   bar = bar+ WriteIf(up,  x, "\t");

  
        addRow(bar );
    
  TimeframeRestore();  
m1 = TimeFrameExpand(up,in1Minute);

[COLOR="Red"]
[B]for(i=1; i<=5; i++) {
 TimeframeSet(i * in1Minute);
up= C > O; //[if there is a bar, between 1 to 5 min.]
  TimeframeRestore();
}
m2= TimeFrameExpand(up, in1minute)

for(i=10; i<=15; i++) {
 TimeframeRestore();
up= C > O; //[if there is a bar, between 10 to 15 min.]
TimeframeRestore();
}
//m3 = TimeFrameExpand(up, in1minute) //or do we need to write in10minutes,('interval' must match the value used in TimeFrameCompress or TimeFrameSet)

m3 = TimeFrameExpand(up, in10minute);
Buy = m2 AND m3; // m2 + m3;

PlotShapes( shape, IIf( Buy, colorGreen, colorRed );
Buy = Exrem(Buy,Sell);
Sell =Exrem(sell,Buy);

}[/B][/COLOR]
_SECTION_END();[/B]
 
Last edited:

cheap

Active Member
Re: MTF timeframe scan output (Scanning Timeframe not Pattern with single timeframe)

Yes,
TimeFrameExpand( array, interval, mode = expandLast )
('interval' must match the value used in TimeFrameCompress or TimeFrameSet)
Available modes:
expandLast - the compressed value is expanded starting from last bar within given period (so for example weekly close/high/low is available on Friday's bar)
expandFirst - the compressed value is expanded starting from first bar within given period (so for example weekly open is available from Monday's bar)
expandPoint - the resulting array gets not empty values only for the last bar within given period (all remaining bars are Null (empty)).


Yes output is done by addrow() , addcolumn is used too but it's for adding column, so i guess it doesn't count? if we have some value than Null, then also it doesn't count?

Code:
SetOption("NoDefaultColumns", True ); 

AddColumn( Null, "Symbol", 1, colorDefault, colorDefault, 70 );
AddColumn( Null, "DateTime", 1, colorDefault, colorDefault, 150 );
AddColumn( Null, "bar", 1, colorDefault, colorDefault, 70 );



dt = DateTime(); 
[B] filter = 0; //outside the loop
[/B]

for(i=1; i<=60; i++) { 

   TimeframeSet(i * in1Minute);
   
   up= C>O; 


 
   bar= Name() + "\t";
   bar= bar+ DateTimeToStr(LastValue(DateTime()))+ "\t"; 
 

   x= StrFormat("%02g-min", i);
   bar = bar+ WriteIf(up,  x, "\t");

  
        addRow(bar );
    
  TimeframeRestore();  
[B]m1 = TimeFrameExpand(up,in1Minute);
[/B]
}
Changed
1. made filter =0 and made it outside of loop as mentioned before.
2. removed filter statement iflastvalue
3. added timeframeexpand, but i don't know whether it's right or wrong?
I've used timeframexpand after timeframerestore();
TimeframeExpand(array,from_interval,mode=expandLast):


PATTERN BETWEEN 10min. to 15min. AND find bar
PATTERN BETWEEN 1min. to 5min. putting arrow on 1 min. timeframe.

for plotting arrow, we need buy condition it can't be possible i guess. I made these two as buy condition
In case it's forming bar, only for checking on historical data.take it as repainting.

I mean, what variable do we use that help us to put arrow on chart, Is it possible to make buy sell arrow from exploration?

we have to use two loops and we have to use AND statement for this.

for(i=1; i<=5; i++) {
up= C > O; //[if there is a bar, between 1 to 5 min.]
}

for(i=10; i<=15; i++) {
up= C > O; //[if there is a bar, between 10 to 15 min.]
}

now what variable do we use that satisfy this condition and add it?
AND operator gonna be used?
or we do it like this ?

for(i=1; i<=5; i++) {
up= C > O; //[if there is a bar, between 1 to 5 min.]
}
m2= TimeFrameExpand(up, in1minute)

for(i=10; i<=15; i++) {
up= C > O; //[if there is a bar, between 10 to 15 min.]
}
//m3 = TimeFrameExpand(up, in1minute) //or do we need to write in10minutes,('interval' must match the value used in TimeFrameCompress or TimeFrameSet)

m3 = TimeFrameExpand(up, in10minute);
Buy = m2 AND m3; // m2 + m3;
//first we need to make right buy condition then plotting arrow on 1minute base timeframe.
1. IS THIS CONDITION IS RIGHT WAY OF CODING?
2. what do we use TO PLOT ARROW ON BASETIMEFRAME.

Code:
[B]_SECTION_BEGIN("Formula 41");
SetOption("NoDefaultColumns", True ); 

AddColumn( Null, "Symbol", 1, colorDefault, colorDefault, 70 );
AddColumn( Null, "DateTime", 1, colorDefault, colorDefault, 150 );
AddColumn( Null, "bar", 1, colorDefault, colorDefault, 70 );



dt = DateTime(); 
[COLOR="Blue"] filter = 0; //outside the loop
[/COLOR]

for(i=1; i<=60; i++) { 

   TimeframeSet(i * in1Minute);
   
   up= C>O; 



   bar= Name() + "\t";
   bar= bar+ DateTimeToStr(LastValue(DateTime()))+ "\t"; 
 

   x= StrFormat("%02g-min", i);
   bar = bar+ WriteIf(up,  x, "\t");

  
        addRow(bar );
    
  TimeframeRestore();  
m1 = TimeFrameExpand(up,in1Minute);

[COLOR="Red"]
[B]for(i=1; i<=5; i++) {
 TimeframeSet(i * in1Minute);
up= C > O; //[if there is a bar, between 1 to 5 min.]
  TimeframeRestore();
}
m2= TimeFrameExpand(up, in1minute)

for(i=10; i<=15; i++) {
 TimeframeRestore();
up= C > O; //[if there is a bar, between 10 to 15 min.]
TimeframeRestore();
}
//m3 = TimeFrameExpand(up, in1minute) //or do we need to write in10minutes,('interval' must match the value used in TimeFrameCompress or TimeFrameSet)

m3 = TimeFrameExpand(up, in10minute);
Buy = m2 AND m3; // m2 + m3;

PlotShapes( shape, IIf( Buy, colorGreen, colorRed );
Buy = Exrem(Buy,Sell);
Sell =Exrem(sell,Buy);

}[/B][/COLOR]
_SECTION_END();[/B]
Let's talk about this problem. we wanna make arrow and little system.
Is this format right? ofcourse code isn't working .

additionally: if you make basic code to second database what do you gonna use?
TimeframeSet(i * in1Second);
x= StrFormat("%01g-sec", i); // do you use %01g-sec or %02g-sec or something else. second, for tick i guess it's 1. i tried both, not working.
// Do i need to change backtest setting for second database exploration?
 
Last edited:

sr114

Well-Known Member
Re: MTF timeframe scan output (Scanning Timeframe not Pattern with single timeframe)

Let's talk about this problem. we wanna make arrow and little system.
Is this format right? ofcourse code isn't working .

additionally: if you make basic code to second database what do you gonna use?
TimeframeSet(i * in1Second);
x= StrFormat("%01g-sec", i); // do you use %01g-sec or %02g-sec or something else. second, for tick i guess it's 1. i tried both, not working.
// Do i need to change backtest setting for second database exploration?
Code:
TimeFrameSet( interval)  
RETURNS NOTHING  
FUNCTION  The TimeFrameSet replaces current price/volume arrays: open, high, low, close, volume, openint, avg with time-compressed bars of specified interval once you switched to a different time frame all calculations and built-in indicators operate on selected time frame. To get back to original interval call TimeFrameRestore() function. Before calling TimeFrameSet again in the same formula with different interval you have to restore original time frame first using TimeFrameRestore. 
[U][B][COLOR="Blue"]interval defines time frame interval in seconds[/COLOR][/B][/U]. [B][U]So 60 means 1-minute[/U][/B]. For the convenience the following interval constants are pre-defined: 

in1Minute = 60 
in5Minute = 5 * 60 
in15Minute = 15 * 60 
inHourly = 3600 
inDaily = 24 * 3600 
inWeekly = 5 * 24 * 3600 + 1 = 432001 
inMonthly = 25 * 24 * 3600 + 1 = 2160001 
inQuarterly (new in 5.20) 
inYearly (new in 5.20)
so 1 second time interval means "in1Minute/60"

its all there in the help file - so read the help file minutely again and again till u grasp the answer.
 

Similar threads