Add more tests
Fix in_r function