We have an R4 , that was fitted with a D4-7U engine . Did not do the conversion ourselves , but I would think R4 and 7J back ends would not be too different.
A fairly common event to interchange....
The grader engine however may not be the best choice as the oil pan, oil pump and scavenge system, flywheel and flywheel housing, clutch, etc is not the same as the tractor.