I am trying to compare the volume at a particular time to what it was at the same time on a prior day. 'Lookup' will not work because the 'datatime' argument has to be a constant. The 'for loop' solution shown below works. However, it is computationally intensive and i was wondering if there is an array processing solution. Thanks for your anticipated help.

```
//Get the DateNum of the previous day
TimeFrameSet( inDaily );
dtYes= DateNum();
TimeFrameRestore();
dtYes = TimeFrameExpand( dtYes, inDaily);
// Convert the datenumber to datetime
dtLookBack = DateTimeConvert( 2, dtYes, TimeNum());
dtNow= DateTimeConvert( 2, dt, TimeNum());
t = TimeNum();
dt = DateNum();
datewindow = Status("barinrange" );
for( i = 0; i < BarCount; i++ ){
if( datewindow [i] ) {
for( j = 0; j < BarCount; j++ ){
if(dtLookBack[i] == dtNow[j] AND t[i] > 93500){
VolumeNow [i] = V[i] ];
VolumeYesterday [i] = V[j]];
}
}
}
else {
VolumeYesterday [i] = 0;
VolumeNow [i] = 0;
}
}
Filter =SUM(VolumeNow,5) > SUM(VolumeYesterday)*7;
```