2009/5/12 John Hough :
> Hi Laurent,
>
> When I try to build windows binaries for RPy2 version 2.0.4 with MINGW, I
> get the error messages shown below. I’m using R 2.8.1, Python 2.5.2 and
> Windows XP SP2. I was able to build windows binaries and install RPy2 on my
> box after making the followi
.
>
> The binaries currently available are contributed by a company (Laurent
> Oget / Predictix), and that might be a interesting model to explore. A
> number of rpy/rpy2 users appear to be working in for-profit
> organizations, which might want to consider a contribution of some sort.
If you run the installer as is it will want to install in the global
python folder to which you do not have write access, which will fail.
There are two ways to get around this:
-build your own python and use it instead of the system-wide python.
this has the added advantage that you get to pick y
We noticed on our production server where we run a lot of rpy scripts,
that /tmp is filling up with Rtmp* files. Anybody knows if there is a
way to get those cleared without involving the sysadmin?
Laurent
--
Open Source
You need to install xcode. http://developer.apple.com/TOOLS/xcode/ it
is free if you sell your soul to apple, or at least sign up on their
website. you might also need a build of R which includes the R shared
library.
good luck.
Laurent
2009/2/13 Declan Troy :
> I'm a novice at installing thes
'FALSE' is a string, which somehow when converted to a boolean
evaluates as True.
How do you like:
>>> kwargs={'df':25,'lower.tail':False}
>>> print ro.r['qt'](0.05, **kwargs)
[1] 1.708141
2009/2/4 Lindsey Bangay :
> HI
>
> I am new to rpy2, but I would appreciate some assistance on this probl
Similar answer, without the windows restriction, and it should be much
easier than on windows, provided you have a recent R on Solaris 10, and I
would recommend you build your own.
Laurent Oget, Predictix LLC
2009/1/28 Evan Girvetz
> Similar to my last question...can Rpy2 be installed and
I am pretty sure it could, with the same limitations as it does on 32 bit
windows, i.e. console redirection is not working, however you will have to
build it from source. There are a number of posts on the mailing lists about
building rpy2 from source on windows.
Laurent Oget, Predictix LLC
2009
>>> import rpy2.robjects as robjects
>>> r = robjects.r
>>>
>>> x = [1,2,3]
>>> y = [2,4,2]
>>>
>>> r.png('plot.png',width=500,height=400)
>>> r.plot(x,y)
>>> r['dev.off']()
>>>
dev_off() turns off the device, in this case the device is writing to a file
so dev_off() flushes the buffer and clos
ent in the C code,
> but it does not have much influence in the 2.0.x serie (work on that is
> under progress, but that's for 2.1.x). When done, long evaluations of R code
> will not hold the GIL, and that locking mechanism will be making sure only
> one thread is doing R things.
&g
Does Rpy2 use any systemwide locking to ensure that only one instance is
running at a given time or is this only a process-wide logging to make sure
only one thread within one process is using R?
Thanks,
Laurent
--
This S
http://mail.python.org/pipermail/distutils-sig/2001-January/001807.html
I think your answer is in there
L
2008/12/19 James Yoo :
> yes, I have R in the path... the hang up is that the rpy2 binary installer
> expects to find python in the registry... hoping someone on this list might
> have had s
This sounds like a question for the developers of the python packaging
utilities, i have no clue what the installer does, i just build it
using setup.py.
The good news is that building rpy2 from source is not that hard. All
you need is MSYS and MINGW, then 'python setup.py install' will get
you th
I do std-error=r['$'](summary,'sigma')
I think r.names(summary) will give you the components.
Laurent
2008/12/12 Gary Strangman :
>
> Hi again,
>
> Forgive me if this is a completely silly question for rpy2. I'm trying to
> wean myself from rpy, but am confused by the new approach to conversion.
This is a known issue when R_HOME is set.
One easy work-around is to unset R_HOME and set your path so R is in the path.
This is fixed in svn and will be fixed in the next release.
Laurent
2008/12/12 Gary Strangman :
>
> Hi RPy gurus,
>
> I'm trying to upgrade to rpy2 and ran into the following
Doing it with mingw does work (I did it yesterday).
If playing with obsolete microsoft tools is your idea fo fun you have
two ways of getting R.lib:
- Build R from source
- follow http://support.microsoft.com/kb/131313
Laurent
2008/12/2 Bo Peng <[EMAIL PROTECTED]>:
> When I do 'python setup.py i
set R_HOME=C:\Program Files\R\R-2.8.0 should fix this. It looks like
your R_HOME variable is set, but set to a wrong value.
2008/12/1 Marcos Silva <[EMAIL PROTECTED]>:
> Hi Peter,
>
> The responses to your questions are:
>
> 1. No, I did not setup R_HOME. By the way, how can I do this?
>
> 2. Yes,
part of rpy.
>
>> In the meantime, I would assume the developers would accept Windows
>> installers compiled by volunteers.
>
> Yes.
>
> I built the last rpy binaries, but stopped because:
> - conception/design/implementation of rpy2 was taking a lot of time
> - I co
Laurent Gautier <[EMAIL PROTECTED]>:
> laurent oget wrote:
>>
>> is there something i can do to prevent the following script from leaking
>> memory?
>
>
> There seems to be something happening.
> (more below)
>
>> Laurent
>>
>> from rpy2.robje
is there something i can do to prevent the following script from leaking memory?
Laurent
from rpy2.robjects import r,RVector,RDataFrame
from rpy2.rlike.container import TaggedList
from math import sin
import array
size=100
xx=[]
for x in range(size):
xx.append(RVector(array.array('f',[sin(0.
I do not know garchfit, but it looks to me like it is expecting data
to be a data frame, and you are setting a vector. since you are
setting both variable in the global evironment, wouldn't it work
without the data argument?
Laurent
2008/11/20 Degraeve, Frederic <[EMAIL PROTECTED]>:
> Hello,
>
>
scratch.
good luck
Laurent
2008/11/17 Paul Geeleher <[EMAIL PROTECTED]>:
> Hi,
>
> I'm importing into version 2.5.2. Thats the version that I compiled from
> source and that now starts by default when I type "python" at the command
> prompt.
>
> -Paul.
>
&g
ning build_py
> running build_ext
> running install_lib
> running install_egg_info
> Removing /usr/local/lib/python2.5/site-packages/rpy-1.0.3-py2.5.egg-info
> Writing /usr/local/lib/python2.5/site-packages/rpy-1.0.3-py2.5.egg-info
>
>
>
> -Paul
>
>
> On Sun, Nov
>> from rpy import *
>
>
>
> Any ideas here would be greatly appreciated.
>
> Thanks,
>
> -Paul.
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> On 11/14/08, Paul Geeleher <[EMAIL PROTECTED]> wrote:
>>
>> Thanks for the response
This definitely looks weird. I have built rpy and rpy2 on 64-bit
linux, but this was always using a python i built before, since the
machine i am using come with an antiquated python in the distribution.
I just looked at one of those machine and I noticed my hand-built
python does not have a libpy
before importing rpy, everything goes perfectly well !
>
> import locale
> locale.setlocale(locale.LC_ALL,'C')
>
> Thank you very much for your help Laurent, Barry and Peter !
> This fix will help me a lot !
>
> Aurélie
>
>
>
> laurent oget a écrit :
>
>
I encountered the same issue a few weeks ago
http://sourceforge.net/mailarchive/message.php?msg_name=1224257111.11195.93.camel%40hot-spring
import array
import rpy2.robjects as ro
import rpy2.rlike.container as rlc
x = ro.RVector(array.array('i', [1,2]))
y = ro.RVector(array.array('i', [3,4]))
I suspect there is a setlocale(LC_ALL,'C') somewhere in the main of R,
but not in the shared library which rpy loads.
Laurent
2008/11/13 Barry Rowlingson <[EMAIL PROTECTED]>:
> 2008/11/13 Aurelie Bornot <[EMAIL PROTECTED]>:
>> Ok
>> So I tried the same chart in python/rpy and in R.
>>
>> Here are
e same size but I can't open TEST_Rpy.ps.
> TEST_R.ps is ok for me : I can open it without problem.
>
> Can you see another difference between the two?
>
> Thank you very much for helping !
> Aurélie
>
>
> laurent oget a écrit :
>
> I would try to generate the sa
I would try to generate the same chart in rpy and directly in R and
compare the postscript files. This would give you, and us, an idea of
what went wrong.
Laurent
2008/11/13 Aurelie Bornot <[EMAIL PROTECTED]>:
> Hello Peter,
>
> Thanks for your answer.
> Yes I have tried this in R itself. And eve
Good.
Either solution sounds reasonable to me.
Laurent
2008/11/12 Peter <[EMAIL PROTECTED]>:
> On Wed, Nov 12, 2008 at 9:09 PM, laurent <[EMAIL PROTECTED]> wrote:
>>
>> That's not (yet) stated in the doc, but the code
>> for rpy2.riniterface.__init__ tells it:
>>
>> 1- look for R_HOME
>> 2- if n
Does this mean that we will have to change a registry key to switch
from one version of R to the other, or will the version of R that is
on the PATH take precendence?
Laurent
2008/11/12 Peter <[EMAIL PROTECTED]>:
> Hi Laurent,
>
> There have been a couple of threads recently about rpy2 having tro
2008/11/8 <[EMAIL PROTECTED]>:
> Thanks for the help so far. I inserted the R executable in the Path, but I
> still get the same error.
>
i can see how that might not work
> Unfortunately, I don't know how to define the R_HOME environment variable
> as suggested in
> http://rpy.sourceforge.net/r
I think Rpy2 needs at least R 2.7.1 and this particular build was
built and verified with R.2.7.2
Laurent Oget
2008/11/7 <[EMAIL PROTECTED]>:
> Hi,
>
> I just tried out rpy2 for the first time:
>
> WinXP
> Python 2.5.2
> Numpy 1.1.1
> R 2.7.0
> rpy2-2.0.0rc1
&g
I ran into similar issues while trying to build rpy2 on windows, and i
ended up having to steal header files from the source distribution of
R. How much work would it be to do this?
Laurent Oget
2008/10/20 Dirk Eddelbuettel <[EMAIL PROTECTED]>:
>
> On 20 October 2008 at 11:42, lauren
--
Traceback (most recent call last):
File "C:\Python25\Lib\site-packages\rpy2\rinterface\tests\test_EmbeddedR.py",
line 16, in testSetWriteC
onsole
self.assertEquals('[1] "3"\n', str.join('', buf))
AssertionError: '[1] "3"\n
After some more tinkering, I was able to build a windows installer for rpy2.
I'll test it tomorrow.
Laurent
2008/10/22 laurent oget <[EMAIL PROTECTED]>:
> I could not find a machine with VS 2003 so i tried my chance with
> MINGW/MSYS, following
>
> http://boodebr.org/ma
quot;, line 164, in split
d, p = splitdrive(p)
File "C:\Python25\lib\ntpath.py", line 119, in splitdrive
if p[1:2] == ':':
TypeError: 'NoneType' object is unsubscriptable
I will do some more digging in distutils to try and figure about what
is going on, but
If I can get my hands on a windows machine with VS 2003 and python
2.5.2, should I expect python setup.py bdist_wininst
to produce a windows installer?
Laurent
-
This SF.Net email is sponsored by the Moblin Your Move Develop
I have been playing with rpy2 for a few days and migrated a batch
process from rpy to rpy2.
I do not have any hard numbers yet but I am already happy to report that:
-the mysterious crash i experience with rpy (a workaround for which
was to call gc() before creating a new dataframe) is not hapenni
I have built and used Rpy2 on ubuntu so it can be done, however the
API are different and replacing rpy with rpy2 in ubuntu packages will
break a lot of code using rpy.
Laurent
2008/10/19 Michael Rutter <[EMAIL PROTECTED]>:
> Hello,
>
> I was spending a lazy Sunday afternoon testing the new R 2.8
In Rpy 1 i c can do
>>> import rpy
>>> d=dict(x=[1,2],y=[2,3])
>>> rpy.set_default_mode(rpy.NO_CONVERSION)
>>> df=rpy.r.as_data_frame(d)
>>> df
and i can then use this dataframe as an argument for lm
Is there any way to do something similar in rpy2? For the moment the
only thing I have found is
What tool does it take to do a windows build? Do I need VS 2003?
L
2008/8/24 laurent <[EMAIL PROTECTED]>:
> Hi,
>
> I am temporarily unable to build win32 compiled package.
> If anyone is willing to help out, please contact me.
>
> I'll be uploading one more alpha (there were still a number of se
Great news!
Do you have an estimate of what soon would be? Days, weeks or months?
Laurent
2008/8/6 Laurent Gautier <[EMAIL PROTECTED]>
> Hi,
>
> Rpy2 version 2.0.0-alpha2 was released.
>
> The beta release, and then the release, should arrive soon now.
>
> It is easier to make changes now that l
Here you are:
>>> from rpy import *
>>> a=[1,2,3,4]
>>> b=r['<'](a,3)
>>> b
[True, True, False, False]
>>>
2008/7/25 Zhang, Minhua <[EMAIL PROTECTED]>:
> In R, I could do:
>
> > a <- c(1,2,3,4)
> > smalla <- a<3
> > smalla
> [1] TRUE TRUE FALSE FALSE
>
> But how do I create such a variable '
%s + %s' %(subvarnames[0], subvarnames[1]),
> data=dataf)
>sumfit = ro.r.summary(fit)
>rsq = sumfit.r['adj.r.squared'][0][0]
>
>res.append((v1_i, v2_i, rsq))
>
> ## check R2 == 1 for the pair (v1, v2)
> [x for x in re
2008/7/17 Laurent Gautier <[EMAIL PROTECTED]>:
> I am a bit confused.
>
> Do you have data frames created and bound to the same Python variable names
> ?
> Or do you have a set of vectors, and subsets put together in different
> data frame ?
> (if you are iterating and building a lot of linear m
d if calls to
> gc
> prevents rpy from crashing.
> To save on runtime, you can try a gc pooling strategy (call gc every N
> iterations).
>
>
>
> 2008/7/15 laurent oget <[EMAIL PROTECTED]>:
> > Calling r.gc() before each creation seems to have solved the prob
Calling r.gc() before each creation seems to have solved the problem. We ran
a whole lot of things over the night without any segmentation fault. This is
however pretty expensive timewise.
Laurent
2008/7/14 laurent oget <[EMAIL PROTECTED]>:
> I am running things with a call to gc() be
I am running things with a call to gc() before each regression, in case what
happens is a race condition where the gc is called in the middle of the
constrction of a new dataframe...
Thanks for the prompt help!
Laurent
2008/7/14 Laurent Gautier <[EMAIL PROTECTED]>:
> 2008/7/15 lau
u could try starting up you embedded R process with '--verbose' and see
> if the problem happens right after garbage collection.
> Without having further details on the exact code ran, it is difficult
> to say more.
>
>
>
>
>
> 2008/7/14 laurent oget <[EM
I think I am seeing pretty much exactly the same issue, as I reported in
another post. In my case I am doing the looping in python, creating a
dataframe from a python dictionary with r.as_data_frame, calling r.lm and
extracting the results from r.summary. The only work-around i have sofar is
to spa
I am using rpy/R to perform linear regressions on a large number of
datasets, in one python run, and am encountering segmentation faults after a
large number of iteration, while handling cases which, taken on their own
run without a problem. My intuition is that the previous iterations somehow
corr
> gcc -pthread -shared build/temp.linux-x86_64-2.5/src/rpymodule2062.o
> build/temp.linux-x86_64-2.5/src/R_eval2062.o
> build/temp.linux-x86_64-2.5/src/io2062.o
> build/temp.linux-x86_64-2.5/src/setenv.o -L/usr/local/lib64/R/bin
> -L/usr/local/lib64/R/lib -L/usr/lib64 -Wl,-R/usr/local/lib64/R/bin
>
e threads, you
> will need to arrange to have a single thread interact with R at a time via
> appropriate locking or delegation.
>
> -G
>
>
> On 6/26/08 11:17AM , "laurent oget" <[EMAIL PROTECTED]> wrote:
>
> f
fellows,
did anybody experiment with running rpy in 2 threads?
-
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/b
Wise Rpy fellows,
I just came back to using R after a few years and am happy to see that the
RPy project is alive and well, and hope I will be able to provide some help
in the future.
For now I have a few questions about rpy2:
-is there a document describing the motivation behind the rewrite and
57 matches
Mail list logo