Estou usando o pandas no Python para ler um arquivo CSV que está no meu computador, porém aparece uma mensagem de erro, parece que ele não encontra o arquivo:
import pandas as pd
reclamacoes = pd.read_csv("C:\Users\Reinaldo\Documents\Jornalismo_de_dados\Justica\reclamacoes\2017-1sem1.csv",sep=';')
import pandas as pd reclamacoes = pd.read_csv("C:\Users\Reinaldo\Documents\Jornalismo_de_dados\Justica\reclamacoes\2017-1sem1.csv",sep=';') IOErrorTraceback (most recent call last) <ipython-input-4-685400fce544> in <module>() ----> 1 reclamacoes = pd.read_csv("C:\Users\Reinaldo\Documents\Jornalismo_de_dados\Justica\reclamacoes\2017-1sem1.csv",sep=';') c:\cygwin64\home\reinaldo\code\justica\lib\site-packages\pandas\io\parsers.pyc
in parser_f(filepath_or_buffer, sep, delimiter, header, names, index_col, usecols, squeeze, prefix, mangle_dupe_cols, dtype, engine, converters, true_values, false_values, skipinitialspace, skiprows, nrows, na_values, keep_default_na, na_filter, verbose, skip_blank_lines, parse_dates, infer_datetime_format, keep_date_col, date_parser, dayfirst, iterator, chunksize, compression, thousands, decimal, lineterminator, quotechar, quoting, escapechar, comment, encoding, dialect, tupleize_cols, error_bad_lines, warn_bad_lines, skipfooter, skip_footer, doublequote, delim_whitespace, as_recarray, compact_ints, use_unsigned, low_memory, buffer_lines, memory_map, float_precision) 653 skip_blank_lines=skip_blank_lines) 654 --> 655 return _read(filepath_or_buffer, kwds) 656 657 parser_f.name = name
c:\cygwin64\home\reinaldo\code\justica\lib\site-packages\pandas\io\parsers.pyc
in _read(filepath_or_buffer, kwds) 403 404 # Create the parser. --> 405 parser = TextFileReader(filepath_or_buffer, **kwds) 406 407 if chunksize or iterator:
c:\cygwin64\home\reinaldo\code\justica\lib\site-packages\pandas\io\parsers.pyc
in init(self, f, engine, **kwds) 762 self.options['has_index_names'] = kwds['has_index_names'] 763 --> 764 self._make_engine(self.engine) 765 766 def close(self):
c:\cygwin64\home\reinaldo\code\justica\lib\site-packages\pandas\io\parsers.pyc
in _make_engine(self, engine) 983 def _make_engine(self, engine='c'): 984 if engine == 'c': --> 985 self._engine = CParserWrapper(self.f, **self.options) 986 else: 987 if engine == 'python':
c:\cygwin64\home\reinaldo\code\justica\lib\site-packages\pandas\io\parsers.pyc
in init(self, src, **kwds) 1603 kwds['allow_leading_cols'] = self.index_col is not False 1604 -> 1605 self._reader = parsers.TextReader(src, **kwds) 1606 1607 # XXX
pandas\_libs\parsers.pyx in pandas._libs.parsers.TextReader.__cinit__
(pandas_libs\parsers.c:4209)()
pandas\_libs\parsers.pyx in pandas._libs.parsers.TextReader._setup_parser_source
(pandas_libs\parsers.c:8873)()
eclamacoes�7-1sem1.csv does not existnaldo\Documents\Jornalismo_de_dados\Justica
Alguém sabe o que pode ser?
O arquivo pode ser baixado aqui: http://dados.gov.br/dataset/reclamacoes-do-consumidor-gov-br1/resource/1d0e048b-6a14-47e0-8145-3dace76185ed