Hi, I was preparing a lecture [1] on rpy2 [2] in Sage (version 4.6.2) and notice that the following very important central bit of rpy2 functionality -- namely converting a numpy array to R -- seems to be horribly broken:
sage: import rpy2.robjects as robjects # standard sage: import rpy2.robjects.numpy2ri # enable automatic conversion from numpy to R sage: import numpy # make numpy available sage: print robjects.r(numpy.array([1,2,3], dtype=float)) # try it out; sad result. [1] 3 The output *should* be a vector with 3 entries, I think. There are similar problems with numpy arrays. The same problem happens with 4.7.rc1. I've never used rpy2 seriously before now, so if I'm just confused, can somebody who knows rpy2 better let me know. -- William [1] http://flask.sagenb.org/home/pub/57/ [2] http://rpy.sourceforge.net/rpy2/doc-2.0/html/numpy.html -- William Stein Professor of Mathematics University of Washington http://wstein.org -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org