Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Feed data to R using Statistics::R

by igelkott (Curate)
on Feb 24, 2013 at 00:19 UTC ( #1020367=note: print w/ replies, xml ) Need Help??


in reply to Feed data to R using Statistics::R

As far as I can tell, Statistics::R can only transfer scalars and refs to simple arrays (ie, no AoA, etc).

One reasonable solution would be to convert your data into a single vector or string that you can reconstitute in R. Besides files, another possibility is to get data from a database (which is what I did since that's where my data was anyway). Maybe Statistics::R could be extended to emulate R's MySQL driver so that a "data.frame" could be transferred to/from Perl. I'll suggest this to the author or might even attempt it myself ... once I've learned R's weird data structures well enough.

Perhaps obvious but yet another possibility is to skip R completely since it's quite possible that the statistical functions you need might already be available directly.

Update: This feature has already been requested at CPAN.


Comment on Re: Feed data to R using Statistics::R

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1020367]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (13)
As of 2014-11-26 01:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My preferred Perl binaries come from:














    Results (160 votes), past polls