How and when to self-isolate