Why does Rpy/R-plot work under PythonWin, but not under commandline/IDLE?

Discussion in 'Python' started by Bo Peng, Jan 9, 2006.

  1. Bo Peng

    Bo Peng Guest

    Dear list,

    I am using rpy, a python module to control statistical package R from
    python. Running the following commands

    >>> from rpy import *
    >>> r.plot(0)


    will pass command 'plot' to R and run it. I notice that the R-plot will
    not refresh (a window is created but the figure is not drawn) until the
    next plot command is executed,
    * when I use python (2.3, 2.4) command line or IDLE
    * NOT when I use pythonwin ( provided with pywin32 package)

    Since rpy+R works under python+pythonwin, I assume that this is not a
    problem with rpy or R. Does anyone know why commandline/IDLE cause this
    problem, while PythonWin does not? I am interested to know what I can do
    in commandline (or in rpy) to fix this problem.

    Regards,
    Bo
     
    Bo Peng, Jan 9, 2006
    #1
    1. Advertisements

  2. Bo Peng

    Bo Peng Guest

    Bo Peng wrote:
    > Does anyone know why commandline/IDLE cause this
    > problem, while PythonWin does not? I am interested to know what I can do
    > in commandline (or in rpy) to fix this problem.


    Just note that R/plot works fine both from command window and a R-GUI.

    Bo
     
    Bo Peng, Jan 9, 2006
    #2
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    2
    Views:
    3,205
    Peter
    Sep 30, 2005
  2. Jonck
    Replies:
    12
    Views:
    1,450
    Thomas G. Marshall
    Sep 28, 2004
  3. stephan
    Replies:
    0
    Views:
    615
    stephan
    Jul 30, 2003
  4. Ollie
    Replies:
    0
    Views:
    535
    Ollie
    Oct 2, 2003
  5. j_mckitrick

    Why does one work, but not the other?

    j_mckitrick, Jun 18, 2004, in forum: Python
    Replies:
    6
    Views:
    468
    Terry Reedy
    Jun 18, 2004
  6. Dr. Colombes
    Replies:
    1
    Views:
    1,263
    John Hunter
    Feb 10, 2005
  7. Horace Nunley

    why why why does function not work

    Horace Nunley, Sep 27, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    718
    =?Utf-8?B?UGV0ZXIgQnJvbWJlcmcgW0MjIE1WUF0=?=
    Sep 27, 2006
  8. Mr. SweatyFinger
    Replies:
    2
    Views:
    2,840
    Smokey Grindel
    Dec 2, 2006
Loading...