adds action to radio buttons