Check out example codes for "bioFabric r". It will help you in understanding the concepts better.

Code Example 1

library(devtools)
devtools::install_github("timelyportfolio/RBioFabric")

Learn ReactJs, React Native from akashmittal.com