Using Electronic Health Records for Population Health Research: A Review of Methods and Applications.