Finished Rtreedist.

Still testing.