A simple JavaScript implementation of the URM model