Gatekeeping procedures with clinical trial applications