A stateful client for Rserve, the TCP/IP server for R framework.
NOTICE: there is a higher quality client rserve-js (github)- and it is useful not only for websockets
TODO
Install with npm:
$ npm install --save rserve-client
var r = require('rserve-client');
r.connect('localhost', 6311, function(err, client) {
client.evaluate('a<-2.7+2', function(err, ans) {
console.log(ans);
client.end();
});
});
See example directory.
Connects to Rserve at hostname on port and returns the connection via callback.
Evaluates the given command on Rserve and returns the result via callback.
Ends the connection by closing the socket.
TODO