R integration in NodeJS

I want to send the input data to r file from node.js and after execution i need to get the output from r file to node.js? What is the process for that??

You need a npm package calledr-script. Here’s a stackoverflow page about it.

I tried that also but i am getting null value in the output… it’s not reading the rfile