Setting up R in OSX
Download R from this link
here
.
Download R Studio from this link
here
.
You can try running R in jupyter notebook with the first link of references.
References
How to Run R scripts in Jupyter