Hello, I'm enjoying the fun (self-imposed) task of learning Python, RPy2 and PyGTK all in one go, so this question may be partly due to my general status as a newbie. My application will have an embedded console in it. Everything is generally working nicely, however I've noticed that if I load a particularly large data file via R's read.delim() command, Python chokes on the output. The data is loaded as expected, but when I try to print the output to the console, only a portion of the data.frame is printed (~65000 characters), presumably because it reached the maximum string size, and then a seemingly-unrelated GTK widget breaks (but we'll ignore that part for now)
What seems ideal to me would be a way to grab the R console output one line at a time rather than all at once so I can just append those lines individually to my gtk text buffer. I can easily do this for a specific task, such as only for a data.frame, programmatically break it apart by rows. However, I'm hoping for something more general that could apply to any output. I have tried to set robjects.rinterface.setWriteConsole(f) to some function f that just appends to a buffer, but that console callback function doesn't seem to append anything to the buffer if I do a call to robjects.r("some command here"). That said, I'm not sure how this method works exactly and if I'd encounter the same problem because a single string of the entire output would just be appended to the buffer. Ok that was a bit long-winded. Is there an obvious solution to this problem that I'm missing? Am I not being clever enough? Thanks for your help, brandon ------------------------------------------------------------------------------ Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are powering Web 2.0 with engaging, cross-platform capabilities. Quickly and easily build your RIAs with Flex Builder, the Eclipse(TM)based development software that enables intelligent coding and step-through debugging. Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com _______________________________________________ rpy-list mailing list rpy-list@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rpy-list