Using evidence and learning to adapt programmes in real time