I think I finally got Rmagic to work. I gave the versions of all the stuff I installed in case it matters but one might be able to skip to step 5 if you have rpy2 working in Ipython but are still having problems with Rmagic. It appears to be working correctly although the cell showing the [correct] results of the %R cell is unusually large for some reason. Haven't tracked down why yet.
1. I installed Python(x,y)-2.7.5.0.exe
2. I had already installed R-2.15.3-win.exe
3. I installed Rtools. Exact filename: Rtools30.exe
4. I installed rpy2-2.3.0dev.win32-py2.7.exe which I got from
following the instructions here for setting up Rhome, Ruser, and path variable changes
I tried the regular non dev version of rpy2 but it didn't work for me.
5. Then I went to my IPython extention folder which for me is: C:\Python27\Lib\site-packages\IPython\extensions
and opened rmagic.py for editing. Found the line
self.r('png("%s/Rplots%%03d.png",%s)' % (tmpd, png_args))
and replaced it with the line:
self.r('png("%s/Rplots%%03d.png",%s)' % (tmpd.replace('\\', '/'), png_args))
The reason you do this is described here:
Supposedly this issue was fixed. See here:
So I'm not quite sure why my Rmagic.py still had the problem.
6. Put %load_ext rmagic in first cell and run it before trying %R
Hope this helps someone,
Erin
--
You received this message because you are subscribed to the Google Groups "python(x,y)" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pythonxy+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to pythonxy-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
Visit this group at
http://groups.google.com/group/pythonxy.
For more options, visit
https://groups.google.com/groups/opt_out.