Learning Treatment Regimens from Electronic Medical Records