Re: [Rpy] Is the AGP still making sense ?

2013-11-27 Thread Artur Wroblewski
On Wed, Nov 27, 2013 at 7:51 PM, Alan G Isaac wrote: > On 11/27/2013 2:24 PM, Artur Wroblewski wrote: >> We might have some evidence that this or that license worked well for >> a given project, but purpose of a license is to give various groups of people >> certain r

Re: [Rpy] Is the AGP still making sense ?

2013-11-27 Thread Artur Wroblewski
On Wed, Nov 27, 2013 at 6:55 PM, Alan G Isaac wrote: > On 11/27/2013 1:41 PM, Artur Wroblewski wrote: >> GPL was never >> designed to bring more contributions to a project. > > > Exactly. Also, I do not think any other license was created for such purpose. We might

Re: [Rpy] Is the AGP still making sense ?

2013-11-27 Thread Artur Wroblewski
On Wed, Nov 27, 2013 at 2:57 PM, Alan G Isaac wrote: > On 11/27/2013 8:53 AM, Dirk Eddelbuettel wrote: >> That the GPL is viral is still a feature and not a bug. > [...] > If a project gets fewer users > and fewer code contributions by choosing the GPL, > it is hard to see that as a good thing.

Re: [Rpy] How to call ltm function using rpy package in python

2013-01-08 Thread Artur Wroblewski
On Tue, Jan 8, 2013 at 10:34 AM, Mohit Khanna wrote: > I am trying the following code-- > > from rpy import * > r.library("ltm") > > dat= #some data frame or matrix > r.ltm(r('dat~z1')) > > error coming is--- > RPy_RException: Error in eval(expr, envir, enclos) : object 'dat' not found > > Please

Re: [Rpy] rpy2-2.3.1

2012-12-11 Thread Artur Wroblewski
On Tue, Dec 11, 2012 at 5:10 PM, Laurent Gautier wrote: > Hi, > > One annoying issue Python 3.3, not caught by the unit tests, slipped > through the beta period. > This is now fixed in rpy2-2.3.1, already available on Pypi. Thanks for the fast fix and immediate release. [...] Regards, w -

Re: [Rpy] rpy2-2.3.0

2012-12-10 Thread Artur Wroblewski
On Mon, Dec 10, 2012 at 8:32 PM, Laurent Gautier wrote: > On 2012-12-10 21:16, Artur Wroblewski wrote: >> >> On Mon, Dec 10, 2012 at 6:29 PM, Laurent Gautier >> wrote: >>> >>> Hi, >>> >>> Rpy2-2.3.0 is (finally) out and is on pypi. To upg

Re: [Rpy] rpy2-2.3.0

2012-12-10 Thread Artur Wroblewski
On Mon, Dec 10, 2012 at 6:29 PM, Laurent Gautier wrote: > Hi, > > Rpy2-2.3.0 is (finally) out and is on pypi. To upgrade, `pip install > rpy2 --upgrade` should just do the trick. Hi, Not sure if that's known problem, but with the following script cut import rpy2.robjects as ro R = ro.

Re: [Rpy] working with R - 2.15.1 (06-22-2012) - what Rpy version

2012-10-18 Thread Artur Wroblewski
On Thu, Oct 18, 2012 at 12:17 PM, Jaime A. Florez wrote: > Hi, > > I am just starting with Rpy so I would appreciate a little more advice: > > * I have the latest version of R (2.15.1,06-22-2012). Can Rpy2 handle > that R version? > - If Rpy can handle it, what version of Rpy is that? >

[Rpy] iterating data frame rows

2012-06-28 Thread Artur Wroblewski
Hi, Please consider the following: from rpy2 import robjects as ro df = ro.DataFrame({'a': ro.FloatVector((5,2,3)), 'b': ro.StrVector(['x1-','y2-','z3-'])}) v = ((r.rx2('a')[0], r.rx2('b')[0]) for r in df.iter_row()) print(list(v)) The result is [(5.0, 1), (2.0, 1), (3.0, 1

Re: [Rpy] Is there an easy way to make a dataframe with different value lengths?

2012-04-03 Thread Artur Wroblewski
On Tue, Apr 3, 2012 at 5:12 PM, Laurent Gautier wrote: > On 2012-04-03 16:51, Dirk Eddelbuettel wrote: >> On 3 April 2012 at 15:31, Niek de Klein wrote: >> | Hi everyone, >> | >> | When I do: >> | >> | import rpy2.robjects as R >> | exampleDict = {'colum1':R.IntVector([1,2,3]), >> 'column2':R.Flo

Re: [Rpy] Dictionary order

2011-12-06 Thread Artur Wroblewski
On Tue, Dec 6, 2011 at 3:56 PM, Marko Limbek wrote: > This is my problem. > I get results of some method and I should match coordinates from one > dictionary and names of categories in another dictionary. Is that possible? Any example? :) Regards, w

[Rpy] rpy2 and data

2011-10-08 Thread Artur Wroblewski
Hi, Let's say I create a vector of integers: alist = list(range(10 ** 7)) avec = IntVector(alist) How efficient is above? Do I have two copies of data or one? If there is one copy of data, then what about data frames with large vectors? Best regards, w ---

Re: [Rpy] What is the equivalent of %in% in rpy2?

2011-09-13 Thread Artur Wroblewski
On Tue, Sep 13, 2011 at 7:01 AM, Laurent Gautier wrote: > On 2011-09-12 21:16, Artur Wroblewski wrote: >> >> On Mon, Sep 12, 2011 at 12:26 PM, Laurent Gautier >>  wrote: >>> >>> Probably not. >>> >>> R is doing a lot of things behind th

Re: [Rpy] What is the equivalent of %in% in rpy2?

2011-09-12 Thread Artur Wroblewski
On Mon, Sep 12, 2011 at 12:26 PM, Laurent Gautier wrote: > Probably not. > > R is doing a lot of things behind the hood. Sometimes it is good, sometimes > it is bad. > The code snippet given to you has a quadratic time-complexity ( O(nm) ). It > can be make linearithmic ( O(n log(m) ) ) simply: >

Re: [Rpy] More seg faults (Rpy 2.2.0beta3)

2011-05-22 Thread Artur Wroblewski
On Sun, May 22, 2011 at 11:51 AM, Laurent Gautier wrote: > The problem might be solved with the revision 1551:19ecaa6a5d6c, and was in > rpy2 and NARealType as people hinted it. > Can people confirm that is now working for them ? tested with my app. no segfaults so far. do you mind closing issue

Re: [Rpy] More seg faults (Rpy 2.2.0beta3)

2011-05-21 Thread Artur Wroblewski
On Sat, May 21, 2011 at 12:35 PM, Laurent Gautier wrote: [...] > Out of curiosity, do people experiencing problems have 32-bit or 64-bit OS ? i have two x86 64-bit systems (PLD Linux and Fedora 14) on which I get segfaults. Out of curiosity I have just checked it with quite old ppc 32-bit system

Re: [Rpy] More seg faults (Rpy 2.2.0beta3)

2011-05-20 Thread Artur Wroblewski
On Fri, May 20, 2011 at 2:16 PM, Laurent Gautier wrote: [...] > This is a problem since rpy2's rinterface is obviously initialized before > the embedded R is (rpy2.initr() must be called to initialize R). [...] > Something is already puzzling: why was this sometimes working ? Maybe because, under

Re: [Rpy] More seg faults (Rpy 2.2.0beta3)

2011-05-19 Thread Artur Wroblewski
On Thu, May 19, 2011 at 8:32 PM, Thomas Kluyver wrote: > On 19 May 2011 19:36, Artur Wroblewski wrote: >> >> At the moment the segfault can be reproduced as follows (using UCS4 >> based build) > > OK, interesting. I still can't replicate it, in either Python

Re: [Rpy] More seg faults (Rpy 2.2.0beta3)

2011-05-19 Thread Artur Wroblewski
On Thu, May 19, 2011 at 12:46 PM, Artur Wroblewski wrote: [...] > While the os.popen does not cause my app to crash with UCS4, still > my application segfaults... just in different place. I will try to narrow it > and provide some stack trace later this evening. At the moment the segfau

Re: [Rpy] More seg faults (Rpy 2.2.0beta3)

2011-05-19 Thread Artur Wroblewski
While the os.popen does not cause my app to crash with UCS4, still my application segfaults... just in different place. I will try to narrow it and provide some stack trace later this evening. Best regards, Artur > On 19 May 2011, at 11:22, Thomas Kluyver wrote: > > On 19 May 2011 08:1

Re: [Rpy] More seg faults (Rpy 2.2.0beta3)

2011-05-19 Thread Artur Wroblewski
On Thu, May 19, 2011 at 12:19 AM, Thomas Kluyver wrote: > Ah, Unicode. I believe the builds from python.org are narrow unicode (i.e. > UTF-16), whereas those shipped in many Linux distros (including the one I > use) are wide unicode (UTF-32). This might explain why I can't replicate > your segfaul

Re: [Rpy] More seg faults (Rpy 2.2.0beta3)

2011-05-18 Thread Artur Wroblewski
On Fri, May 13, 2011 at 7:01 PM, Christian Marquardt wrote: > I tried your popen script before, but it's running fine - no core dump. I'll > might try to compile a debuggable python over the weekend... I have just discovered that compiling Python with "--with-wide-unicode" helps in my os.popen t

Re: [Rpy] newbie questions

2011-05-17 Thread Artur Wroblewski
On Tue, May 17, 2011 at 2:41 PM, Massimo Di Pierro wrote: [...] > 3) I understand that robjects.r['pi'] returns a vector of one element. Is > this an R "feature" or an rpy2 feature? R returns vector for pi number. Best regards, Artur --

Re: [Rpy] More seg faults (Rpy 2.2.0beta3)

2011-05-13 Thread Artur Wroblewski
On Fri, May 13, 2011 at 03:49:49PM +, Christian Marquardt wrote: > Hello, > > I experienced seg faults and core dumps related to rpy with several > recent versions of rpy, and reported some of them on this list. Here's > another one, this time with rpy 2.2.0beta3 (and python 2.7.1) > occurring

Re: [Rpy] Seg fault with IPython

2011-05-10 Thread Artur Wroblewski
On Wed, May 11, 2011 at 12:22 AM, Yang Zhang wrote: > I have R 2.13.0 installed via the CRAN Ubuntu lucid repo (installed > packages r-base, r-base-dev, and liblapack-dev).  When I tried out > RPy2 (either 2.1 or 2.2) from ipython, I get a seg fault.  Details > below.  Any ideas what's going on?  

Re: [Rpy] rpy 2.2.0 setup.py

2011-05-01 Thread Artur Wroblewski
On Sun, May 1, 2011 at 10:36 PM, Laurent Gautier wrote: > On 2011-05-01 20:14, Artur Wroblewski wrote: >> >> Hi, >> >> The setup.py on version_2.2.0 contains line >> >>     package_prefix = os.path.join('build', 'python3_rpy') >>

[Rpy] rpy 2.2.0 setup.py

2011-05-01 Thread Artur Wroblewski
Hi, The setup.py on version_2.2.0 contains line package_prefix = os.path.join('build', 'python3_rpy') Shouldn't it be package_prefix = os.path.join('build', 'rpy') ? Best regards, w -- WhatsUp Gold - Downloa

[Rpy] python 3 and unicode (rpy 2.2.0)

2011-05-01 Thread Artur Wroblewski
Hi, Some time ago I have raised the bug https://bitbucket.org/lgautier/rpy2/issue/65/segfault-with-unicode-characters-in-python It is marked as fixed, but the problem still persists. Tested with python 3.2. Best regards, w

[Rpy] float vector behaviour with NA_Real (ver. 2.2.0)

2011-04-25 Thread Artur Wroblewski
Hello, Please take a look at >>> import rpy2.robjects as ro >>> ro.FloatVector([ro.NA_Real, 1, 2, 3, ro.NA_Real]) [0.00, 1.00, 2.00, 3.00, 0.00] Why NA_Real is converted to 0.0? Is it a bug or designed behaviour? Best regards, w --

Re: [Rpy] rpy2-2.2.0beta is out

2011-04-21 Thread Artur Wroblewski
On Thu, Apr 21, 2011 at 05:03:21PM +0200, Laurent Gautier wrote: > As the subject lines says. > This is now the default version obtained through Pypi and related > utilities (pip, easy_install, distribute, ...). > > The final release of 2.2.0 is scheduled to happen within 2 months. Is it suppose

Re: [Rpy] consolePrint() and Python 3

2011-02-28 Thread Artur Wroblewski
On Mon, Feb 28, 2011 at 1:05 PM, Laurent Gautier wrote: >> Indeed, you mentioned NA_Real, but what else can be put in FloatVector >> beside float number? Some R's NULL representation? What about NaN? [...] > rinterface.NULL is not accepted (for I believe R's behaviour is confusing). > Nan in Pytho

Re: [Rpy] consolePrint() and Python 3

2011-02-25 Thread Artur Wroblewski
On Fri, Feb 25, 2011 at 5:25 PM, Laurent wrote: > On 24/02/11 11:26, Artur Wroblewski wrote: [...] >> In Python >> >>     >>>  (1, None, 2, None, 3) >>     (1, None, 2, None, 3) >> >> In R >> >>     >  c(1, NULL, 2, NULL, 3) >>

Re: [Rpy] consolePrint() and Python 3

2011-02-24 Thread Artur Wroblewski
On Thu, Feb 24, 2011 at 07:57:19AM +0100, Laurent wrote: > On 24/02/11 00:12, Artur Wroblewski wrote: > >On Wed, Feb 23, 2011 at 8:00 PM, Laurent Gautier wrote: > >[...] > >>Rpy2 aims at doing very little hidden magic or second guessing of the user's >