The Electronic Health Record as the Primary Data Source in a Pragmatic Trial: A Case Study