Identifying patients at risk of unplanned re-hospitalisation using statewide electronic health records