File tree 1 file changed +17
-1
lines changed
1 file changed +17
-1
lines changed Original file line number Diff line number Diff line change 343
343
Alias for sep.
344
344
"""
345
345
346
+ _fwf_widths = r"""
347
+ colspecs : list of pairs (int, int) or 'infer'. optional
348
+ A list of pairs (tuples) giving the extents of the fixed-width
349
+ fields of each line as half-open intervals (i.e., [from, to[ ).
350
+ String value 'infer' can be used to instruct the parser to try
351
+ detecting the column specifications from the first 100 rows of
352
+ the data which are not being skipped via skiprows (default='infer').
353
+ widths : list of ints. optional
354
+ A list of field widths which can be used instead of 'colspecs' if
355
+ the intervals are contiguous.
356
+ delimiter : str, default ``'\t' + ' '``
357
+ Characters to consider as filler characters in the fixed-width file.
358
+ Can be used to specify the filler character of the fields
359
+ if it is not spaces (e.g., '~').
360
+ """
361
+
346
362
347
363
def _validate_integer (name , val , min_val = 0 ):
348
364
"""
@@ -712,7 +728,7 @@ def parser_f(filepath_or_buffer,
712
728
func_name = 'read_fwf' ,
713
729
summary = ('Read a table of fixed-width formatted lines '
714
730
'into DataFrame.' ),
715
- sep_doc = '' ,
731
+ sep_doc = _fwf_widths ,
716
732
engine_doc = '' ))
717
733
def read_fwf (filepath_or_buffer , colspecs = 'infer' , widths = None , ** kwds ):
718
734
# Check input arguments.
You can’t perform that action at this time.
0 commit comments