replace R_InitTranMap() with an implementation that I actually understand