File tree 1 file changed +12
-0
lines changed
1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -64,6 +64,18 @@ Strings passed to ``DataFrame.groupby()`` as the ``by`` parameter may now refere
64
64
65
65
df.groupby(['second', 'A']).sum()
66
66
67
+ Reading dataframes from URLs, in :func:`read_csv` or :func:`read_table`, now
68
+ supports additional compression methods (`xz`, `bz2`, `zip`). Previously, only
69
+ `gzip` compression was supported. By default, compression of URLs and paths are
70
+ now both inferred using their file extensions.
71
+
72
+ .. ipython:: python
73
+
74
+ url = ('https://github.com/pandas-dev/pandas/raw/master/' +
75
+ 'pandas/io/tests/parser/data/salaries.csv.bz2')
76
+ df = pd.read_table(url, compression='infer') # default, infer compression
77
+ df = pd.read_table(url, compression='bz2') # explicitly specify compression
78
+ df.head(2)
67
79
68
80
.. _whatsnew_0200.enhancements.other:
69
81
You can’t perform that action at this time.
0 commit comments