Hello,
This is probably a trivial fix that is available in the sage groups, but I'm striking out searching for preparser / rings.integer / iterable posts. Maybe it is idiosyncratic to pandas?
I'm using pandas for some simple munging; python doesn't like the taste of what sage is passing as the skiprows argument
. (pd.read_csv() works fine from a terminal ipython session)
sage: import pandas as pd
sage: preparser(False)
sage: pd.read_csv('data/6226BB60.dat', skiprows=86)
Error in lines 2-2
Traceback (most recent call last):
File "/mnt/home/HXupCDGU/.sagemathcloud/sage_server.py", line 668, in execute
exec compile(block+'\n', '', 'single') in namespace, locals
File "", line 1, in <module>
File "/usr/local/sage/sage-5.12/local/lib/python2.7/site-packages/pandas/io/parsers.py", line 400, in parser_f
return _read(filepath_or_buffer, kwds)
File "/usr/local/sage/sage-5.12/local/lib/python2.7/site-packages/pandas/io/parsers.py", line 198, in _read
parser = TextFileReader(filepath_or_buffer, **kwds)
File "/usr/local/sage/sage-5.12/local/lib/python2.7/site-packages/pandas/io/parsers.py", line 475, in __init__
self.options, self.engine = self._clean_options(options, engine)
File "/usr/local/sage/sage-5.12/local/lib/python2.7/site-packages/pandas/io/parsers.py", line 562, in _clean_options
skiprows = set() if skiprows is None else set(skiprows)
TypeError: 'sage.rings.integer.Integer' object is not iterable
Hints?
Thanks,
Steve