Dear community,

I'm new to quantconnect and for learning purposes I am trying to build an algorithm that runs everyday 5 minutes before market close and collect the previous daily closing price of the 500 most liquid equities as well as the current price and then buy the 20 biggest losers.

The problem is that if I set "Resolution.Daily" then the algo is launched at midnight and the order is executed at the next open. While if set "Resolution.Minutes" then the algorithm is way to slow due to the high volume of data.

What I would like to do is keeping the Resolution but I would like it to happen 5 minutes before market close and not at midnight. Or if there is another way to solve this problem ?

Thank you in advance for your comments.