@@ -62,13 +62,17 @@ def read_csv(filepath_or_buffer, sep=None, header=0, index_col=None, names=None,
62
62
63
63
def read_table (filepath_or_buffer , sep = '\t ' , header = 0 , index_col = None ,
64
64
names = None , skiprows = None , na_values = None , parse_dates = False ,
65
- date_parser = None ):
65
+ date_parser = None , nrows = None , iterator = False , chunksize = None ):
66
66
return read_csv (filepath_or_buffer , sep = sep , header = header ,
67
67
skiprows = skiprows , index_col = index_col ,
68
68
na_values = na_values , date_parser = date_parser ,
69
- names = names , parse_dates = parse_dates )
69
+ names = names , parse_dates = parse_dates ,
70
+ nrows = nrows , iterator = iterator , chunksize = chunksize )
70
71
71
- _parser_params = """Parameters
72
+ _parser_params = """Also supports optionally iterating or breaking of the file
73
+ into chunks.
74
+
75
+ Parameters
72
76
----------
73
77
filepath_or_buffer : string or file handle / StringIO
74
78
%s
@@ -79,15 +83,26 @@ def read_table(filepath_or_buffer, sep='\t', header=0, index_col=None,
79
83
index_col : int or sequence, default None
80
84
Column to use as the row labels of the DataFrame. If a sequence is
81
85
given, a MultiIndex is used.
86
+ names : array-like
87
+ List of column names
82
88
na_values : list-like, default None
83
89
List of additional strings to recognize as NA/NaN
84
90
parse_dates : boolean, default False
85
91
Attempt to parse dates in the index column(s)
86
92
date_parser : function
87
93
Function to use for converting dates to strings. Defaults to
88
94
dateutil.parser
89
- names : array-like
90
- List of column names"""
95
+ nrows : int, default None
96
+ Number of rows of file to read. Useful for reading pieces of large files
97
+ iterator : boolean, default False
98
+ Return TextParser object
99
+ chunksize : int, default None
100
+ Return TextParser object for iteration
101
+
102
+ Returns
103
+ -------
104
+ result : DataFrame or TextParser
105
+ """
91
106
92
107
_csv_sep = """sep : string, default None
93
108
Delimiter to use. By default will try to automatically determine
0 commit comments