url
stringlengths
55
59
repository_url
stringclasses
1 value
labels_url
stringlengths
69
73
comments_url
stringlengths
64
68
events_url
stringlengths
62
66
html_url
stringlengths
44
49
id
int64
338k
1.06B
node_id
stringlengths
18
32
number
int64
1
44.6k
title
stringlengths
1
590
user
dict
labels
listlengths
0
9
state
stringclasses
2 values
locked
bool
2 classes
assignee
dict
assignees
listlengths
0
5
milestone
dict
comments
int64
0
477
created_at
timestamp[us, tz=UTC]
updated_at
timestamp[us, tz=UTC]
closed_at
timestamp[us, tz=UTC]
author_association
stringclasses
3 values
active_lock_reason
stringclasses
4 values
body
stringlengths
0
251k
reactions
dict
timeline_url
stringlengths
64
68
performed_via_github_app
float64
draft
float64
0
1
pull_request
dict
https://api.github.com/repos/pandas-dev/pandas/issues/13204
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13204/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13204/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13204/events
https://github.com/pandas-dev/pandas/issues/13204
155,284,017
MDU6SXNzdWUxNTUyODQwMTc=
13,204
groupby with index = False returns NANs when column is categorical.
{ "avatar_url": "https://avatars.githubusercontent.com/u/4855603?v=4", "events_url": "https://api.github.com/users/toasteez/events{/privacy}", "followers_url": "https://api.github.com/users/toasteez/followers", "following_url": "https://api.github.com/users/toasteez/following{/other_user}", "gists_url": "https://api.github.com/users/toasteez/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/toasteez", "id": 4855603, "login": "toasteez", "node_id": "MDQ6VXNlcjQ4NTU2MDM=", "organizations_url": "https://api.github.com/users/toasteez/orgs", "received_events_url": "https://api.github.com/users/toasteez/received_events", "repos_url": "https://api.github.com/users/toasteez/repos", "site_admin": false, "starred_url": "https://api.github.com/users/toasteez/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/toasteez/subscriptions", "type": "User", "url": "https://api.github.com/users/toasteez" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "729FCF", "default": false, "description": null, "id": 233160, "name": "Groupby", "node_id": "MDU6TGFiZWwyMzMxNjA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Groupby" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
4
2016-05-17T15:07:21Z
2016-07-03T23:28:31Z
2016-07-03T23:28:31Z
NONE
null
Please see stackoverflow for example of issue http://stackoverflow.com/questions/37279260/why-doesnt-pandas-allow-a-categorical-column-to-be-used-in-groupby?noredirect=1#comment62084780_37279260 ``` >>> pd.__version__ '0.18.1' >>> # import the pandas module import pandas as pd # Create an example dataframe raw_data = {'Date': ['2016-05-13', '2016-05-13', '2016-05-13', '2016-05-13', '2016-05-13','2016-05-13', '2016-05-13', '2016-05-13', '2016-05-13', '2016-05-13', '2016-05-13', '2016-05-13', '2016-05-13', '2016-05-13', '2016-05-13', '2016-05-13', '2016-05-13'], 'Portfolio': ['A', 'A', 'A', 'A', 'A', 'A', 'B', 'B','B', 'B', 'B', 'C', 'C', 'C', 'C', 'C', 'C'], 'Duration': [1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3], 'Yield': [0.3, 0.3, 0.3, 0.3, 0.3, 0.3, 2, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1],} df = pd.DataFrame(raw_data, columns = ['Date', 'Portfolio', 'Duration', 'Yield']) df['Portfolio'] = pd.Categorical(df['Portfolio'],['C', 'B', 'A']) df=df.sort_values('Portfolio') dfs = df.groupby(['Date','Portfolio'], as_index =False).sum() print(dfs) Date Portfolio Duration Yield Date Portfolio 13/05/2016 C NaN NaN NaN NaN B NaN NaN NaN NaN A NaN NaN NaN NaN ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13204/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13204/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13205
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13205/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13205/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13205/events
https://github.com/pandas-dev/pandas/pull/13205
155,293,972
MDExOlB1bGxSZXF1ZXN0NzAzODExNTA=
13,205
Numindexname
{ "avatar_url": "https://avatars.githubusercontent.com/u/1224492?v=4", "events_url": "https://api.github.com/users/toobaz/events{/privacy}", "followers_url": "https://api.github.com/users/toobaz/followers", "following_url": "https://api.github.com/users/toobaz/following{/other_user}", "gists_url": "https://api.github.com/users/toobaz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/toobaz", "id": 1224492, "login": "toobaz", "node_id": "MDQ6VXNlcjEyMjQ0OTI=", "organizations_url": "https://api.github.com/users/toobaz/orgs", "received_events_url": "https://api.github.com/users/toobaz/received_events", "repos_url": "https://api.github.com/users/toobaz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/toobaz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/toobaz/subscriptions", "type": "User", "url": "https://api.github.com/users/toobaz" }
[ { "color": "0b02e1", "default": false, "description": "Related to indexing on series/frames, not to indexes themselves", "id": 2822098, "name": "Indexing", "node_id": "MDU6TGFiZWwyODIyMDk4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Indexing" }, { "color": "0052cc", "default": false, "description": "pandas objects compatability with Numpy or Python functions", "id": 76865106, "name": "Compat", "node_id": "MDU6TGFiZWw3Njg2NTEwNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Compat" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
22
2016-05-17T15:46:18Z
2016-06-14T14:08:55Z
2016-06-14T13:53:54Z
MEMBER
null
- [x] closes #12309 - [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` - [x] whatsnew entries: name passing, unsupported `dtype`s, `copy=true` for `DateTimeIndex` This is a rebased & updated version of #12331 I would say the [last commit](https://github.com/pydata/pandas/pull/13205/commits/cd89efc88afd6fc5b0e973da4338cefdbea52d51) is the most critical one: it exposes the consequences of making numeric indices only support their default `dtype`. By the way: I had interpreted [your comment](https://github.com/pydata/pandas/pull/12331#discussion_r54882912) as "raise if `dtype` is set", but I don't think this is what we want, since it breaks the obj -> str(obj) -> obj roundtrip. So I raise only if `dtype` is not the expected dtype.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 1, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13205/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13205/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13205.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13205", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13205.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13205" }
https://api.github.com/repos/pandas-dev/pandas/issues/13206
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13206/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13206/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13206/events
https://github.com/pandas-dev/pandas/issues/13206
155,300,875
MDU6SXNzdWUxNTUzMDA4NzU=
13,206
BUG: Quote table names in to_sql
{ "avatar_url": "https://avatars.githubusercontent.com/u/5654544?v=4", "events_url": "https://api.github.com/users/the4thv/events{/privacy}", "followers_url": "https://api.github.com/users/the4thv/followers", "following_url": "https://api.github.com/users/the4thv/following{/other_user}", "gists_url": "https://api.github.com/users/the4thv/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/the4thv", "id": 5654544, "login": "the4thv", "node_id": "MDQ6VXNlcjU2NTQ1NDQ=", "organizations_url": "https://api.github.com/users/the4thv/orgs", "received_events_url": "https://api.github.com/users/the4thv/received_events", "repos_url": "https://api.github.com/users/the4thv/repos", "site_admin": false, "starred_url": "https://api.github.com/users/the4thv/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/the4thv/subscriptions", "type": "User", "url": "https://api.github.com/users/the4thv" }
[ { "color": "4E9A06", "default": false, "description": null, "id": 76812, "name": "Enhancement", "node_id": "MDU6TGFiZWw3NjgxMg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Enhancement" }, { "color": "5319e7", "default": false, "description": "to_sql, read_sql, read_sql_query", "id": 47232590, "name": "IO SQL", "node_id": "MDU6TGFiZWw0NzIzMjU5MA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20SQL" } ]
closed
false
null
[]
{ "closed_at": "2017-10-28T18:54:27Z", "closed_issues": 764, "created_at": "2017-03-23T13:26:25Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2017-10-27T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/46", "id": 2406656, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/46/labels", "node_id": "MDk6TWlsZXN0b25lMjQwNjY1Ng==", "number": 46, "open_issues": 0, "state": "closed", "title": "0.21.0", "updated_at": "2018-07-08T21:53:21Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/46" }
10
2016-05-17T16:15:24Z
2019-05-01T20:07:48Z
2017-06-07T20:53:48Z
NONE
null
``` python xl.to_sql(con=conn, name='d1187b08-4943-4c8d-a7f6-6c06b7cb9509', flavor='mysql', if_exists='replace') Traceback (most recent call last): File "<input>", line 1, in <module> File "C:\Dev\Project\www\venv\project\lib\site-packages\pandas\core\generic.py", line 1165, in to_sql chunksize=chunksize, dtype=dtype) File "C:\Dev\Project\www\venv\project\lib\site-packages\pandas\io\sql.py", line 571, in to_sql chunksize=chunksize, dtype=dtype) File "C:\Dev\Project\www\venv\project\lib\site-packages\pandas\io\sql.py", line 1660, in to_sql dtype=dtype) File "C:\Dev\Project\www\venv\project\lib\site-packages\pandas\io\sql.py", line 1417, in __init__ super(SQLiteTable, self).__init__(*args, **kwargs) File "C:\Dev\Project\www\venv\project\lib\site-packages\pandas\io\sql.py", line 669, in __init__ self.table = self._create_table_setup() File "C:\Dev\Project\www\venv\project\lib\site-packages\pandas\io\sql.py", line 1478, in _create_table_setup ',\n '.join(create_tbl_stmts) + "\n)"] File "C:\Dev\Project\www\venv\project\lib\site-packages\pandas\io\sql.py", line 1363, in _get_valid_mysql_name raise ValueError("Invalid MySQL identifier '%s'" % uname) ValueError: Invalid MySQL identifier '`d1187b08-4943-4c8d-a7f6-6c06b7cb9509`' ``` #### Expected Output (no output, just successful write to db table) #### output of `pd.show_versions()` ## INSTALLED VERSIONS commit: None python: 3.4.3.final.0 python-bits: 32 OS: Windows OS-release: 7 machine: AMD64 processor: Intel64 Family 6 Model 58 Stepping 9, GenuineIntel byteorder: little LC_ALL: None LANG: None pandas: 0.18.1 nose: None pip: 8.1.2 setuptools: 18.0.1 Cython: None numpy: 1.11.0 scipy: None statsmodels: None xarray: None IPython: None sphinx: None patsy: None dateutil: 2.4.2 pytz: 2015.4 blosc: None bottleneck: None tables: None numexpr: None matplotlib: None openpyxl: None xlrd: 0.9.3 xlwt: 0.8.0 xlsxwriter: 0.7.3 lxml: None bs4: 4.4.0 html5lib: 0.999999 httplib2: 0.9.2 apiclient: 1.5.0 sqlalchemy: None pymysql: None psycopg2: None jinja2: None boto: 2.38.0 pandas_datareader: None # Proposed fix: Line 1478 of pandas\io\sql.py, wrapping the escape(self.name) with ``: create_stmts = ["CREATE TABLE `" + escape(self.name) + "` (\n" + ',\n '.join(create_tbl_stmts) + "\n)"]
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13206/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13206/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13207
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13207/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13207/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13207/events
https://github.com/pandas-dev/pandas/issues/13207
155,338,716
MDU6SXNzdWUxNTUzMzg3MTY=
13,207
BUG: Index doesn't have an .empty attribute
{ "avatar_url": "https://avatars.githubusercontent.com/u/1924092?v=4", "events_url": "https://api.github.com/users/chris-b1/events{/privacy}", "followers_url": "https://api.github.com/users/chris-b1/followers", "following_url": "https://api.github.com/users/chris-b1/following{/other_user}", "gists_url": "https://api.github.com/users/chris-b1/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/chris-b1", "id": 1924092, "login": "chris-b1", "node_id": "MDQ6VXNlcjE5MjQwOTI=", "organizations_url": "https://api.github.com/users/chris-b1/orgs", "received_events_url": "https://api.github.com/users/chris-b1/received_events", "repos_url": "https://api.github.com/users/chris-b1/repos", "site_admin": false, "starred_url": "https://api.github.com/users/chris-b1/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/chris-b1/subscriptions", "type": "User", "url": "https://api.github.com/users/chris-b1" }
[ { "color": "0b02e1", "default": false, "description": "Related to indexing on series/frames, not to indexes themselves", "id": 2822098, "name": "Indexing", "node_id": "MDU6TGFiZWwyODIyMDk4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Indexing" }, { "color": "AD7FA8", "default": false, "description": null, "id": 35818298, "name": "API Design", "node_id": "MDU6TGFiZWwzNTgxODI5OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/API%20Design" } ]
closed
false
null
[]
{ "closed_at": "2017-05-06T10:20:19Z", "closed_issues": 987, "created_at": "2016-02-08T15:30:21Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "after 0.19.x series", "due_on": "2017-05-12T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/39", "id": 1570595, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/39/labels", "node_id": "MDk6TWlsZXN0b25lMTU3MDU5NQ==", "number": 39, "open_issues": 0, "state": "closed", "title": "0.20.0", "updated_at": "2018-10-28T08:18:42Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/39" }
4
2016-05-17T19:14:01Z
2017-03-28T19:10:59Z
2017-03-28T19:10:59Z
CONTRIBUTOR
null
#### Code Sample, a copy-pastable example if possible ``` python In [108]: i = pd.Index([]) In [109]: bool(i) --------------------------------------------------------------------------- ValueError Traceback (most recent call last) <ipython-input-109-43b3c3723ad4> in <module>() ----> 1 bool(i) C:\Users\Chris\Anaconda\envs\py35\lib\site-packages\pandas\indexes\base.py in __nonzero__(self) 1227 raise ValueError("The truth value of a {0} is ambiguous. " 1228 "Use a.empty, a.bool(), a.item(), a.any() or a.all()." -> 1229 .format(self.__class__.__name__)) 1230 1231 __bool__ = __nonzero__ ValueError: The truth value of a Index is ambiguous. Use a.empty, a.bool(), a.item(), a.any() or a.all(). In [110]: i.empty --------------------------------------------------------------------------- AttributeError Traceback (most recent call last) <ipython-input-110-1524e0ba750e> in <module>() ----> 1 i.empty AttributeError: 'Index' object has no attribute 'empty' ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13207/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13207/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13208
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13208/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13208/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13208/events
https://github.com/pandas-dev/pandas/issues/13208
155,364,158
MDU6SXNzdWUxNTUzNjQxNTg=
13,208
Series __finalized__ not correctly called in binary operators
{ "avatar_url": "https://avatars.githubusercontent.com/u/1331338?v=4", "events_url": "https://api.github.com/users/jdfekete/events{/privacy}", "followers_url": "https://api.github.com/users/jdfekete/followers", "following_url": "https://api.github.com/users/jdfekete/following{/other_user}", "gists_url": "https://api.github.com/users/jdfekete/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jdfekete", "id": 1331338, "login": "jdfekete", "node_id": "MDQ6VXNlcjEzMzEzMzg=", "organizations_url": "https://api.github.com/users/jdfekete/orgs", "received_events_url": "https://api.github.com/users/jdfekete/received_events", "repos_url": "https://api.github.com/users/jdfekete/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jdfekete/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jdfekete/subscriptions", "type": "User", "url": "https://api.github.com/users/jdfekete" }
[ { "color": "0e8a16", "default": true, "description": null, "id": 717120670, "name": "good first issue", "node_id": "MDU6TGFiZWw3MTcxMjA2NzA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/good%20first%20issue" }, { "color": "cdea3c", "default": false, "description": "Unit test(s) needed to prevent regressions", "id": 986278782, "name": "Needs Tests", "node_id": "MDU6TGFiZWw5ODYyNzg3ODI=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Needs%20Tests" }, { "color": "abf98b", "default": false, "description": "Subclassing pandas objects", "id": 2559562239, "name": "Subclassing", "node_id": "MDU6TGFiZWwyNTU5NTYyMjM5", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Subclassing" } ]
closed
false
null
[]
{ "closed_at": "2020-01-30T12:18:05Z", "closed_issues": 2207, "created_at": "2012-09-13T02:13:00Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/329591?v=4", "events_url": "https://api.github.com/users/wesm/events{/privacy}", "followers_url": "https://api.github.com/users/wesm/followers", "following_url": "https://api.github.com/users/wesm/following{/other_user}", "gists_url": "https://api.github.com/users/wesm/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/wesm", "id": 329591, "login": "wesm", "node_id": "MDQ6VXNlcjMyOTU5MQ==", "organizations_url": "https://api.github.com/users/wesm/orgs", "received_events_url": "https://api.github.com/users/wesm/received_events", "repos_url": "https://api.github.com/users/wesm/repos", "site_admin": false, "starred_url": "https://api.github.com/users/wesm/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/wesm/subscriptions", "type": "User", "url": "https://api.github.com/users/wesm" }, "description": "on-merge: backport to 1.0.x", "due_on": "2020-02-01T08:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/16", "id": 174211, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/16/labels", "node_id": "MDk6TWlsZXN0b25lMTc0MjEx", "number": 16, "open_issues": 0, "state": "closed", "title": "1.0.0", "updated_at": "2020-01-30T12:18:05Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/16" }
12
2016-05-17T21:17:29Z
2020-12-07T08:17:00Z
2020-01-07T23:45:41Z
NONE
null
``` #!/bin/env python """ Example bug in derived Pandas Series. __finalized__ is not called in arithmetic binary operators, but it is in in some booleans cases. >>> m = MySeries([1, 2, 3], name='test') >>> m.x = 42 >>> n=m[:2] >>> n 0 1 1 2 dtype: int64 >>> n.x 42 >>> o=n+1 >>> o 0 2 1 3 dtype: int64 >>> o.x Traceback (most recent call last): ... AttributeError: 'MySeries' object has no attribute 'x' >>> m = MySeries([True, False, True], name='test2') >>> m.x = 42 >>> n=m[:2] >>> n 0 True 1 False dtype: bool >>> n.x 42 >>> o=n ^ True >>> o 0 False 1 True dtype: bool >>> o.x 42 >>> p = n ^ o >>> p 0 True 1 True dtype: bool >>> p.x 42 """ import pandas as pd class MySeries(pd.Series): _metadata = ['x'] @property def _constructor(self): return MySeries if __name__ == "__main__": import doctest doctest.testmod() ``` #### Expected Output In all cases, the metadata 'x' should be transferred from the passed values when applying binary operators. When the right-hand value is a constant, the left-hand value metadata should be used in **finalize** for arithmetic operators, just like it is for Boolean binary operators. When two series are used in binary operators, some resolution should be possible in **finalize**. I would pass the second (right-hand) value by calling **finalize**(self, other=other), leaving the resolution to the derived class implementer, but there might be a smarter approach. #### output of `pd.show_versions()` pd.show_versions() ## INSTALLED VERSIONS commit: None python: 2.7.6.final.0 python-bits: 64 OS: Linux OS-release: 3.19.0-59-generic machine: x86_64 processor: x86_64 byteorder: little LC_ALL: None LANG: en_US.UTF-8 pandas: 0.18.1 nose: 1.3.7 pip: None setuptools: 20.2.2 Cython: 0.24 numpy: 1.11.0 scipy: 0.17.0 statsmodels: 0.6.1 xarray: None IPython: 4.0.1 sphinx: 1.3.1 patsy: 0.4.0 dateutil: 2.4.2 pytz: 2015.7 blosc: None bottleneck: 1.0.0 tables: 3.2.2 numexpr: 2.5.2 matplotlib: 1.5.0 openpyxl: 2.2.6 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: 0.7.7 lxml: 3.4.4 bs4: 4.4.1 html5lib: 0.9999999 httplib2: None apiclient: None sqlalchemy: 1.0.9 pymysql: None psycopg2: None jinja2: 2.8 boto: 2.38.0 pandas_datareader: None
{ "+1": 1, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13208/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13208/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13209
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13209/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13209/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13209/events
https://github.com/pandas-dev/pandas/pull/13209
155,367,899
MDExOlB1bGxSZXF1ZXN0NzA0MzQ3MzI=
13,209
BUG: Fix #13149 and ENH: 'copy' param in Index.astype()
{ "avatar_url": "https://avatars.githubusercontent.com/u/9507544?v=4", "events_url": "https://api.github.com/users/pijucha/events{/privacy}", "followers_url": "https://api.github.com/users/pijucha/followers", "following_url": "https://api.github.com/users/pijucha/following{/other_user}", "gists_url": "https://api.github.com/users/pijucha/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pijucha", "id": 9507544, "login": "pijucha", "node_id": "MDQ6VXNlcjk1MDc1NDQ=", "organizations_url": "https://api.github.com/users/pijucha/orgs", "received_events_url": "https://api.github.com/users/pijucha/received_events", "repos_url": "https://api.github.com/users/pijucha/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pijucha/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pijucha/subscriptions", "type": "User", "url": "https://api.github.com/users/pijucha" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
12
2016-05-17T21:36:03Z
2016-05-24T00:32:35Z
2016-05-23T20:45:45Z
CONTRIBUTOR
null
- [x] closes #13149 - [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` - [x] whatsnew entry **Update** 1. Float64Index.astype(int) raises ValueError if a NaN is present. Previously, it converted NaN's to the smallest negative integer. 2. TimedeltaIndex.astype(int) and DatetimeIndex.astype(int) return. Int64Index, which is consistent with behavior of other Indexes. Previously, they returned a numpy.array of ints. 3. Added: - bool parameter 'copy' to Index.astype() - shared doc string to .astype() - tests on .astype() (consolidated and added new) - bool parameter 'copy' to Categorical.astype() 4. Fixed core.common.is_timedelta64_ns_dtype(). 5. Set a default NaT representation to a string type in a parameter of DatetimeIndex._format_native_types(). Previously, it produced a unicode u'NaT' in Python2.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13209/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13209/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13209.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13209", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13209.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13209" }
https://api.github.com/repos/pandas-dev/pandas/issues/13210
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13210/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13210/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13210/events
https://github.com/pandas-dev/pandas/issues/13210
155,371,744
MDU6SXNzdWUxNTUzNzE3NDQ=
13,210
Pandas .read_sql_table() not reading a table which SQLalchemy can find
{ "avatar_url": "https://avatars.githubusercontent.com/u/9990778?v=4", "events_url": "https://api.github.com/users/alexpetralia/events{/privacy}", "followers_url": "https://api.github.com/users/alexpetralia/followers", "following_url": "https://api.github.com/users/alexpetralia/following{/other_user}", "gists_url": "https://api.github.com/users/alexpetralia/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/alexpetralia", "id": 9990778, "login": "alexpetralia", "node_id": "MDQ6VXNlcjk5OTA3Nzg=", "organizations_url": "https://api.github.com/users/alexpetralia/orgs", "received_events_url": "https://api.github.com/users/alexpetralia/received_events", "repos_url": "https://api.github.com/users/alexpetralia/repos", "site_admin": false, "starred_url": "https://api.github.com/users/alexpetralia/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/alexpetralia/subscriptions", "type": "User", "url": "https://api.github.com/users/alexpetralia" }
[ { "color": "5319e7", "default": false, "description": "to_sql, read_sql, read_sql_query", "id": 47232590, "name": "IO SQL", "node_id": "MDU6TGFiZWw0NzIzMjU5MA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20SQL" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 2361, "created_at": "2015-02-26T19:29:05Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1020496?v=4", "events_url": "https://api.github.com/users/jorisvandenbossche/events{/privacy}", "followers_url": "https://api.github.com/users/jorisvandenbossche/followers", "following_url": "https://api.github.com/users/jorisvandenbossche/following{/other_user}", "gists_url": "https://api.github.com/users/jorisvandenbossche/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jorisvandenbossche", "id": 1020496, "login": "jorisvandenbossche", "node_id": "MDQ6VXNlcjEwMjA0OTY=", "organizations_url": "https://api.github.com/users/jorisvandenbossche/orgs", "received_events_url": "https://api.github.com/users/jorisvandenbossche/received_events", "repos_url": "https://api.github.com/users/jorisvandenbossche/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jorisvandenbossche/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jorisvandenbossche/subscriptions", "type": "User", "url": "https://api.github.com/users/jorisvandenbossche" }, "description": "A milestone for closed or open issues for which there is no action needed (eg not a bug, just a question / discussion, nothing to resolve, wontfix, etc).\r\n\r\n", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/33", "id": 997544, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33/labels", "node_id": "MDk6TWlsZXN0b25lOTk3NTQ0", "number": 33, "open_issues": 11, "state": "open", "title": "No action", "updated_at": "2021-11-19T17:33:16Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33" }
12
2016-05-17T21:55:33Z
2017-09-19T13:46:29Z
2016-05-18T09:36:39Z
NONE
null
I am running the following code (**pandas 0.18.0, sqlalchemy 1.0.12**): `skus = pd.read_sql_table('ads_skus', SQLALCHEMY_CONN, schema='a')` I receive the error: `ValueError: Table ads_skus not found` However, if I run: ``` i = inspect(SQLALCHEMY_CONN) for table_name in i.get_table_names(schema='a'): print(table_name) ``` where `SQLALCHEMY` is an `Engine` object. I see `ads_skus` in the list that is output. This looks like a bug if pandas is using the SQLAlchemy engine. _Note: I used the same function for a bunch of similar tables (which are also in the schema `'a'`). They all worked - it only fails on this table._ _Note 2: I noticed that "ads_skus" is the only table which has foreign keys to another schema. That seems to be the differentiating factor._
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13210/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13210/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13211
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13211/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13211/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13211/events
https://github.com/pandas-dev/pandas/issues/13211
155,403,436
MDU6SXNzdWUxNTU0MDM0MzY=
13,211
ValueError: invalid literal for float(): 25:13:15
{ "avatar_url": "https://avatars.githubusercontent.com/u/507492?v=4", "events_url": "https://api.github.com/users/kennetham/events{/privacy}", "followers_url": "https://api.github.com/users/kennetham/followers", "following_url": "https://api.github.com/users/kennetham/following{/other_user}", "gists_url": "https://api.github.com/users/kennetham/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennetham", "id": 507492, "login": "kennetham", "node_id": "MDQ6VXNlcjUwNzQ5Mg==", "organizations_url": "https://api.github.com/users/kennetham/orgs", "received_events_url": "https://api.github.com/users/kennetham/received_events", "repos_url": "https://api.github.com/users/kennetham/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennetham/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennetham/subscriptions", "type": "User", "url": "https://api.github.com/users/kennetham" }
[ { "color": "AFEEEE", "default": false, "description": null, "id": 211840, "name": "Timeseries", "node_id": "MDU6TGFiZWwyMTE4NDA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Timeseries" }, { "color": "0052cc", "default": false, "description": null, "id": 34444536, "name": "Usage Question", "node_id": "MDU6TGFiZWwzNDQ0NDUzNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Usage%20Question" } ]
closed
false
null
[]
null
9
2016-05-18T02:24:34Z
2016-05-19T00:39:03Z
2016-05-18T12:38:20Z
NONE
null
Hi, I am running my own dataset with scikit-learn. My dataset contains '2016/02/28', '20:12:22', '100' and 'string', Date, time, integer and string. I have successfully parsed the data with Pandas and have reached CLF using SVM to test out. However, upon clf.fit(X, y), an error was returned ValueError: invalid literal for float(): 25:13:15, apparently in my dataset, there is a time of 25:13:15 which reflect 02:13:15am. Am I able to convert datetime into float or numeric array? Please advise how should I go about fixing this issue. Thank you.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13211/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13211/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13212
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13212/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13212/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13212/events
https://github.com/pandas-dev/pandas/issues/13212
155,418,031
MDU6SXNzdWUxNTU0MTgwMzE=
13,212
Empty DataFrame with PeriodIndex doesn't maintain index type on resample
{ "avatar_url": "https://avatars.githubusercontent.com/u/5635139?v=4", "events_url": "https://api.github.com/users/max-sixty/events{/privacy}", "followers_url": "https://api.github.com/users/max-sixty/followers", "following_url": "https://api.github.com/users/max-sixty/following{/other_user}", "gists_url": "https://api.github.com/users/max-sixty/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/max-sixty", "id": 5635139, "login": "max-sixty", "node_id": "MDQ6VXNlcjU2MzUxMzk=", "organizations_url": "https://api.github.com/users/max-sixty/orgs", "received_events_url": "https://api.github.com/users/max-sixty/received_events", "repos_url": "https://api.github.com/users/max-sixty/repos", "site_admin": false, "starred_url": "https://api.github.com/users/max-sixty/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/max-sixty/subscriptions", "type": "User", "url": "https://api.github.com/users/max-sixty" }
[ { "color": "eb6420", "default": false, "description": "Period data type", "id": 60635328, "name": "Period", "node_id": "MDU6TGFiZWw2MDYzNTMyOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Period" }, { "color": "207de5", "default": false, "description": "resample method", "id": 74975453, "name": "Resample", "node_id": "MDU6TGFiZWw3NDk3NTQ1Mw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Resample" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
0
2016-05-18T05:13:41Z
2016-05-21T14:12:53Z
2016-05-21T14:12:53Z
CONTRIBUTOR
null
ref: https://github.com/pydata/pandas/pull/13079#discussion_r63645752 ``` python In [5]: pd.DataFrame(index=pd.PeriodIndex([],freq='D')).resample('M').mean().index Out[5]: Index([], dtype='object') ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13212/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13212/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13213
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13213/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13213/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13213/events
https://github.com/pandas-dev/pandas/issues/13213
155,491,787
MDU6SXNzdWUxNTU0OTE3ODc=
13,213
json_normalize() can't deal with non-ascii characters in unicode keys
{ "avatar_url": "https://avatars.githubusercontent.com/u/45175?v=4", "events_url": "https://api.github.com/users/fmarczin/events{/privacy}", "followers_url": "https://api.github.com/users/fmarczin/followers", "following_url": "https://api.github.com/users/fmarczin/following{/other_user}", "gists_url": "https://api.github.com/users/fmarczin/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/fmarczin", "id": 45175, "login": "fmarczin", "node_id": "MDQ6VXNlcjQ1MTc1", "organizations_url": "https://api.github.com/users/fmarczin/orgs", "received_events_url": "https://api.github.com/users/fmarczin/received_events", "repos_url": "https://api.github.com/users/fmarczin/repos", "site_admin": false, "starred_url": "https://api.github.com/users/fmarczin/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/fmarczin/subscriptions", "type": "User", "url": "https://api.github.com/users/fmarczin" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "444444", "default": false, "description": "Unicode strings", "id": 36380025, "name": "Unicode", "node_id": "MDU6TGFiZWwzNjM4MDAyNQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Unicode" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
0
2016-05-18T12:43:27Z
2016-05-19T13:14:51Z
2016-05-19T13:14:46Z
CONTRIBUTOR
null
Example code: ``` python import pandas import json testjson = u''' [{"Ünicøde":0,"sub":{"A":1, "B":2}}, {"Ünicøde":1,"sub":{"A":3, "B":4}}] '''.encode('utf8') pd.io.json.json_normalize(json.loads(testjson)) ``` Output: ``` Traceback (most recent call last): File "...lib/python2.7/site-packages/IPython/core/interactiveshell.py", line 2885, in run_code exec(code_obj, self.user_global_ns, self.user_ns) File "<ipython-input-12-f866f9c7ec7c>", line 5, in <module> pd.io.json.json_normalize(json.loads(testjson)) File ".../lib/python2.7/site-packages/pandas/io/json.py", line 715, in json_normalize data = nested_to_record(data) File ".../lib/python2.7/site-packages/pandas/io/json.py", line 617, in nested_to_record newkey = str(k) UnicodeEncodeError: 'ascii' codec can't encode character u'\xdc' in position 0: ordinal not in range(128) ``` Expected output ``` sub.A sub.B Ünicøde 0 1 2 0 1 3 4 1 ``` The cause are probably https://github.com/pydata/pandas/blob/master/pandas/io/json.py#L618 and https://github.com/pydata/pandas/blob/master/pandas/io/json.py#L620 Those lines seemingly were introduced to deal with numeric types, but fail when `k` is a Unicode object containing non-ascii characters. It seems to be the same bug in principle as https://github.com/pydata/pandas/issues/13101
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13213/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13213/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13214
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13214/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13214/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13214/events
https://github.com/pandas-dev/pandas/pull/13214
155,493,580
MDExOlB1bGxSZXF1ZXN0NzA1MjIwMzY=
13,214
BUG: Fix #13213 json_normalize() and non-ascii characters in keys
{ "avatar_url": "https://avatars.githubusercontent.com/u/45175?v=4", "events_url": "https://api.github.com/users/fmarczin/events{/privacy}", "followers_url": "https://api.github.com/users/fmarczin/followers", "following_url": "https://api.github.com/users/fmarczin/following{/other_user}", "gists_url": "https://api.github.com/users/fmarczin/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/fmarczin", "id": 45175, "login": "fmarczin", "node_id": "MDQ6VXNlcjQ1MTc1", "organizations_url": "https://api.github.com/users/fmarczin/orgs", "received_events_url": "https://api.github.com/users/fmarczin/received_events", "repos_url": "https://api.github.com/users/fmarczin/repos", "site_admin": false, "starred_url": "https://api.github.com/users/fmarczin/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/fmarczin/subscriptions", "type": "User", "url": "https://api.github.com/users/fmarczin" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "444444", "default": false, "description": "Unicode strings", "id": 36380025, "name": "Unicode", "node_id": "MDU6TGFiZWwzNjM4MDAyNQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Unicode" }, { "color": "207de5", "default": false, "description": "read_json, to_json, json_normalize", "id": 49379259, "name": "IO JSON", "node_id": "MDU6TGFiZWw0OTM3OTI1OQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20JSON" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
5
2016-05-18T12:52:14Z
2016-05-19T13:35:41Z
2016-05-19T13:14:46Z
CONTRIBUTOR
null
- [ ] closes #13213 - [ ] tests added / passed - [ ] passes `git diff upstream/master | flake8 --diff` - [ ] whatsnew entry
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13214/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13214/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13214.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13214", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13214.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13214" }
https://api.github.com/repos/pandas-dev/pandas/issues/13215
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13215/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13215/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13215/events
https://github.com/pandas-dev/pandas/pull/13215
155,493,879
MDExOlB1bGxSZXF1ZXN0NzA1MjIyNTI=
13,215
Bug Fix for #13207. Added empty attribute for Index
{ "avatar_url": "https://avatars.githubusercontent.com/u/10297394?v=4", "events_url": "https://api.github.com/users/pfrcks/events{/privacy}", "followers_url": "https://api.github.com/users/pfrcks/followers", "following_url": "https://api.github.com/users/pfrcks/following{/other_user}", "gists_url": "https://api.github.com/users/pfrcks/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pfrcks", "id": 10297394, "login": "pfrcks", "node_id": "MDQ6VXNlcjEwMjk3Mzk0", "organizations_url": "https://api.github.com/users/pfrcks/orgs", "received_events_url": "https://api.github.com/users/pfrcks/received_events", "repos_url": "https://api.github.com/users/pfrcks/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pfrcks/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pfrcks/subscriptions", "type": "User", "url": "https://api.github.com/users/pfrcks" }
[ { "color": "0b02e1", "default": false, "description": "Related to indexing on series/frames, not to indexes themselves", "id": 2822098, "name": "Indexing", "node_id": "MDU6TGFiZWwyODIyMDk4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Indexing" }, { "color": "AD7FA8", "default": false, "description": null, "id": 35818298, "name": "API Design", "node_id": "MDU6TGFiZWwzNTgxODI5OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/API%20Design" } ]
closed
false
null
[]
null
3
2016-05-18T12:53:45Z
2016-05-18T13:28:23Z
2016-05-18T13:28:23Z
CONTRIBUTOR
null
- [x] closes #13207 - [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` - [x] whatsnew entry
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13215/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13215/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13215.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13215", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13215.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13215" }
https://api.github.com/repos/pandas-dev/pandas/issues/13216
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13216/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13216/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13216/events
https://github.com/pandas-dev/pandas/pull/13216
155,504,005
MDExOlB1bGxSZXF1ZXN0NzA1Mjk0Mjg=
13,216
BUG: DataFrame.align bug with join keyword (GH13914)
{ "avatar_url": "https://avatars.githubusercontent.com/u/10297394?v=4", "events_url": "https://api.github.com/users/pfrcks/events{/privacy}", "followers_url": "https://api.github.com/users/pfrcks/followers", "following_url": "https://api.github.com/users/pfrcks/following{/other_user}", "gists_url": "https://api.github.com/users/pfrcks/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pfrcks", "id": 10297394, "login": "pfrcks", "node_id": "MDQ6VXNlcjEwMjk3Mzk0", "organizations_url": "https://api.github.com/users/pfrcks/orgs", "received_events_url": "https://api.github.com/users/pfrcks/received_events", "repos_url": "https://api.github.com/users/pfrcks/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pfrcks/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pfrcks/subscriptions", "type": "User", "url": "https://api.github.com/users/pfrcks" }
[ { "color": "0b02e1", "default": false, "description": "Related to indexing on series/frames, not to indexes themselves", "id": 2822098, "name": "Indexing", "node_id": "MDU6TGFiZWwyODIyMDk4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Indexing" }, { "color": "AD7FA8", "default": false, "description": null, "id": 35818298, "name": "API Design", "node_id": "MDU6TGFiZWwzNTgxODI5OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/API%20Design" } ]
closed
false
null
[]
null
24
2016-05-18T13:40:42Z
2017-02-01T20:48:01Z
2017-02-01T20:48:01Z
CONTRIBUTOR
null
- [x] closes #13194 - [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` - [x] whatsnew entry
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13216/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13216/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13216.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13216", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13216.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13216" }
https://api.github.com/repos/pandas-dev/pandas/issues/13217
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13217/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13217/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13217/events
https://github.com/pandas-dev/pandas/issues/13217
155,530,966
MDU6SXNzdWUxNTU1MzA5NjY=
13,217
BUG: groupby, as_index=False still returning group variable as index
{ "avatar_url": "https://avatars.githubusercontent.com/u/9683693?v=4", "events_url": "https://api.github.com/users/nickeubank/events{/privacy}", "followers_url": "https://api.github.com/users/nickeubank/followers", "following_url": "https://api.github.com/users/nickeubank/following{/other_user}", "gists_url": "https://api.github.com/users/nickeubank/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nickeubank", "id": 9683693, "login": "nickeubank", "node_id": "MDQ6VXNlcjk2ODM2OTM=", "organizations_url": "https://api.github.com/users/nickeubank/orgs", "received_events_url": "https://api.github.com/users/nickeubank/received_events", "repos_url": "https://api.github.com/users/nickeubank/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nickeubank/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nickeubank/subscriptions", "type": "User", "url": "https://api.github.com/users/nickeubank" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "729FCF", "default": false, "description": null, "id": 233160, "name": "Groupby", "node_id": "MDU6TGFiZWwyMzMxNjA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Groupby" }, { "color": "0e8a16", "default": true, "description": null, "id": 717120670, "name": "good first issue", "node_id": "MDU6TGFiZWw3MTcxMjA2NzA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/good%20first%20issue" }, { "color": "cdea3c", "default": false, "description": "Unit test(s) needed to prevent regressions", "id": 986278782, "name": "Needs Tests", "node_id": "MDU6TGFiZWw5ODYyNzg3ODI=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Needs%20Tests" } ]
closed
false
null
[]
{ "closed_at": "2021-07-02T07:59:17Z", "closed_issues": 2396, "created_at": "2020-11-11T19:05:43Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "on-merge: backport to 1.3.x", "due_on": "2021-06-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/80", "id": 6095818, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/80/labels", "node_id": "MDk6TWlsZXN0b25lNjA5NTgxOA==", "number": 80, "open_issues": 1, "state": "closed", "title": "1.3", "updated_at": "2021-08-25T20:34:06Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/80" }
9
2016-05-18T15:25:39Z
2021-05-12T13:27:56Z
2021-05-12T13:27:56Z
CONTRIBUTOR
null
#### Code Sample, a copy-pastable example if possible ``` a = pd.DataFrame({'a':[1,1,2,2], 'b':[1,1,2,2], 'c':[1,1,1,1]}) a.groupby(['a','b'], as_index=False).apply(lambda x: 1) Out[4]: a b 1 1 1 2 2 1 dtype: int64 ``` #### Expected Output ``` Out[4]: 0 1 1 1 dtype: int64 ``` (this is what you get with a unique `by` column -- ``` a.groupby(['a'], as_index=False).apply(lambda x: 1) Out[8]: 0 1 1 1 dtype: int64 ``` #### output of `pd.show_versions()` pd.show_versions() ## INSTALLED VERSIONS commit: None python: 3.5.1.final.0 python-bits: 64 OS: Darwin OS-release: 15.4.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: None LANG: en_US.UTF-8 pandas: 0.18.1 nose: 1.3.7 pip: 8.1.1 setuptools: 20.3 Cython: 0.23.4 numpy: 1.11.0 scipy: 0.17.0 statsmodels: None xarray: None IPython: 4.1.2 sphinx: 1.3.5 patsy: 0.4.0 dateutil: 2.5.1 pytz: 2016.2 blosc: None bottleneck: 1.0.0 tables: 3.2.2 numexpr: 2.5.1 matplotlib: 1.5.1 openpyxl: 2.3.2 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: 0.8.4 lxml: 3.6.0 bs4: 4.4.1 html5lib: None httplib2: None apiclient: None sqlalchemy: 1.0.12 pymysql: None psycopg2: None jinja2: 2.8 boto: 2.39.0 pandas_datareader: None
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13217/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13217/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13218
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13218/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13218/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13218/events
https://github.com/pandas-dev/pandas/issues/13218
155,542,027
MDU6SXNzdWUxNTU1NDIwMjc=
13,218
loffset doesn't work in resample if used with agg()
{ "avatar_url": "https://avatars.githubusercontent.com/u/10881376?v=4", "events_url": "https://api.github.com/users/marcomayer/events{/privacy}", "followers_url": "https://api.github.com/users/marcomayer/followers", "following_url": "https://api.github.com/users/marcomayer/following{/other_user}", "gists_url": "https://api.github.com/users/marcomayer/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/marcomayer", "id": 10881376, "login": "marcomayer", "node_id": "MDQ6VXNlcjEwODgxMzc2", "organizations_url": "https://api.github.com/users/marcomayer/orgs", "received_events_url": "https://api.github.com/users/marcomayer/received_events", "repos_url": "https://api.github.com/users/marcomayer/repos", "site_admin": false, "starred_url": "https://api.github.com/users/marcomayer/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/marcomayer/subscriptions", "type": "User", "url": "https://api.github.com/users/marcomayer" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "207de5", "default": false, "description": "resample method", "id": 74975453, "name": "Resample", "node_id": "MDU6TGFiZWw3NDk3NTQ1Mw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Resample" } ]
closed
false
null
[]
{ "closed_at": "2017-05-06T10:20:19Z", "closed_issues": 987, "created_at": "2016-02-08T15:30:21Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "after 0.19.x series", "due_on": "2017-05-12T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/39", "id": 1570595, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/39/labels", "node_id": "MDk6TWlsZXN0b25lMTU3MDU5NQ==", "number": 39, "open_issues": 0, "state": "closed", "title": "0.20.0", "updated_at": "2018-10-28T08:18:42Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/39" }
5
2016-05-18T16:10:15Z
2016-12-31T16:56:53Z
2016-12-31T16:56:53Z
NONE
null
#### Code Sample, a copy-pastable example if possible ``` # Create DF df = pd.DataFrame(np.random.rand(5,2), columns=list('AB'), index=pd.date_range('2010-01-01 09:00:00', periods=5, freq='s')) print(df) A B 2010-01-01 09:00:00 0.283113 0.559642 2010-01-01 09:00:01 0.754942 0.621557 2010-01-01 09:00:02 0.102002 0.892100 2010-01-01 09:00:03 0.885400 0.524359 2010-01-01 09:00:04 0.324761 0.706758 #Resample, loffset works fine using mean(), is offset by 2 hours. print(df.resample('2s', loffset='2h').mean()) A B 2010-01-01 11:00:00 0.519028 0.590599 2010-01-01 11:00:02 0.493701 0.708229 2010-01-01 11:00:04 0.324761 0.706758 # Resample with agg(), loffset doesn't work anymore. print(df.resample('2s', loffset='2h').agg(dict(A='sum', B='mean'))) A B 2010-01-01 09:00:00 1.038055 0.590599 2010-01-01 09:00:02 0.987402 0.708229 2010-01-01 09:00:04 0.324761 0.706758 ``` #### Expected Output I'd expect the same as with mean(), this is how resample worked in the past with resample(how=...). But maybe I also misunderstood something about the change. If so please enlighten me. Since I need this to keep things going, I use the following workaround for now, please let me know if this is the way to go or if there's a more efficient way: ``` print(df.resample('2s', loffset='2h').agg(dict(A='sum', B='mean')).tshift(2, 'h')) ``` #### output of `pd.show_versions()` ## INSTALLED VERSIONS commit: None python: 3.5.1.final.0 python-bits: 64 OS: Darwin OS-release: 15.5.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: None LANG: de_DE.UTF-8 pandas: 0.18.1 nose: 1.3.7 pip: 8.1.2 setuptools: 20.3 Cython: 0.23.4 numpy: 1.10.4 scipy: 0.17.1 statsmodels: 0.6.1 xarray: None IPython: 4.2.0 sphinx: 1.3.5 patsy: 0.4.0 dateutil: 2.5.1 pytz: 2016.2 blosc: None bottleneck: 1.0.0 tables: 3.2.2 numexpr: 2.5.2 matplotlib: 1.5.1 openpyxl: 2.3.2 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: 0.8.4 lxml: 3.6.0 bs4: 4.4.1 html5lib: None httplib2: None apiclient: None sqlalchemy: 1.0.12 pymysql: None psycopg2: None jinja2: 2.8 boto: 2.39.0 pandas_datareader: 0.2.1 In [92]:
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13218/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13218/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13219
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13219/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13219/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13219/events
https://github.com/pandas-dev/pandas/issues/13219
155,547,716
MDU6SXNzdWUxNTU1NDc3MTY=
13,219
Unicode not acceptable input for `usecols` kwarg in `read_csv()`
{ "avatar_url": "https://avatars.githubusercontent.com/u/9703332?v=4", "events_url": "https://api.github.com/users/PeterKucirek/events{/privacy}", "followers_url": "https://api.github.com/users/PeterKucirek/followers", "following_url": "https://api.github.com/users/PeterKucirek/following{/other_user}", "gists_url": "https://api.github.com/users/PeterKucirek/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/PeterKucirek", "id": 9703332, "login": "PeterKucirek", "node_id": "MDQ6VXNlcjk3MDMzMzI=", "organizations_url": "https://api.github.com/users/PeterKucirek/orgs", "received_events_url": "https://api.github.com/users/PeterKucirek/received_events", "repos_url": "https://api.github.com/users/PeterKucirek/repos", "site_admin": false, "starred_url": "https://api.github.com/users/PeterKucirek/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/PeterKucirek/subscriptions", "type": "User", "url": "https://api.github.com/users/PeterKucirek" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "444444", "default": false, "description": "Unicode strings", "id": 36380025, "name": "Unicode", "node_id": "MDU6TGFiZWwzNjM4MDAyNQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Unicode" }, { "color": "5319e7", "default": false, "description": "read_csv, to_csv", "id": 47229171, "name": "IO CSV", "node_id": "MDU6TGFiZWw0NzIyOTE3MQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20CSV" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
4
2016-05-18T16:35:22Z
2016-10-14T17:29:00Z
2016-06-01T11:13:41Z
NONE
null
I caught this bug while updating from version 0.18.0 to 0.18.1. The kwarg `usecols` no longer accepts unicode column labels. Example below: ``` python from io import StringIO import pandas as pd s = u'''AAA,BBB,CCC,DDD 0.056674973,8,True,a 2.613230982,2,False,b 3.568935038,7,False,a ''' buff = StringIO(s) print pd.read_csv(buff, usecols=[u'AAA', u'BBB']) >> ValueError: The elements of 'usecols' must either be all strings or all integers ``` I note that 0.18.1 introduced the requirement that `usecols` be all string or all ints. This makes sense but it looks like the implementation also throws away unicode strings.
{ "+1": 1, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13219/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13219/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13220
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13220/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13220/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13220/events
https://github.com/pandas-dev/pandas/issues/13220
155,557,323
MDU6SXNzdWUxNTU1NTczMjM=
13,220
BUG: .transform('size') should be the same as .transform(len)
{ "avatar_url": "https://avatars.githubusercontent.com/u/18246162?v=4", "events_url": "https://api.github.com/users/jhmuller/events{/privacy}", "followers_url": "https://api.github.com/users/jhmuller/followers", "following_url": "https://api.github.com/users/jhmuller/following{/other_user}", "gists_url": "https://api.github.com/users/jhmuller/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jhmuller", "id": 18246162, "login": "jhmuller", "node_id": "MDQ6VXNlcjE4MjQ2MTYy", "organizations_url": "https://api.github.com/users/jhmuller/orgs", "received_events_url": "https://api.github.com/users/jhmuller/received_events", "repos_url": "https://api.github.com/users/jhmuller/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jhmuller/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jhmuller/subscriptions", "type": "User", "url": "https://api.github.com/users/jhmuller" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "C4A000", "default": false, "description": "pandas testing functions or related to the test suite", "id": 127685, "name": "Testing", "node_id": "MDU6TGFiZWwxMjc2ODU=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Testing" }, { "color": "729FCF", "default": false, "description": null, "id": 233160, "name": "Groupby", "node_id": "MDU6TGFiZWwyMzMxNjA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Groupby" }, { "color": "d7e102", "default": false, "description": "np.nan, pd.NaT, pd.NA, dropna, isnull, interpolate", "id": 2822342, "name": "Missing-data", "node_id": "MDU6TGFiZWwyODIyMzQy", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Missing-data" }, { "color": "AD7FA8", "default": false, "description": null, "id": 35818298, "name": "API Design", "node_id": "MDU6TGFiZWwzNTgxODI5OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/API%20Design" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 786, "created_at": "2015-01-13T10:53:19Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "Changes that would be nice to have in the next release. These issues are not blocking. They will be pushed to the next release if no one has time to fix them.", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/32", "id": 933188, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32/labels", "node_id": "MDk6TWlsZXN0b25lOTMzMTg4", "number": 32, "open_issues": 1053, "state": "open", "title": "Contributions Welcome", "updated_at": "2021-11-21T00:50:06Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32" }
12
2016-05-18T17:22:25Z
2019-10-18T01:07:39Z
2019-10-18T01:07:38Z
NONE
null
``` import pandas as pd N = 6 df = pd.DataFrame(data={"size":[0.1]*N, "group":[None]*N}, index=range(N)) gb = df.groupby(by=['group']) d2 = gb.transform('sum') print d2 ``` #### Expected Output ``` # not actually sure what should be returned, perhaps just the original values Here is what I got size 0 2.605041e-316 1 6.899144e-310 2 2.584561e+161 3 1.485397e-313 4 1.916117e+214 5 3.075369e+203 #### output of ``pd.show_versions()`` INSTALLED VERSIONS ------------------ commit: None python: 2.7.11.final.0 python-bits: 64 OS: Linux OS-release: 3.2.0-54-generic machine: x86_64 processor: x86_64 byteorder: little LC_ALL: None LANG: None pandas: 0.18.1 nose: 1.3.7 pip: 8.1.0 setuptools: 20.7.0 Cython: 0.24 numpy: 1.11.0 scipy: 0.17.0 statsmodels: 0.6.1 xarray: 0.7.2 IPython: 4.2.0 sphinx: 1.3.6 patsy: 0.4.1 dateutil: 2.2 pytz: 2016.4 blosc: None bottleneck: 1.0.0 tables: 3.2.2 numexpr: 2.5.2 matplotlib: 1.5.1 openpyxl: 2.2.0-b1 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: 0.8.5 lxml: 3.6.0 bs4: 4.4.1 html5lib: 0.999 httplib2: None apiclient: None sqlalchemy: 1.0.12 pymysql: None psycopg2: None jinja2: 2.8 boto: 2.39.0 pandas_datareader: None ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13220/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13220/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13221
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13221/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13221/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13221/events
https://github.com/pandas-dev/pandas/issues/13221
155,557,716
MDU6SXNzdWUxNTU1NTc3MTY=
13,221
COMPAT: concat of PeriodIndex
{ "avatar_url": "https://avatars.githubusercontent.com/u/5635139?v=4", "events_url": "https://api.github.com/users/max-sixty/events{/privacy}", "followers_url": "https://api.github.com/users/max-sixty/followers", "following_url": "https://api.github.com/users/max-sixty/following{/other_user}", "gists_url": "https://api.github.com/users/max-sixty/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/max-sixty", "id": 5635139, "login": "max-sixty", "node_id": "MDQ6VXNlcjU2MzUxMzk=", "organizations_url": "https://api.github.com/users/max-sixty/orgs", "received_events_url": "https://api.github.com/users/max-sixty/received_events", "repos_url": "https://api.github.com/users/max-sixty/repos", "site_admin": false, "starred_url": "https://api.github.com/users/max-sixty/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/max-sixty/subscriptions", "type": "User", "url": "https://api.github.com/users/max-sixty" }
[ { "color": "02d7e1", "default": false, "description": "Concat, Merge/Join, Stack/Unstack, Explode", "id": 13098779, "name": "Reshaping", "node_id": "MDU6TGFiZWwxMzA5ODc3OQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Reshaping" }, { "color": "eb6420", "default": false, "description": "Period data type", "id": 60635328, "name": "Period", "node_id": "MDU6TGFiZWw2MDYzNTMyOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Period" }, { "color": "0052cc", "default": false, "description": "pandas objects compatability with Numpy or Python functions", "id": 76865106, "name": "Compat", "node_id": "MDU6TGFiZWw3Njg2NTEwNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Compat" } ]
closed
false
null
[]
{ "closed_at": "2019-01-26T00:51:26Z", "closed_issues": 2048, "created_at": "2018-03-29T12:00:12Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1020496?v=4", "events_url": "https://api.github.com/users/jorisvandenbossche/events{/privacy}", "followers_url": "https://api.github.com/users/jorisvandenbossche/followers", "following_url": "https://api.github.com/users/jorisvandenbossche/following{/other_user}", "gists_url": "https://api.github.com/users/jorisvandenbossche/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jorisvandenbossche", "id": 1020496, "login": "jorisvandenbossche", "node_id": "MDQ6VXNlcjEwMjA0OTY=", "organizations_url": "https://api.github.com/users/jorisvandenbossche/orgs", "received_events_url": "https://api.github.com/users/jorisvandenbossche/received_events", "repos_url": "https://api.github.com/users/jorisvandenbossche/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jorisvandenbossche/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jorisvandenbossche/subscriptions", "type": "User", "url": "https://api.github.com/users/jorisvandenbossche" }, "description": "", "due_on": "2019-01-31T08:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/55", "id": 3228419, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/55/labels", "node_id": "MDk6TWlsZXN0b25lMzIyODQxOQ==", "number": 55, "open_issues": 0, "state": "closed", "title": "0.24.0", "updated_at": "2019-01-29T07:42:40Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/55" }
5
2016-05-18T17:24:41Z
2018-10-26T08:41:52Z
2018-10-25T13:31:37Z
CONTRIBUTOR
null
https://github.com/pydata/pandas/blob/master/pandas/tseries/period.py#L920 `return Index(com._concat_compat(to_concat), name=name)` now should reference `pandas.types.concat._concat_compat` I _think_ this should probably fail - concat-ing a `PeriodIndex` with other index types?
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13221/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13221/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13222
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13222/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13222/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13222/events
https://github.com/pandas-dev/pandas/issues/13222
155,560,934
MDU6SXNzdWUxNTU1NjA5MzQ=
13,222
style apply of rows fails for subset list, but works for single row?
{ "avatar_url": "https://avatars.githubusercontent.com/u/501736?v=4", "events_url": "https://api.github.com/users/paulperry/events{/privacy}", "followers_url": "https://api.github.com/users/paulperry/followers", "following_url": "https://api.github.com/users/paulperry/following{/other_user}", "gists_url": "https://api.github.com/users/paulperry/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/paulperry", "id": 501736, "login": "paulperry", "node_id": "MDQ6VXNlcjUwMTczNg==", "organizations_url": "https://api.github.com/users/paulperry/orgs", "received_events_url": "https://api.github.com/users/paulperry/received_events", "repos_url": "https://api.github.com/users/paulperry/repos", "site_admin": false, "starred_url": "https://api.github.com/users/paulperry/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/paulperry/subscriptions", "type": "User", "url": "https://api.github.com/users/paulperry" }
[ { "color": "3465A4", "default": false, "description": null, "id": 134699, "name": "Docs", "node_id": "MDU6TGFiZWwxMzQ2OTk=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Docs" }, { "color": "8AE234", "default": false, "description": null, "id": 2413328, "name": "Visualization", "node_id": "MDU6TGFiZWwyNDEzMzI4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Visualization" }, { "color": "006b75", "default": false, "description": "read_html, to_html, Styler.apply, Styler.applymap", "id": 57395487, "name": "IO HTML", "node_id": "MDU6TGFiZWw1NzM5NTQ4Nw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20HTML" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
11
2016-05-18T17:42:27Z
2016-06-18T21:26:02Z
2016-06-18T21:26:02Z
NONE
null
#### Code Sample, a copy-pastable example if possible ``` df = pd.DataFrame([["A", 1],["B", 2]], columns=["Letter", "Number"]) def highlight(s): return ['background-color: yellow'] df.style.apply(highlight, axis=0, subset=[0]) --------------------------------------------------------------------------- KeyError Traceback (most recent call last) /Users/paulperry/anaconda/lib/python3.5/site-packages/IPython/core/formatters.py in __call__(self, obj) 341 method = _safe_get_formatter_method(obj, self.print_method) 342 if method is not None: --> 343 return method() 344 return None 345 else: /Users/paulperry/anaconda/lib/python3.5/site-packages/pandas/core/style.py in _repr_html_(self) 163 def _repr_html_(self): 164 """Hooks into Jupyter notebook rich display system.""" --> 165 return self.render() 166 167 def _translate(self): /Users/paulperry/anaconda/lib/python3.5/site-packages/pandas/core/style.py in render(self) 356 the rendered HTML in the notebook. 357 """ --> 358 self._compute() 359 d = self._translate() 360 # filter out empty styles, every cell will have a class /Users/paulperry/anaconda/lib/python3.5/site-packages/pandas/core/style.py in _compute(self) 422 r = self 423 for func, args, kwargs in self._todo: --> 424 r = func(self)(*args, **kwargs) 425 return r 426 /Users/paulperry/anaconda/lib/python3.5/site-packages/pandas/core/style.py in _apply(self, func, axis, subset, **kwargs) 429 subset = _non_reducing_slice(subset) 430 if axis is not None: --> 431 result = self.data.loc[subset].apply(func, axis=axis, **kwargs) 432 else: 433 # like tee /Users/paulperry/anaconda/lib/python3.5/site-packages/pandas/core/indexing.py in __getitem__(self, key) 1282 def __getitem__(self, key): 1283 if type(key) is tuple: -> 1284 return self._getitem_tuple(key) 1285 else: 1286 return self._getitem_axis(key, axis=0) /Users/paulperry/anaconda/lib/python3.5/site-packages/pandas/core/indexing.py in _getitem_tuple(self, tup) 783 784 # no multi-index, so validate all of the indexers --> 785 self._has_valid_tuple(tup) 786 787 # ugly hack for GH #836 /Users/paulperry/anaconda/lib/python3.5/site-packages/pandas/core/indexing.py in _has_valid_tuple(self, key) 136 if i >= self.obj.ndim: 137 raise IndexingError('Too many indexers') --> 138 if not self._has_valid_type(k, i): 139 raise ValueError("Location based indexing can only have [%s] " 140 "types" % self._valid_types) /Users/paulperry/anaconda/lib/python3.5/site-packages/pandas/core/indexing.py in _has_valid_type(self, key, axis) 1365 1366 raise KeyError("None of [%s] are in the [%s]" % -> 1367 (key, self.obj._get_axis_name(axis))) 1368 1369 return True KeyError: 'None of [[0]] are in the [columns]' Out[16]: <pandas.core.style.Styler at 0x11ae32cf8> ``` The code appears to be applying it to the columns, not the rows, but passing a single value as the subset renders the table with the correct row highlighted. ``` df.style.apply(highlight, axis=0, subset=0) Letter Number 0 A 1 <- in html this row is highlighted yellow 1 B 2 ``` Passing a bad row index (e.g. 3) also correctly fails with 'None of [[3]] are in the [index]' `df.style.apply(highlight, axis=1, subset=['Letter'])` works, but `df.style.apply(highlight, axis=1, subset=['Letter','Number'])` Fails #### Expected Output ``` df.style.apply(highlight, axis=0, subset=[0]) Letter Number 0 A 1 <- in html this row should be highlighted yellow 1 B 2 ``` #### output of `pd.show_versions()` ## INSTALLED VERSIONS commit: None python: 3.5.1.final.0 python-bits: 64 OS: Darwin OS-release: 15.4.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: None LANG: en_US.UTF-8 pandas: 0.18.0 nose: 1.3.7 pip: 8.1.2 setuptools: 20.3 Cython: 0.23.4 numpy: 1.10.4 scipy: 0.17.0 statsmodels: 0.6.1 xarray: None IPython: 4.1.2 sphinx: 1.3.5 patsy: 0.4.0 dateutil: 2.5.1 pytz: 2016.2 blosc: None bottleneck: 1.0.0 tables: 3.2.2 numexpr: 2.5 matplotlib: 1.5.1 openpyxl: 2.3.2 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: 0.8.4 lxml: 3.6.0 bs4: 4.4.1 html5lib: None httplib2: None apiclient: None sqlalchemy: 1.0.12 pymysql: None psycopg2: None jinja2: 2.8 boto: 2.39.0
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13222/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13222/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13223
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13223/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13223/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13223/events
https://github.com/pandas-dev/pandas/issues/13223
155,610,891
MDU6SXNzdWUxNTU2MTA4OTE=
13,223
Resampling with NaT in TimedeltaIndex raises MemoryError
{ "avatar_url": "https://avatars.githubusercontent.com/u/8616972?v=4", "events_url": "https://api.github.com/users/evectant/events{/privacy}", "followers_url": "https://api.github.com/users/evectant/followers", "following_url": "https://api.github.com/users/evectant/following{/other_user}", "gists_url": "https://api.github.com/users/evectant/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/evectant", "id": 8616972, "login": "evectant", "node_id": "MDQ6VXNlcjg2MTY5NzI=", "organizations_url": "https://api.github.com/users/evectant/orgs", "received_events_url": "https://api.github.com/users/evectant/received_events", "repos_url": "https://api.github.com/users/evectant/repos", "site_admin": false, "starred_url": "https://api.github.com/users/evectant/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/evectant/subscriptions", "type": "User", "url": "https://api.github.com/users/evectant" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "5319e7", "default": false, "description": "Timedelta data type", "id": 49597148, "name": "Timedelta", "node_id": "MDU6TGFiZWw0OTU5NzE0OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Timedelta" }, { "color": "207de5", "default": false, "description": "resample method", "id": 74975453, "name": "Resample", "node_id": "MDU6TGFiZWw3NDk3NTQ1Mw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Resample" } ]
closed
false
null
[]
{ "closed_at": "2018-10-23T02:32:44Z", "closed_issues": 18, "created_at": "2018-08-02T10:03:24Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "on-merge: backport to 0.23.x\r\n\r\nIf needed", "due_on": "2018-11-30T08:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/60", "id": 3541597, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/60/labels", "node_id": "MDk6TWlsZXN0b25lMzU0MTU5Nw==", "number": 60, "open_issues": 0, "state": "closed", "title": "0.23.5", "updated_at": "2018-10-23T02:32:44Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/60" }
1
2016-05-18T21:56:12Z
2018-08-09T10:33:35Z
2018-08-09T10:33:34Z
CONTRIBUTOR
null
`DatetimeIndex` can handle `NaT`: ``` In [2]: dti = pd.DatetimeIndex(['1970-01-01 00:00:00', pd.NaT, '1970-01-01 00:00:02']) In [3]: pd.DataFrame([2, 3, 5], dti).resample('1s').mean() Out[3]: 0 1970-01-01 00:00:00 2.0 1970-01-01 00:00:01 NaN 1970-01-01 00:00:02 5.0 ``` But `TimedeltaIndex` can't: ``` In [4]: tdi = pd.to_timedelta(['0s', pd.NaT, '2s']) In [5]: pd.DataFrame([2, 3, 5], tdi).resample('1s').mean() ... MemoryError: ``` Versions: ``` python: 2.7.11.final.0 OS: Linux machine: x86_64 pandas: 0.18.1+38.gc7e6f5f.dirty numpy: 1.10.2 ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13223/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13223/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13224
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13224/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13224/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13224/events
https://github.com/pandas-dev/pandas/issues/13224
155,611,254
MDU6SXNzdWUxNTU2MTEyNTQ=
13,224
Resampling with NaT in PeriodIndex raises ValueError
{ "avatar_url": "https://avatars.githubusercontent.com/u/8616972?v=4", "events_url": "https://api.github.com/users/evectant/events{/privacy}", "followers_url": "https://api.github.com/users/evectant/followers", "following_url": "https://api.github.com/users/evectant/following{/other_user}", "gists_url": "https://api.github.com/users/evectant/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/evectant", "id": 8616972, "login": "evectant", "node_id": "MDQ6VXNlcjg2MTY5NzI=", "organizations_url": "https://api.github.com/users/evectant/orgs", "received_events_url": "https://api.github.com/users/evectant/received_events", "repos_url": "https://api.github.com/users/evectant/repos", "site_admin": false, "starred_url": "https://api.github.com/users/evectant/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/evectant/subscriptions", "type": "User", "url": "https://api.github.com/users/evectant" }
[ { "color": "eb6420", "default": false, "description": "Period data type", "id": 60635328, "name": "Period", "node_id": "MDU6TGFiZWw2MDYzNTMyOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Period" }, { "color": "207de5", "default": false, "description": "resample method", "id": 74975453, "name": "Resample", "node_id": "MDU6TGFiZWw3NDk3NTQ1Mw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Resample" } ]
closed
false
null
[]
{ "closed_at": "2017-10-28T18:54:27Z", "closed_issues": 764, "created_at": "2017-03-23T13:26:25Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2017-10-27T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/46", "id": 2406656, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/46/labels", "node_id": "MDk6TWlsZXN0b25lMjQwNjY1Ng==", "number": 46, "open_issues": 0, "state": "closed", "title": "0.21.0", "updated_at": "2018-07-08T21:53:21Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/46" }
1
2016-05-18T21:58:15Z
2017-10-01T14:55:33Z
2017-10-01T14:55:33Z
CONTRIBUTOR
null
`PeriodIndex` can't handle `NaT`: ``` In [2]: pi = pd.PeriodIndex(['1970-01-01 00:00:00', pd.NaT, '1970-01-01 00:00:02'], freq='S') In [3]: pd.DataFrame([2, 3, 5], pi).resample('1s').mean() ... ValueError: Start and end must not be NaT ``` But `DatetimeIndex` obtained from `PeriodIndex` can: ``` In [4]: pd.DataFrame([2, 3, 5], pi.to_datetime()).resample('1s').mean() Out[4]: 0 1970-01-01 00:00:00 2.0 1970-01-01 00:00:01 NaN 1970-01-01 00:00:02 5.0 ``` Shouldn't these behave the same? Versions: ``` python: 2.7.11.final.0 OS: Linux machine: x86_64 pandas: 0.18.1+38.gc7e6f5f.dirty numpy: 1.10.2 ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13224/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13224/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13225
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13225/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13225/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13225/events
https://github.com/pandas-dev/pandas/pull/13225
155,638,167
MDExOlB1bGxSZXF1ZXN0NzA2MjYwMTY=
13,225
DOC/API: Styler documentation changes
{ "avatar_url": "https://avatars.githubusercontent.com/u/1312546?v=4", "events_url": "https://api.github.com/users/TomAugspurger/events{/privacy}", "followers_url": "https://api.github.com/users/TomAugspurger/followers", "following_url": "https://api.github.com/users/TomAugspurger/following{/other_user}", "gists_url": "https://api.github.com/users/TomAugspurger/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/TomAugspurger", "id": 1312546, "login": "TomAugspurger", "node_id": "MDQ6VXNlcjEzMTI1NDY=", "organizations_url": "https://api.github.com/users/TomAugspurger/orgs", "received_events_url": "https://api.github.com/users/TomAugspurger/received_events", "repos_url": "https://api.github.com/users/TomAugspurger/repos", "site_admin": false, "starred_url": "https://api.github.com/users/TomAugspurger/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/TomAugspurger/subscriptions", "type": "User", "url": "https://api.github.com/users/TomAugspurger" }
[ { "color": "3465A4", "default": false, "description": null, "id": 134699, "name": "Docs", "node_id": "MDU6TGFiZWwxMzQ2OTk=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Docs" }, { "color": "ededed", "default": false, "description": "__repr__ of pandas objects, to_string", "id": 13101118, "name": "Output-Formatting", "node_id": "MDU6TGFiZWwxMzEwMTExOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Output-Formatting" }, { "color": "006b75", "default": false, "description": "read_html, to_html, Styler.apply, Styler.applymap", "id": 57395487, "name": "IO HTML", "node_id": "MDU6TGFiZWw1NzM5NTQ4Nw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20HTML" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
12
2016-05-19T01:48:21Z
2017-04-05T02:06:51Z
2016-06-18T21:26:02Z
CONTRIBUTOR
null
Closes https://github.com/pydata/pandas/issues/13222, #13225 - Update docstring and notebook on output shapes matching - Change build process to use nbconvert to execute the notebook and then convert using NBConvert. Second commit puts some more restrictions on the output of a user's function passed to `.apply`.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13225/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13225/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13225.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13225", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13225.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13225" }
https://api.github.com/repos/pandas-dev/pandas/issues/13226
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13226/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13226/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13226/events
https://github.com/pandas-dev/pandas/issues/13226
155,690,513
MDU6SXNzdWUxNTU2OTA1MTM=
13,226
SettingWithCopyWarning while using .loc
{ "avatar_url": "https://avatars.githubusercontent.com/u/10881376?v=4", "events_url": "https://api.github.com/users/marcomayer/events{/privacy}", "followers_url": "https://api.github.com/users/marcomayer/followers", "following_url": "https://api.github.com/users/marcomayer/following{/other_user}", "gists_url": "https://api.github.com/users/marcomayer/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/marcomayer", "id": 10881376, "login": "marcomayer", "node_id": "MDQ6VXNlcjEwODgxMzc2", "organizations_url": "https://api.github.com/users/marcomayer/orgs", "received_events_url": "https://api.github.com/users/marcomayer/received_events", "repos_url": "https://api.github.com/users/marcomayer/repos", "site_admin": false, "starred_url": "https://api.github.com/users/marcomayer/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/marcomayer/subscriptions", "type": "User", "url": "https://api.github.com/users/marcomayer" }
[ { "color": "0b02e1", "default": false, "description": "Related to indexing on series/frames, not to indexes themselves", "id": 2822098, "name": "Indexing", "node_id": "MDU6TGFiZWwyODIyMDk4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Indexing" }, { "color": "AD7FA8", "default": false, "description": null, "id": 35818298, "name": "API Design", "node_id": "MDU6TGFiZWwzNTgxODI5OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/API%20Design" }, { "color": "70e5ca", "default": false, "description": "", "id": 2085877452, "name": "Copy / view semantics", "node_id": "MDU6TGFiZWwyMDg1ODc3NDUy", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Copy%20/%20view%20semantics" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 786, "created_at": "2015-01-13T10:53:19Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "Changes that would be nice to have in the next release. These issues are not blocking. They will be pushed to the next release if no one has time to fix them.", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/32", "id": 933188, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32/labels", "node_id": "MDk6TWlsZXN0b25lOTMzMTg4", "number": 32, "open_issues": 1053, "state": "open", "title": "Contributions Welcome", "updated_at": "2021-11-21T00:50:06Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32" }
6
2016-05-19T09:21:19Z
2021-04-30T05:30:53Z
2021-04-30T05:30:53Z
NONE
null
#### Code Sample, a copy-pastable example if possible ``` df = pd.DataFrame(np.random.randn(6,4), columns=list('ABCD')) # In ipython-notebook, I'm now just looking at the DF by calling it. This seems to create a view of the DF? If df is not called, the warning doesn't show. It will also show when doing x = df for example. df df = df.loc[df['A'] > 0] # Now calling this, SettingWithCopyWarning shows suggesting to use .loc which is what I do? df.loc[:, 'A'] = 1 ``` #### Expected Output What works without a warning is to use df.assign. But what about single row changes a la df.loc[1,'A'] = 1 Looking at the docs, df.loc seems to be the suggested way that should work fine. Maybe I'm just missing something and the mistake is on my side. If so I'd be happy to know. #### output of `pd.show_versions()` ## INSTALLED VERSIONS commit: None python: 3.5.1.final.0 python-bits: 64 OS: Darwin OS-release: 15.5.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: None LANG: de_DE.UTF-8 pandas: 0.18.1 nose: 1.3.7 pip: 8.1.2 setuptools: 20.3 Cython: 0.23.4 numpy: 1.10.4 scipy: 0.17.1 statsmodels: 0.6.1 xarray: None IPython: 4.2.0 sphinx: 1.3.5 patsy: 0.4.0 dateutil: 2.5.1 pytz: 2016.2 blosc: None bottleneck: 1.0.0 tables: 3.2.2 numexpr: 2.5.2 matplotlib: 1.5.1 openpyxl: 2.3.2 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: 0.8.4 lxml: 3.6.0 bs4: 4.4.1 html5lib: None httplib2: None apiclient: None sqlalchemy: 1.0.12 pymysql: None psycopg2: None jinja2: 2.8 boto: 2.39.0 pandas_datareader: 0.2.1
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13226/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13226/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13227
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13227/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13227/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13227/events
https://github.com/pandas-dev/pandas/issues/13227
155,699,572
MDU6SXNzdWUxNTU2OTk1NzI=
13,227
Inconsistent default date ticks for data at different frequencies
{ "avatar_url": "https://avatars.githubusercontent.com/u/5760954?v=4", "events_url": "https://api.github.com/users/marcinbielecki/events{/privacy}", "followers_url": "https://api.github.com/users/marcinbielecki/followers", "following_url": "https://api.github.com/users/marcinbielecki/following{/other_user}", "gists_url": "https://api.github.com/users/marcinbielecki/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/marcinbielecki", "id": 5760954, "login": "marcinbielecki", "node_id": "MDQ6VXNlcjU3NjA5NTQ=", "organizations_url": "https://api.github.com/users/marcinbielecki/orgs", "received_events_url": "https://api.github.com/users/marcinbielecki/received_events", "repos_url": "https://api.github.com/users/marcinbielecki/repos", "site_admin": false, "starred_url": "https://api.github.com/users/marcinbielecki/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/marcinbielecki/subscriptions", "type": "User", "url": "https://api.github.com/users/marcinbielecki" }
[ { "color": "8AE234", "default": false, "description": null, "id": 2413328, "name": "Visualization", "node_id": "MDU6TGFiZWwyNDEzMzI4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Visualization" } ]
closed
false
null
[]
null
3
2016-05-19T10:05:00Z
2021-04-30T05:36:23Z
2021-04-30T05:36:23Z
NONE
null
When the data indexed with datetime are plotted via DataFrame.plot(), the default date ticks behave inconsistently depending on the frequency of the data index. Here's a [short notebook](https://gist.github.com/marcinbielecki/9a8c1e3f7900a4761202769aecf746e0) that reproduces the issue. The data at daily, weekly and annual frequencies are plotted with ticks aligning to "round" years, in this example multiples of 5 (5n). However, data at monthly and quarterly frequencies are plotted with ticks aligning to 5n-1.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13227/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13227/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13228
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13228/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13228/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13228/events
https://github.com/pandas-dev/pandas/issues/13228
155,753,871
MDU6SXNzdWUxNTU3NTM4NzE=
13,228
Using str() in .map() on floats gives string with higher precision than before
{ "avatar_url": "https://avatars.githubusercontent.com/u/10881376?v=4", "events_url": "https://api.github.com/users/marcomayer/events{/privacy}", "followers_url": "https://api.github.com/users/marcomayer/followers", "following_url": "https://api.github.com/users/marcomayer/following{/other_user}", "gists_url": "https://api.github.com/users/marcomayer/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/marcomayer", "id": 10881376, "login": "marcomayer", "node_id": "MDQ6VXNlcjEwODgxMzc2", "organizations_url": "https://api.github.com/users/marcomayer/orgs", "received_events_url": "https://api.github.com/users/marcomayer/received_events", "repos_url": "https://api.github.com/users/marcomayer/repos", "site_admin": false, "starred_url": "https://api.github.com/users/marcomayer/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/marcomayer/subscriptions", "type": "User", "url": "https://api.github.com/users/marcomayer" }
[ { "color": "0e8a16", "default": true, "description": null, "id": 717120670, "name": "good first issue", "node_id": "MDU6TGFiZWw3MTcxMjA2NzA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/good%20first%20issue" }, { "color": "cdea3c", "default": false, "description": "Unit test(s) needed to prevent regressions", "id": 986278782, "name": "Needs Tests", "node_id": "MDU6TGFiZWw5ODYyNzg3ODI=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Needs%20Tests" } ]
closed
false
null
[]
{ "closed_at": "2020-01-30T12:18:05Z", "closed_issues": 2207, "created_at": "2012-09-13T02:13:00Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/329591?v=4", "events_url": "https://api.github.com/users/wesm/events{/privacy}", "followers_url": "https://api.github.com/users/wesm/followers", "following_url": "https://api.github.com/users/wesm/following{/other_user}", "gists_url": "https://api.github.com/users/wesm/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/wesm", "id": 329591, "login": "wesm", "node_id": "MDQ6VXNlcjMyOTU5MQ==", "organizations_url": "https://api.github.com/users/wesm/orgs", "received_events_url": "https://api.github.com/users/wesm/received_events", "repos_url": "https://api.github.com/users/wesm/repos", "site_admin": false, "starred_url": "https://api.github.com/users/wesm/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/wesm/subscriptions", "type": "User", "url": "https://api.github.com/users/wesm" }, "description": "on-merge: backport to 1.0.x", "due_on": "2020-02-01T08:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/16", "id": 174211, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/16/labels", "node_id": "MDk6TWlsZXN0b25lMTc0MjEx", "number": 16, "open_issues": 0, "state": "closed", "title": "1.0.0", "updated_at": "2020-01-30T12:18:05Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/16" }
15
2016-05-19T14:41:19Z
2020-01-07T23:45:41Z
2020-01-07T23:45:41Z
NONE
null
#### Code Sample, a copy-pastable example if possible ``` # In 0.17.1: x = pd.Series(1/3) x.map(lambda x: str(x)).to_dict() {0: '0.333333333333'} x.astype(str).map(lambda x: x).to_dict() {0: '0.333333333333'} # In 0.18.1: x = pd.Series(1/3) x.map(lambda x: str(x)).to_dict() {0: '0.3333333333333333'} x.astype(str).map(lambda x: x).to_dict() {0: '0.333333333333'} ``` #### Expected Output I'd expect the same output as in 0.17.x and before. I do this a lot to convert floats to decimal.decimal with .map(lambda x: D(str(x))) which is slightly faster than using .astype(str).map(D). This also messed up many of my unit-tests where I convert DFs to string dicts. Thanks to those I found this at all. I checked the change docs but couldn't find something that points to why this should have changed. #### output of `pd.show_versions()`
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13228/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13228/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13229
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13229/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13229/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13229/events
https://github.com/pandas-dev/pandas/issues/13229
155,771,182
MDU6SXNzdWUxNTU3NzExODI=
13,229
DOC: sas & R functionaility
{ "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }
[ { "color": "3465A4", "default": false, "description": null, "id": 134699, "name": "Docs", "node_id": "MDU6TGFiZWwxMzQ2OTk=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Docs" }, { "color": "5319e7", "default": false, "description": "SAS: read_sas", "id": 258745163, "name": "IO SAS", "node_id": "MDU6TGFiZWwyNTg3NDUxNjM=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20SAS" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 2361, "created_at": "2015-02-26T19:29:05Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1020496?v=4", "events_url": "https://api.github.com/users/jorisvandenbossche/events{/privacy}", "followers_url": "https://api.github.com/users/jorisvandenbossche/followers", "following_url": "https://api.github.com/users/jorisvandenbossche/following{/other_user}", "gists_url": "https://api.github.com/users/jorisvandenbossche/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jorisvandenbossche", "id": 1020496, "login": "jorisvandenbossche", "node_id": "MDQ6VXNlcjEwMjA0OTY=", "organizations_url": "https://api.github.com/users/jorisvandenbossche/orgs", "received_events_url": "https://api.github.com/users/jorisvandenbossche/received_events", "repos_url": "https://api.github.com/users/jorisvandenbossche/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jorisvandenbossche/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jorisvandenbossche/subscriptions", "type": "User", "url": "https://api.github.com/users/jorisvandenbossche" }, "description": "A milestone for closed or open issues for which there is no action needed (eg not a bug, just a question / discussion, nothing to resolve, wontfix, etc).\r\n\r\n", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/33", "id": 997544, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33/labels", "node_id": "MDk6TWlsZXN0b25lOTk3NTQ0", "number": 33, "open_issues": 11, "state": "open", "title": "No action", "updated_at": "2021-11-19T17:33:16Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33" }
4
2016-05-19T15:49:59Z
2021-04-15T06:49:37Z
2021-04-15T06:49:28Z
CONTRIBUTOR
null
http://blog.dominodatalab.com/using-r-and-python-for-common-sas-functions/?utm_source=&utm_medium=&utm_campaign= might be interesting to update `comparison_with_SAS/R` with this.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13229/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13229/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13230
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13230/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13230/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13230/events
https://github.com/pandas-dev/pandas/issues/13230
155,799,966
MDU6SXNzdWUxNTU3OTk5NjY=
13,230
Different order in datetime-column using sort_values on multiple columns
{ "avatar_url": "https://avatars.githubusercontent.com/u/10881376?v=4", "events_url": "https://api.github.com/users/marcomayer/events{/privacy}", "followers_url": "https://api.github.com/users/marcomayer/followers", "following_url": "https://api.github.com/users/marcomayer/following{/other_user}", "gists_url": "https://api.github.com/users/marcomayer/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/marcomayer", "id": 10881376, "login": "marcomayer", "node_id": "MDQ6VXNlcjEwODgxMzc2", "organizations_url": "https://api.github.com/users/marcomayer/orgs", "received_events_url": "https://api.github.com/users/marcomayer/received_events", "repos_url": "https://api.github.com/users/marcomayer/repos", "site_admin": false, "starred_url": "https://api.github.com/users/marcomayer/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/marcomayer/subscriptions", "type": "User", "url": "https://api.github.com/users/marcomayer" }
[ { "color": "0e8a16", "default": true, "description": null, "id": 717120670, "name": "good first issue", "node_id": "MDU6TGFiZWw3MTcxMjA2NzA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/good%20first%20issue" }, { "color": "cdea3c", "default": false, "description": "Unit test(s) needed to prevent regressions", "id": 986278782, "name": "Needs Tests", "node_id": "MDU6TGFiZWw5ODYyNzg3ODI=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Needs%20Tests" } ]
closed
false
null
[]
{ "closed_at": "2020-01-30T12:18:05Z", "closed_issues": 2207, "created_at": "2012-09-13T02:13:00Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/329591?v=4", "events_url": "https://api.github.com/users/wesm/events{/privacy}", "followers_url": "https://api.github.com/users/wesm/followers", "following_url": "https://api.github.com/users/wesm/following{/other_user}", "gists_url": "https://api.github.com/users/wesm/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/wesm", "id": 329591, "login": "wesm", "node_id": "MDQ6VXNlcjMyOTU5MQ==", "organizations_url": "https://api.github.com/users/wesm/orgs", "received_events_url": "https://api.github.com/users/wesm/received_events", "repos_url": "https://api.github.com/users/wesm/repos", "site_admin": false, "starred_url": "https://api.github.com/users/wesm/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/wesm/subscriptions", "type": "User", "url": "https://api.github.com/users/wesm" }, "description": "on-merge: backport to 1.0.x", "due_on": "2020-02-01T08:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/16", "id": 174211, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/16/labels", "node_id": "MDk6TWlsZXN0b25lMTc0MjEx", "number": 16, "open_issues": 0, "state": "closed", "title": "1.0.0", "updated_at": "2020-01-30T12:18:05Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/16" }
6
2016-05-19T18:09:42Z
2020-01-07T23:45:40Z
2020-01-07T23:45:40Z
NONE
null
#### Code Sample, a copy-pastable example if possible ``` #0.17.1: df = pd.DataFrame([1,2,3,4,5], columns=list('A'), index=pd.date_range('2010-01-01 09:00:00', periods=5, freq='s')).reset_index() df['date'] = df['index'] del df['index'] df.loc[4,'A'] = 4 df.loc[4,'date'] = pd.NaT print(df.sort_values(['A','date'])) A date 0 1 2010-01-01 09:00:00 1 2 2010-01-01 09:00:01 2 3 2010-01-01 09:00:02 4 4 NaT 3 4 2010-01-01 09:00:03 #0.18.1: df = pd.DataFrame([1,2,3,4,5], columns=list('A'), index=pd.date_range('2010-01-01 09:00:00', periods=5, freq='s')).reset_index() df['date'] = df['index'] del df['index'] df.loc[4,'A'] = 4 df.loc[4,'date'] = pd.NaT print(df.sort_values(['A','date'])) A date 0 1 2010-01-01 09:00:00 1 2 2010-01-01 09:00:01 2 3 2010-01-01 09:00:02 3 4 2010-01-01 09:00:03 4 4 NaT ``` #### Expected Output This one was hard to find. The order stays the same as in 0.17.1 when using only sort_values('date'), but using multiple cols, it changes sorting datetimes with NaT. Couldn't find anything in the Changelogs that points to a reason for this. #### output of `pd.show_versions()` ## INSTALLED VERSIONS commit: None python: 3.5.1.final.0 python-bits: 64 OS: Darwin OS-release: 15.5.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: None LANG: de_DE.UTF-8 pandas: 0.18.1 nose: 1.3.7 pip: 8.1.2 setuptools: 20.3 Cython: 0.23.4 numpy: 1.10.4 scipy: 0.17.1 statsmodels: 0.6.1 xarray: None IPython: 4.2.0 sphinx: 1.3.5 patsy: 0.4.0 dateutil: 2.5.1 pytz: 2016.2 blosc: None bottleneck: 1.0.0 tables: 3.2.2 numexpr: 2.5.2 matplotlib: 1.5.1 openpyxl: 2.3.2 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: 0.8.4 lxml: 3.6.0 bs4: 4.4.1 html5lib: None httplib2: None apiclient: None sqlalchemy: 1.0.12 pymysql: None psycopg2: None jinja2: 2.8 boto: 2.39.0 pandas_datareader: 0.2.1
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13230/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13230/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13231
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13231/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13231/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13231/events
https://github.com/pandas-dev/pandas/issues/13231
155,804,314
MDU6SXNzdWUxNTU4MDQzMTQ=
13,231
Automatic detection of HDF5 dataset identifier fails when data contains categoricals
{ "avatar_url": "https://avatars.githubusercontent.com/u/632858?v=4", "events_url": "https://api.github.com/users/chrish42/events{/privacy}", "followers_url": "https://api.github.com/users/chrish42/followers", "following_url": "https://api.github.com/users/chrish42/following{/other_user}", "gists_url": "https://api.github.com/users/chrish42/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/chrish42", "id": 632858, "login": "chrish42", "node_id": "MDQ6VXNlcjYzMjg1OA==", "organizations_url": "https://api.github.com/users/chrish42/orgs", "received_events_url": "https://api.github.com/users/chrish42/received_events", "repos_url": "https://api.github.com/users/chrish42/repos", "site_admin": false, "starred_url": "https://api.github.com/users/chrish42/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/chrish42/subscriptions", "type": "User", "url": "https://api.github.com/users/chrish42" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "5319e7", "default": false, "description": "read_hdf, HDFStore", "id": 47229190, "name": "IO HDF5", "node_id": "MDU6TGFiZWw0NzIyOTE5MA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20HDF5" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
14
2016-05-19T18:31:16Z
2016-06-05T14:08:12Z
2016-06-05T14:08:12Z
CONTRIBUTOR
null
We use HDF5 to store our pandas dataframes on disk. We only store one dataframe per HDF5, so the feature of pandas.read_hdf() that allows omitting the key when a HDF file contains a single Pandas object is very nice for our workflow. However, said feature doesn't work when the dataframe saved contains one or more categorical columns: ``` import pandas as pd df = pd.DataFrame({'col1': [11, 21, 31], 'col2': ['a', 'b', 'a']}) # This works fine. df.to_hdf('no_cat.hdf5', 'data', format='table') df2 = pd.read_hdf('no_cat.hdf5') print((df == df2).all().all()) # But this produces an exception. df.assign(col2=pd.Categorical(df.col2)).to_hdf('cat.hdf5', 'data', format='table') df3 = pd.read_hdf('cat.hdf5') # ValueError: key must be provided when HDF file contains multiple datasets. ``` It looks like this is because pandas.read_hdf() doesn't ignore the metadata used to store the categorical codes: ``` print(pd.HDFStore('cat.hdf5')) <class 'pandas.io.pytables.HDFStore'> File path: cat.hdf5 /data frame_table (typ->appendable,nrows->3,ncols->2,indexers->[index]) /data/meta/values_block_1/meta series_table (typ->appendable,nrows->2,ncols->1,indexers->[index],dc->[values]) ``` it'd be nice if this feature worked even when some of the columns are categoricals. It should be possible to ignore that metadata that pandas creates when looking if there is only one dataset stored, no?
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13231/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13231/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13232
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13232/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13232/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13232/events
https://github.com/pandas-dev/pandas/issues/13232
155,832,725
MDU6SXNzdWUxNTU4MzI3MjU=
13,232
PeriodIndex with float input inconsistency
{ "avatar_url": "https://avatars.githubusercontent.com/u/1696302?v=4", "events_url": "https://api.github.com/users/sinhrks/events{/privacy}", "followers_url": "https://api.github.com/users/sinhrks/followers", "following_url": "https://api.github.com/users/sinhrks/following{/other_user}", "gists_url": "https://api.github.com/users/sinhrks/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sinhrks", "id": 1696302, "login": "sinhrks", "node_id": "MDQ6VXNlcjE2OTYzMDI=", "organizations_url": "https://api.github.com/users/sinhrks/orgs", "received_events_url": "https://api.github.com/users/sinhrks/received_events", "repos_url": "https://api.github.com/users/sinhrks/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sinhrks/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sinhrks/subscriptions", "type": "User", "url": "https://api.github.com/users/sinhrks" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "AD7FA8", "default": false, "description": null, "id": 35818298, "name": "API Design", "node_id": "MDU6TGFiZWwzNTgxODI5OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/API%20Design" }, { "color": "eb6420", "default": false, "description": "Period data type", "id": 60635328, "name": "Period", "node_id": "MDU6TGFiZWw2MDYzNTMyOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Period" } ]
closed
false
null
[]
{ "closed_at": "2017-05-06T10:20:19Z", "closed_issues": 987, "created_at": "2016-02-08T15:30:21Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "after 0.19.x series", "due_on": "2017-05-12T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/39", "id": 1570595, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/39/labels", "node_id": "MDk6TWlsZXN0b25lMTU3MDU5NQ==", "number": 39, "open_issues": 0, "state": "closed", "title": "0.20.0", "updated_at": "2018-10-28T08:18:42Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/39" }
12
2016-05-19T20:54:42Z
2017-03-04T21:15:37Z
2017-03-04T21:15:37Z
MEMBER
null
#### Code Sample, a copy-pastable example if possible ``` pd.PeriodIndex([1.1], freq='M') # ValueError: Given date string not likely a datetime. pd.PeriodIndex(np.array([1.1]), freq='M') # PeriodIndex(['1970-02'], dtype='int64', freq='M' ``` #### Expected Output Consistently raise or coerce to `Period` #### output of `pd.show_versions()` 0.18.1 CC: @MaximilianR
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13232/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13232/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13233
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13233/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13233/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13233/events
https://github.com/pandas-dev/pandas/pull/13233
155,839,413
MDExOlB1bGxSZXF1ZXN0NzA3NjgyODg=
13,233
BUG: GH13219 Fixed. Allow unicode values in usecol
{ "avatar_url": "https://avatars.githubusercontent.com/u/1965378?v=4", "events_url": "https://api.github.com/users/hassanshamim/events{/privacy}", "followers_url": "https://api.github.com/users/hassanshamim/followers", "following_url": "https://api.github.com/users/hassanshamim/following{/other_user}", "gists_url": "https://api.github.com/users/hassanshamim/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/hassanshamim", "id": 1965378, "login": "hassanshamim", "node_id": "MDQ6VXNlcjE5NjUzNzg=", "organizations_url": "https://api.github.com/users/hassanshamim/orgs", "received_events_url": "https://api.github.com/users/hassanshamim/received_events", "repos_url": "https://api.github.com/users/hassanshamim/repos", "site_admin": false, "starred_url": "https://api.github.com/users/hassanshamim/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/hassanshamim/subscriptions", "type": "User", "url": "https://api.github.com/users/hassanshamim" }
[ { "color": "444444", "default": false, "description": "Unicode strings", "id": 36380025, "name": "Unicode", "node_id": "MDU6TGFiZWwzNjM4MDAyNQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Unicode" }, { "color": "5319e7", "default": false, "description": "read_csv, to_csv", "id": 47229171, "name": "IO CSV", "node_id": "MDU6TGFiZWw0NzIyOTE3MQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20CSV" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
12
2016-05-19T21:27:26Z
2016-06-01T11:13:44Z
2016-06-01T11:13:41Z
CONTRIBUTOR
null
- [x] closes #13219 - [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` - [x] whatsnew entry This is my first time contributing to this project. Let me know what needs to be improved, especially with regards to the test and the bugfix. It was simpler than I imagined which makes me want to say I did it wrong.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13233/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13233/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13233.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13233", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13233.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13233" }
https://api.github.com/repos/pandas-dev/pandas/issues/13234
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13234/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13234/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13234/events
https://github.com/pandas-dev/pandas/pull/13234
155,856,779
MDExOlB1bGxSZXF1ZXN0NzA3ODA5Nzk=
13,234
Correct ValueError invalid type promotion exception
{ "avatar_url": "https://avatars.githubusercontent.com/u/50109?v=4", "events_url": "https://api.github.com/users/gliptak/events{/privacy}", "followers_url": "https://api.github.com/users/gliptak/followers", "following_url": "https://api.github.com/users/gliptak/following{/other_user}", "gists_url": "https://api.github.com/users/gliptak/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/gliptak", "id": 50109, "login": "gliptak", "node_id": "MDQ6VXNlcjUwMTA5", "organizations_url": "https://api.github.com/users/gliptak/orgs", "received_events_url": "https://api.github.com/users/gliptak/received_events", "repos_url": "https://api.github.com/users/gliptak/repos", "site_admin": false, "starred_url": "https://api.github.com/users/gliptak/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gliptak/subscriptions", "type": "User", "url": "https://api.github.com/users/gliptak" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "0b02e1", "default": false, "description": "Related to indexing on series/frames, not to indexes themselves", "id": 2822098, "name": "Indexing", "node_id": "MDU6TGFiZWwyODIyMDk4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Indexing" }, { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
6
2016-05-19T23:21:12Z
2016-05-23T13:05:48Z
2016-05-23T13:05:43Z
CONTRIBUTOR
null
- [x] closes #12599 - [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` - [x] whatsnew entry
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13234/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13234/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13234.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13234", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13234.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13234" }
https://api.github.com/repos/pandas-dev/pandas/issues/13235
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13235/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13235/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13235/events
https://github.com/pandas-dev/pandas/issues/13235
155,905,085
MDU6SXNzdWUxNTU5MDUwODU=
13,235
label keyword argument for resample causes an error when used with a groupby object
{ "avatar_url": "https://avatars.githubusercontent.com/u/747219?v=4", "events_url": "https://api.github.com/users/roycoding/events{/privacy}", "followers_url": "https://api.github.com/users/roycoding/followers", "following_url": "https://api.github.com/users/roycoding/following{/other_user}", "gists_url": "https://api.github.com/users/roycoding/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/roycoding", "id": 747219, "login": "roycoding", "node_id": "MDQ6VXNlcjc0NzIxOQ==", "organizations_url": "https://api.github.com/users/roycoding/orgs", "received_events_url": "https://api.github.com/users/roycoding/received_events", "repos_url": "https://api.github.com/users/roycoding/repos", "site_admin": false, "starred_url": "https://api.github.com/users/roycoding/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/roycoding/subscriptions", "type": "User", "url": "https://api.github.com/users/roycoding" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "207de5", "default": false, "description": "resample method", "id": 74975453, "name": "Resample", "node_id": "MDU6TGFiZWw3NDk3NTQ1Mw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Resample" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
2
2016-05-20T07:41:17Z
2016-05-25T12:14:52Z
2016-05-25T12:14:52Z
CONTRIBUTOR
null
#### Code Sample, a copy-pastable example if possible ``` Python import numpy as np import pandas as pd index = pd.date_range('2000-01-01', freq='2D', periods=5) df = pd.DataFrame(index=index, data={'col1':[0,0,1,1,2], 'col2':[1,1,1,1,1]}) df.groupby('col1').resample('1W', label='left').sum() ``` #### The dataframe ``` col1 col2 2000-01-01 0 1 2000-01-03 0 1 2000-01-05 1 1 2000-01-07 1 1 2000-01-09 2 1 ``` #### Expected Output ``` col1 col2 col1 0 1999-12-26 0 1 2000-01-02 0 1 1 2000-01-02 2 2 2 2000-01-02 2 1 ``` #### Actual ouput ``` TypeError Traceback (most recent call last) <ipython-input-53-6e7ac0fde8b3> in <module>() ----> 1 df.groupby('col1').resample('1W', label='left').sum() /Users/roycoding/venv-lib-upgrade/lib/python2.7/site-packages/pandas/core/groupby.pyc in resample(self, rule, *args, **kwargs) 1080 """ 1081 from pandas.tseries.resample import get_resampler_for_grouping -> 1082 return get_resampler_for_grouping(self, rule, *args, **kwargs) 1083 1084 @Substitution(name='groupby') /Users/roycoding/venv-lib-upgrade/lib/python2.7/site-packages/pandas/tseries/resample.pyc in get_resampler_for_grouping(groupby, rule, how, fill_method, limit, kind, **kwargs) 910 fill_method=fill_method, 911 limit=limit, --> 912 **kwargs) 913 914 TypeError: _maybe_process_deprecations() got an unexpected keyword argument 'label' ``` Without the `label` keyword, I get this (with expected right labeled dates): ``` col1 col2 col1 0 2000-01-02 0 1 2000-01-09 0 1 1 2000-01-09 2 2 2 2000-01-09 2 1 ``` #### output of `pd.show_versions()` ``` INSTALLED VERSIONS ------------------ commit: None python: 2.7.8.final.0 python-bits: 64 OS: Darwin OS-release: 13.4.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: None LANG: en_US.UTF-8 pandas: 0.18.1 nose: 1.3.7 pip: 1.5.6 setuptools: 3.6 Cython: None numpy: 1.11.0 scipy: 0.15.1 statsmodels: 0.6.1 xarray: None IPython: 3.2.1 sphinx: None patsy: None dateutil: 2.5.3 pytz: 2016.4 blosc: None bottleneck: None tables: None numexpr: 2.5 matplotlib: 1.4.3 openpyxl: None xlrd: None xlwt: None xlsxwriter: None lxml: None bs4: 4.4.1 html5lib: 0.9999999 httplib2: 0.9.2 apiclient: None sqlalchemy: 1.0.12 pymysql: None psycopg2: 2.6.1 (dt dec pq3 ext lo64) jinja2: 2.8 boto: None pandas_datareader: None ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13235/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13235/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13236
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13236/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13236/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13236/events
https://github.com/pandas-dev/pandas/issues/13236
155,922,105
MDU6SXNzdWUxNTU5MjIxMDU=
13,236
COMPAT: .map iterates over python types rather than storage type
{ "avatar_url": "https://avatars.githubusercontent.com/u/3242660?v=4", "events_url": "https://api.github.com/users/glaucouri/events{/privacy}", "followers_url": "https://api.github.com/users/glaucouri/followers", "following_url": "https://api.github.com/users/glaucouri/following{/other_user}", "gists_url": "https://api.github.com/users/glaucouri/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/glaucouri", "id": 3242660, "login": "glaucouri", "node_id": "MDQ6VXNlcjMyNDI2NjA=", "organizations_url": "https://api.github.com/users/glaucouri/orgs", "received_events_url": "https://api.github.com/users/glaucouri/received_events", "repos_url": "https://api.github.com/users/glaucouri/repos", "site_admin": false, "starred_url": "https://api.github.com/users/glaucouri/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/glaucouri/subscriptions", "type": "User", "url": "https://api.github.com/users/glaucouri" }
[ { "color": "3465A4", "default": false, "description": null, "id": 134699, "name": "Docs", "node_id": "MDU6TGFiZWwxMzQ2OTk=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Docs" }, { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" }, { "color": "AD7FA8", "default": false, "description": null, "id": 35818298, "name": "API Design", "node_id": "MDU6TGFiZWwzNTgxODI5OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/API%20Design" }, { "color": "0052cc", "default": false, "description": "pandas objects compatability with Numpy or Python functions", "id": 76865106, "name": "Compat", "node_id": "MDU6TGFiZWw3Njg2NTEwNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Compat" } ]
closed
false
null
[]
{ "closed_at": "2017-10-28T18:54:27Z", "closed_issues": 764, "created_at": "2017-03-23T13:26:25Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2017-10-27T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/46", "id": 2406656, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/46/labels", "node_id": "MDk6TWlsZXN0b25lMjQwNjY1Ng==", "number": 46, "open_issues": 0, "state": "closed", "title": "0.21.0", "updated_at": "2018-07-08T21:53:21Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/46" }
17
2016-05-20T09:27:17Z
2017-09-12T12:54:54Z
2017-09-12T12:54:54Z
NONE
null
#### Code Sample, a copy-pastable example if possible ``` import pandas as P S=P.Series([0.6,0.2,15]) ``` **pandas 0.18+numpy 0.10**: ``` In [1]: print S.dtype float64 In [2]: print S.values.dtype float64 In [3]: print S.map(type) 0 <type 'numpy.float64'> 1 <type 'numpy.float64'> 2 <type 'numpy.float64'> dtype: object ``` **pandas 0.18.1+numpy 0.11.0**: ``` In [5]: print S.dtype float64 In [6]: print S.values.dtype float64 In [7]: print S.map(type) 0 <type 'float'> 1 <type 'float'> 2 <type 'float'> dtype: object ``` I expect to get the same dtype for the 3 print, why this is changed in last version? #### output of `pd.show_versions()` ``` pandas: 0.18.1 nose: 1.3.7 pip: 1.5.4 setuptools: 21.0.0 Cython: 0.24 numpy: 1.11.0 scipy: 0.17.0 statsmodels: 0.6.1 xarray: None IPython: 4.2.0 sphinx: 1.3.5 patsy: 0.4.1 dateutil: 2.4.2 pytz: 2016.4 blosc: 1.2.7 bottleneck: None tables: 3.2.2 numexpr: 2.5.2 matplotlib: 1.5.1 openpyxl: 2.3.5 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: None lxml: 3.4.0 bs4: 4.4.1 html5lib: 0.9999999 httplib2: None apiclient: None sqlalchemy: 1.0.12 pymysql: None psycopg2: None jinja2: 2.8 boto: None pandas_datareader: None ``` Thank you Gla
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13236/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13236/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13237
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13237/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13237/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13237/events
https://github.com/pandas-dev/pandas/issues/13237
155,953,663
MDU6SXNzdWUxNTU5NTM2NjM=
13,237
cannot safely convert passed user dtype of <f8 for object dtyped data in column ***
{ "avatar_url": "https://avatars.githubusercontent.com/u/1320172?v=4", "events_url": "https://api.github.com/users/wildwild/events{/privacy}", "followers_url": "https://api.github.com/users/wildwild/followers", "following_url": "https://api.github.com/users/wildwild/following{/other_user}", "gists_url": "https://api.github.com/users/wildwild/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/wildwild", "id": 1320172, "login": "wildwild", "node_id": "MDQ6VXNlcjEzMjAxNzI=", "organizations_url": "https://api.github.com/users/wildwild/orgs", "received_events_url": "https://api.github.com/users/wildwild/received_events", "repos_url": "https://api.github.com/users/wildwild/repos", "site_admin": false, "starred_url": "https://api.github.com/users/wildwild/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/wildwild/subscriptions", "type": "User", "url": "https://api.github.com/users/wildwild" }
[ { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" }, { "color": "0052cc", "default": false, "description": null, "id": 34444536, "name": "Usage Question", "node_id": "MDU6TGFiZWwzNDQ0NDUzNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Usage%20Question" } ]
closed
false
null
[]
null
13
2016-05-20T12:37:21Z
2019-03-18T06:19:53Z
2016-05-20T12:49:25Z
NONE
null
#### Code Sample, a copy-pastable example if possible under 64bit windows problem it's ok on win32 platform ,but it does not work under 64bit,unless I remove the dtype and read the DataFrame and then transform the format asfloat ... I cant debug into the file market_head_list = ['TradingDay','ClosePrice'] dt['TradingDay'] = np.str dt['ClosePrice'] = float # I used np.float64 too ,but it still cant work csv_str_now ='1.7976931348623157e+308, 1.7976931348623157e+308 ' ``` csv_str = StringIO.StringIO((csv_str_now)) df = pd.read_csv(csv_str, engine='c', names=market_head_list,dtype=dt) ``` #### output of `pd.show_versions()` pandas: 0.18.1 nose: 1.3.7 pip: 8.1.2 setuptools: 20.3 Cython: 0.23.4 numpy: 1.11.0 scipy: 0.17.0 statsmodels: None xarray: None IPython: 4.1.2 sphinx: 1.3.5 patsy: 0.4.0 dateutil: 2.5.1 pytz: 2016.2 blosc: None bottleneck: 1.0.0 tables: 3.2.2 numexpr: 2.5.2 matplotlib: 1.5.1 openpyxl: 2.3.2 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: 0.8.4 lxml: 3.6.0 bs4: 4.4.1 html5lib: None httplib2: None apiclient: None sqlalchemy: 1.0.12 pymysql: None psycopg2: None jinja2: 2.8 boto: 2.39.0 pandas_datareader: None File "pandas\parser.pyx", line 805, in pandas.parser.TextReader.read (pandas\parser.c:8620) File "pandas\parser.pyx", line 827, in pandas.parser.TextReader._read_low_memory (pandas\parser.c:8876) File "pandas\parser.pyx", line 904, in pandas.parser.TextReader._read_rows (pandas\parser.c:9893) File "pandas\parser.pyx", line 1011, in pandas.parser.TextReader._convert_column_data (pandas\parser.c:11286) File "pandas\parser.pyx", line 1092, in pandas.parser.TextReader._convert_tokens (pandas\parser.c:12659) ValueError: cannot safely convert passed user dtype of <f8 for object dtyped data in column 1
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13237/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13237/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13238
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13238/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13238/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13238/events
https://github.com/pandas-dev/pandas/issues/13238
155,971,896
MDU6SXNzdWUxNTU5NzE4OTY=
13,238
Resample discards timezone information
{ "avatar_url": "https://avatars.githubusercontent.com/u/835184?v=4", "events_url": "https://api.github.com/users/jeremywhelchel/events{/privacy}", "followers_url": "https://api.github.com/users/jeremywhelchel/followers", "following_url": "https://api.github.com/users/jeremywhelchel/following{/other_user}", "gists_url": "https://api.github.com/users/jeremywhelchel/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jeremywhelchel", "id": 835184, "login": "jeremywhelchel", "node_id": "MDQ6VXNlcjgzNTE4NA==", "organizations_url": "https://api.github.com/users/jeremywhelchel/orgs", "received_events_url": "https://api.github.com/users/jeremywhelchel/received_events", "repos_url": "https://api.github.com/users/jeremywhelchel/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jeremywhelchel/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jeremywhelchel/subscriptions", "type": "User", "url": "https://api.github.com/users/jeremywhelchel" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "e11d21", "default": false, "description": "Functionality that used to work in a prior pandas version", "id": 32815646, "name": "Regression", "node_id": "MDU6TGFiZWwzMjgxNTY0Ng==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Regression" }, { "color": "5319e7", "default": false, "description": "Timezone data dtype", "id": 60458168, "name": "Timezones", "node_id": "MDU6TGFiZWw2MDQ1ODE2OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Timezones" }, { "color": "207de5", "default": false, "description": "resample method", "id": 74975453, "name": "Resample", "node_id": "MDU6TGFiZWw3NDk3NTQ1Mw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Resample" }, { "color": "0e8a16", "default": true, "description": null, "id": 717120670, "name": "good first issue", "node_id": "MDU6TGFiZWw3MTcxMjA2NzA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/good%20first%20issue" } ]
closed
false
null
[]
{ "closed_at": "2018-05-16T03:09:58Z", "closed_issues": 1645, "created_at": "2017-10-20T10:17:09Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "after 0.22", "due_on": "2018-05-15T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/53", "id": 2853937, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/53/labels", "node_id": "MDk6TWlsZXN0b25lMjg1MzkzNw==", "number": 53, "open_issues": 0, "state": "closed", "title": "0.23.0", "updated_at": "2018-08-20T06:48:57Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/53" }
11
2016-05-20T14:11:10Z
2018-04-11T02:29:55Z
2018-04-11T02:29:55Z
NONE
null
It appears that resample is now dropping timezone information on the index. Is this expected? ``` a = pp.Series(index=pp.DatetimeIndex(['2013-01-01 06:00', '2013-01-01 07:00', '2013-01-02 06:00'], tz=pytz.timezone('America/Los_Angeles')), data=[1, 2, 3]) b = a.resample('D', how='max') print repr(a.index.tz) print repr(b.index.tz) print a.index.tz == b.index.tz ``` produces the following in 0.16.1. Notably the timezones for the original series and the resampled series are the same. ``` <DstTzInfo 'America/Los_Angeles' LMT-1 day, 16:07:00 STD> <DstTzInfo 'America/Los_Angeles' LMT-1 day, 16:07:00 STD> True ``` However that's not the case for 0.18.1. Caveat is that we're using the new resample syntax: `b = a.resample('D').max()` ``` <DstTzInfo 'America/Los_Angeles' LMT-1 day, 16:07:00 STD> <DstTzInfo 'America/Los_Angeles' PST-1 day, 16:00:00 STD> False ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13238/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13238/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13239
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13239/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13239/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13239/events
https://github.com/pandas-dev/pandas/issues/13239
155,999,239
MDU6SXNzdWUxNTU5OTkyMzk=
13,239
nunique Error when called by groupby from an empty dataframe
{ "avatar_url": "https://avatars.githubusercontent.com/u/7169207?v=4", "events_url": "https://api.github.com/users/zhangyingmath/events{/privacy}", "followers_url": "https://api.github.com/users/zhangyingmath/followers", "following_url": "https://api.github.com/users/zhangyingmath/following{/other_user}", "gists_url": "https://api.github.com/users/zhangyingmath/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/zhangyingmath", "id": 7169207, "login": "zhangyingmath", "node_id": "MDQ6VXNlcjcxNjkyMDc=", "organizations_url": "https://api.github.com/users/zhangyingmath/orgs", "received_events_url": "https://api.github.com/users/zhangyingmath/received_events", "repos_url": "https://api.github.com/users/zhangyingmath/repos", "site_admin": false, "starred_url": "https://api.github.com/users/zhangyingmath/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/zhangyingmath/subscriptions", "type": "User", "url": "https://api.github.com/users/zhangyingmath" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "729FCF", "default": false, "description": null, "id": 233160, "name": "Groupby", "node_id": "MDU6TGFiZWwyMzMxNjA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Groupby" }, { "color": "0b02e1", "default": false, "description": "Related to indexing on series/frames, not to indexes themselves", "id": 2822098, "name": "Indexing", "node_id": "MDU6TGFiZWwyODIyMDk4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Indexing" }, { "color": "009800", "default": false, "description": "Duplicate issue or pull request", "id": 40153326, "name": "Duplicate Report", "node_id": "MDU6TGFiZWw0MDE1MzMyNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Duplicate%20Report" } ]
closed
false
null
[]
null
1
2016-05-20T16:14:33Z
2016-05-20T16:32:58Z
2016-05-20T16:32:37Z
NONE
null
Initialize a dataframe: (I am using pandas version 0.17.1) ``` import pandas as pd a=pd.DataFrame({'f':[1,2,3,4]}) ``` First if I call nunique from an empty dataframe, I get what I expect: ``` a[a['f']>10]['f'].nunique() 0 ``` But If I call nunique from groupby, I get an error: ``` a[a['f']>10].groupby('f')['f'].nunique() Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/opt/ci1/plus/tc10b/sles11sp2_gcc-4.8.3_x86-64/PythonModules-2.7.8/20160310/lib/python/pandas/core/groupby.py", line 2695, in nunique return Series(out if ids[0] != -1 else out[1:], IndexError: index 0 is out of bounds for axis 0 with size 0 ``` On the other hand, the 'unique' function doesn't have this issue: ``` a[a['f']>10]['f'].unique() array([], dtype=int64) a[a['f']>10].groupby('f')['f'].unique() Series([], Name: f, dtype: float64) ``` I would like the 'nunique' function to behave like 'unique' when handling an empty dataframe + groupby. (Or please let me know if this issue is already fixed in later versions.) Thanks!
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13239/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13239/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13240
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13240/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13240/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13240/events
https://github.com/pandas-dev/pandas/issues/13240
156,015,566
MDU6SXNzdWUxNTYwMTU1NjY=
13,240
merge with series
{ "avatar_url": "https://avatars.githubusercontent.com/u/7169207?v=4", "events_url": "https://api.github.com/users/zhangyingmath/events{/privacy}", "followers_url": "https://api.github.com/users/zhangyingmath/followers", "following_url": "https://api.github.com/users/zhangyingmath/following{/other_user}", "gists_url": "https://api.github.com/users/zhangyingmath/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/zhangyingmath", "id": 7169207, "login": "zhangyingmath", "node_id": "MDQ6VXNlcjcxNjkyMDc=", "organizations_url": "https://api.github.com/users/zhangyingmath/orgs", "received_events_url": "https://api.github.com/users/zhangyingmath/received_events", "repos_url": "https://api.github.com/users/zhangyingmath/repos", "site_admin": false, "starred_url": "https://api.github.com/users/zhangyingmath/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/zhangyingmath/subscriptions", "type": "User", "url": "https://api.github.com/users/zhangyingmath" }
[ { "color": "02d7e1", "default": false, "description": "Concat, Merge/Join, Stack/Unstack, Explode", "id": 13098779, "name": "Reshaping", "node_id": "MDU6TGFiZWwxMzA5ODc3OQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Reshaping" }, { "color": "ffa0ff", "default": false, "description": "Incorrect or improved errors from pandas", "id": 42670965, "name": "Error Reporting", "node_id": "MDU6TGFiZWw0MjY3MDk2NQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Error%20Reporting" }, { "color": "0052cc", "default": false, "description": "pandas objects compatability with Numpy or Python functions", "id": 76865106, "name": "Compat", "node_id": "MDU6TGFiZWw3Njg2NTEwNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Compat" } ]
closed
false
null
[]
null
2
2016-05-20T17:45:35Z
2016-05-20T17:50:30Z
2016-05-20T17:49:55Z
NONE
null
#### Code Sample, a copy-pastable example if possible a=pd.DataFrame({'f':[1,2,3,4]}) b=pd.DataFrame({'f':[2,3,4,5]}) ## pd.merge(a['f'],b,on='f') Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/opt/ci1/plus/tc10b/sles11sp2_gcc-4.8.3_x86-64/PythonModules-2.7.8/20160310/lib/python/pandas/tools/merge.py", line 34, in merge copy=copy, indicator=indicator) File "/opt/ci1/plus/tc10b/sles11sp2_gcc-4.8.3_x86-64/PythonModules-2.7.8/20160310/lib/python/pandas/tools/merge.py", line 190, in **init** self.join_names) = self._get_merge_keys() File "/opt/ci1/plus/tc10b/sles11sp2_gcc-4.8.3_x86-64/PythonModules-2.7.8/20160310/lib/python/pandas/tools/merge.py", line 412, in _get_merge_keys left_keys.append(left[lk]._values) File "/opt/ci1/plus/tc10b/sles11sp2_gcc-4.8.3_x86-64/PythonModules-2.7.8/20160310/lib/python/pandas/core/series.py", line 557, in __getitem__ result = self.index.get_value(self, key) File "/opt/ci1/plus/tc10b/sles11sp2_gcc-4.8.3_x86-64/PythonModules-2.7.8/20160310/lib/python/pandas/core/index.py", line 1790, in get_value return self._engine.get_value(s, k) File "pandas/index.pyx", line 103, in pandas.index.IndexEngine.get_value (pandas/index.c:3204) File "pandas/index.pyx", line 111, in pandas.index.IndexEngine.get_value (pandas/index.c:2903) File "pandas/index.pyx", line 159, in pandas.index.IndexEngine.get_loc (pandas/index.c:3908) KeyError: 'f' #### Expected Output ``` f ``` 0 2 1 3 2 4 #### output of `pd.show_versions()` ## INSTALLED VERSIONS commit: None python: 2.7.8.final.0 python-bits: 64 OS: Linux OS-release: 3.0.38-0.5-default machine: x86_64 processor: x86_64 byteorder: little LC_ALL: None LANG: C pandas: 0.17.1 nose: 1.3.6 pip: 1.5.6 setuptools: 0.6 Cython: 0.21.1 numpy: 1.9.3 scipy: 0.16.1 statsmodels: 0.6.1 IPython: 4.0.1 sphinx: 1.2.2 patsy: 0.3.0 dateutil: 2.3 pytz: 2015.4 blosc: None bottleneck: 0.8.0 tables: 3.2.2 numexpr: 2.4 matplotlib: 1.4.3 openpyxl: 2.0.4 xlrd: 0.9.0 xlwt: 0.7.4 xlsxwriter: 0.7.3 lxml: 3.4.4 bs4: 4.3.2 html5lib: None httplib2: None apiclient: None sqlalchemy: 0.9.7 pymysql: 0.6.2.None psycopg2: None Jinja2: None
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13240/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13240/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13241
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13241/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13241/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13241/events
https://github.com/pandas-dev/pandas/pull/13241
156,023,039
MDExOlB1bGxSZXF1ZXN0NzA4OTcyNzY=
13,241
Fixes resampler for grouping kw bug #13235
{ "avatar_url": "https://avatars.githubusercontent.com/u/747219?v=4", "events_url": "https://api.github.com/users/roycoding/events{/privacy}", "followers_url": "https://api.github.com/users/roycoding/followers", "following_url": "https://api.github.com/users/roycoding/following{/other_user}", "gists_url": "https://api.github.com/users/roycoding/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/roycoding", "id": 747219, "login": "roycoding", "node_id": "MDQ6VXNlcjc0NzIxOQ==", "organizations_url": "https://api.github.com/users/roycoding/orgs", "received_events_url": "https://api.github.com/users/roycoding/received_events", "repos_url": "https://api.github.com/users/roycoding/repos", "site_admin": false, "starred_url": "https://api.github.com/users/roycoding/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/roycoding/subscriptions", "type": "User", "url": "https://api.github.com/users/roycoding" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "207de5", "default": false, "description": "resample method", "id": 74975453, "name": "Resample", "node_id": "MDU6TGFiZWw3NDk3NTQ1Mw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Resample" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
3
2016-05-20T18:25:40Z
2016-05-25T12:15:02Z
2016-05-25T12:14:52Z
CONTRIBUTOR
null
- [x] closes #13235 - [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` - [x] whatsnew entry
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13241/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13241/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13241.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13241", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13241.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13241" }
https://api.github.com/repos/pandas-dev/pandas/issues/13242
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13242/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13242/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13242/events
https://github.com/pandas-dev/pandas/issues/13242
156,057,890
MDU6SXNzdWUxNTYwNTc4OTA=
13,242
TST: test_assert_index check index attributes
{ "avatar_url": "https://avatars.githubusercontent.com/u/1696302?v=4", "events_url": "https://api.github.com/users/sinhrks/events{/privacy}", "followers_url": "https://api.github.com/users/sinhrks/followers", "following_url": "https://api.github.com/users/sinhrks/following{/other_user}", "gists_url": "https://api.github.com/users/sinhrks/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sinhrks", "id": 1696302, "login": "sinhrks", "node_id": "MDQ6VXNlcjE2OTYzMDI=", "organizations_url": "https://api.github.com/users/sinhrks/orgs", "received_events_url": "https://api.github.com/users/sinhrks/received_events", "repos_url": "https://api.github.com/users/sinhrks/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sinhrks/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sinhrks/subscriptions", "type": "User", "url": "https://api.github.com/users/sinhrks" }
[ { "color": "C4A000", "default": false, "description": "pandas testing functions or related to the test suite", "id": 127685, "name": "Testing", "node_id": "MDU6TGFiZWwxMjc2ODU=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Testing" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 786, "created_at": "2015-01-13T10:53:19Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "Changes that would be nice to have in the next release. These issues are not blocking. They will be pushed to the next release if no one has time to fix them.", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/32", "id": 933188, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32/labels", "node_id": "MDk6TWlsZXN0b25lOTMzMTg4", "number": 32, "open_issues": 1053, "state": "open", "title": "Contributions Welcome", "updated_at": "2021-11-21T00:50:06Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32" }
7
2016-05-20T21:52:40Z
2020-05-22T03:13:30Z
2020-05-22T03:13:29Z
MEMBER
null
- [x] `PeriodIndex.freq` (mandatory), #13250 - [x] `DatetimeIndex.tz` (mandatory) - [x] `DatetimeIndex.freq` (add `check_freq` option with default False, because lots of tests compare op result (lost freq) and expected result created by `date_range` (has freq)) - [x] `TimedeltaIndex.freq` (same as above), #13250 - [x] `CategoricalIndex` internals (`.codes` and `.categories`) (ref #13076, add `check_categorical` with default True), PR ##13249
{ "+1": 1, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13242/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13242/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13243
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13243/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13243/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13243/events
https://github.com/pandas-dev/pandas/issues/13243
156,058,053
MDU6SXNzdWUxNTYwNTgwNTM=
13,243
Idea: use df.index/df.columns names to automatically choose axis along which to broadcast
{ "avatar_url": "https://avatars.githubusercontent.com/u/10649212?v=4", "events_url": "https://api.github.com/users/supern8ent/events{/privacy}", "followers_url": "https://api.github.com/users/supern8ent/followers", "following_url": "https://api.github.com/users/supern8ent/following{/other_user}", "gists_url": "https://api.github.com/users/supern8ent/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/supern8ent", "id": 10649212, "login": "supern8ent", "node_id": "MDQ6VXNlcjEwNjQ5MjEy", "organizations_url": "https://api.github.com/users/supern8ent/orgs", "received_events_url": "https://api.github.com/users/supern8ent/received_events", "repos_url": "https://api.github.com/users/supern8ent/repos", "site_admin": false, "starred_url": "https://api.github.com/users/supern8ent/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/supern8ent/subscriptions", "type": "User", "url": "https://api.github.com/users/supern8ent" }
[ { "color": "0b02e1", "default": false, "description": "Related to indexing on series/frames, not to indexes themselves", "id": 2822098, "name": "Indexing", "node_id": "MDU6TGFiZWwyODIyMDk4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Indexing" }, { "color": "AD7FA8", "default": false, "description": null, "id": 35818298, "name": "API Design", "node_id": "MDU6TGFiZWwzNTgxODI5OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/API%20Design" } ]
closed
false
null
[]
null
2
2016-05-20T21:53:55Z
2016-05-24T20:06:27Z
2016-05-24T20:06:27Z
NONE
null
In writing some math code in pandas, I find it necessary to do things like ``` df2 = df.sub(ser, axis='columns') ``` instead of the shorter and more intuitive ``` df2 = df - ser ``` in order to control the axis along which the series is broadcast. I think it would be a big improvement syntactically if pandas would automatically broadcast down the axis that didn't have a matching name. Example: ``` df = pd.DataFrame(np.random.rand(3, 2), columns=['a', 'b']) df.index.name = 'dim0' df.columns.name = 'dim1' df dim1 a b dim0 0 0.755744 0.321682 1 0.915464 0.413154 2 0.647672 0.457927 ``` subtract: ``` df - df['a'] # does not give the desired result a b 0 1 2 dim0 0 NaN NaN NaN NaN NaN 1 NaN NaN NaN NaN NaN 2 NaN NaN NaN NaN NaN ``` subtract, specifying which axis to match on (broadcasting happens on the other axis): ``` df.sub(df['a'], axis='index') # gives the desired result dim1 a b dim0 0 0.0 -0.434062 1 0.0 -0.502310 2 0.0 -0.189745 ``` I am suggesting that the "-" operator would look at the names of the indices in the operands and match on the axis that has the same name in the two operands. By way of motivation, I'm doing mass spectral matching of compounds, so I could name my indices 'chemical' and 'mass'.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13243/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13243/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13244
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13244/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13244/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13244/events
https://github.com/pandas-dev/pandas/pull/13244
156,060,636
MDExOlB1bGxSZXF1ZXN0NzA5MjQzNjY=
13,244
Fix to_gbq method when verbose=False
{ "avatar_url": "https://avatars.githubusercontent.com/u/1209723?v=4", "events_url": "https://api.github.com/users/cgrin/events{/privacy}", "followers_url": "https://api.github.com/users/cgrin/followers", "following_url": "https://api.github.com/users/cgrin/following{/other_user}", "gists_url": "https://api.github.com/users/cgrin/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/cgrin", "id": 1209723, "login": "cgrin", "node_id": "MDQ6VXNlcjEyMDk3MjM=", "organizations_url": "https://api.github.com/users/cgrin/orgs", "received_events_url": "https://api.github.com/users/cgrin/received_events", "repos_url": "https://api.github.com/users/cgrin/repos", "site_admin": false, "starred_url": "https://api.github.com/users/cgrin/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/cgrin/subscriptions", "type": "User", "url": "https://api.github.com/users/cgrin" }
[ { "color": "0052cc", "default": false, "description": "pandas-gbq compatability", "id": 57351315, "name": "IO Google", "node_id": "MDU6TGFiZWw1NzM1MTMxNQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20Google" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
8
2016-05-20T22:13:53Z
2016-08-15T20:19:42Z
2016-08-15T20:19:33Z
CONTRIBUTOR
null
Currently the `to_gbq` method fails when `verbose=False`, as the printing of progress is done regardless of the value of the `verbose` flag, and therefore `total_rows` gets called without being set. This change suppresses printing of progress when `verbose=False`.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13244/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13244/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13244.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13244", "merged_at": "2016-08-15T20:19:33Z", "patch_url": "https://github.com/pandas-dev/pandas/pull/13244.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13244" }
https://api.github.com/repos/pandas-dev/pandas/issues/13245
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13245/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13245/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13245/events
https://github.com/pandas-dev/pandas/issues/13245
156,065,178
MDU6SXNzdWUxNTYwNjUxNzg=
13,245
Pandas incorrectly parses maturity code for yahoo options
{ "avatar_url": "https://avatars.githubusercontent.com/u/535259?v=4", "events_url": "https://api.github.com/users/yigu-2000/events{/privacy}", "followers_url": "https://api.github.com/users/yigu-2000/followers", "following_url": "https://api.github.com/users/yigu-2000/following{/other_user}", "gists_url": "https://api.github.com/users/yigu-2000/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/yigu-2000", "id": 535259, "login": "yigu-2000", "node_id": "MDQ6VXNlcjUzNTI1OQ==", "organizations_url": "https://api.github.com/users/yigu-2000/orgs", "received_events_url": "https://api.github.com/users/yigu-2000/received_events", "repos_url": "https://api.github.com/users/yigu-2000/repos", "site_admin": false, "starred_url": "https://api.github.com/users/yigu-2000/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/yigu-2000/subscriptions", "type": "User", "url": "https://api.github.com/users/yigu-2000" }
[ { "color": "06909A", "default": false, "description": "IO issues that don't fit into a more specific label", "id": 2301354, "name": "IO Data", "node_id": "MDU6TGFiZWwyMzAxMzU0", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20Data" } ]
closed
false
null
[]
null
1
2016-05-20T22:53:37Z
2016-05-20T23:33:52Z
2016-05-20T23:33:45Z
NONE
null
Pandas's option.get_all_data incorrectly parses the maturity dates for all options, so 2017 options from Yahoo will be parsed to 2020 option. This is because a problem logic to use to_datetime() to convert the date string. A simple and practical fix is to append "20" in front of the string before calling to_datetime(). Line to fix is in data.py's _process_data function. - Yi Gu 2016 # frame["Expiry"] = to_datetime("20"+frame.Rootexp.str[-6:]) # sample code to produce the error from pandas.io.data import Options myopt = Options("GS", "yahoo") data = myopt.get_all_data() print data.ix[0].name #### Expected Output (310.0, Timestamp('2020-01-17 00:00:00'), 'put', u'GS170120P00310000') After the code correction, the correct output should be (310.0, Timestamp('2017-01-20 00:00:00'), 'put', u'GS170120P00310000') #### output of `pd.show_versions()` ## INSTALLED VERSIONS commit: None python: 2.7.11.final.0 python-bits: 64 OS: Windows OS-release: 10 machine: AMD64 processor: AMD64 Family 22 Model 48 Stepping 1, AuthenticAMD byteorder: little LC_ALL: None LANG: None pandas: 0.18.0 nose: 1.3.7 pip: 8.1.1 setuptools: 20.7.0 Cython: 0.23.4 numpy: 1.10.4 scipy: 0.16.0 statsmodels: 0.6.1 xarray: None IPython: 4.0.1 sphinx: 1.3.1 patsy: 0.4.0 dateutil: 2.5.2 pytz: 2016.3 blosc: None bottleneck: 1.0.0 tables: 3.2.2 numexpr: 2.4.4 matplotlib: 1.5.0 openpyxl: 2.2.6 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: 0.7.7 lxml: 3.4.4 bs4: 4.4.1 html5lib: 0.9999999 httplib2: None apiclient: None sqlalchemy: 1.0.9 pymysql: None psycopg2: None jinja2: 2.8 boto: 2.38.0
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13245/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13245/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13246
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13246/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13246/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13246/events
https://github.com/pandas-dev/pandas/pull/13246
156,076,387
MDExOlB1bGxSZXF1ZXN0NzA5MzU2NDQ=
13,246
Reverse numpy compat changes to tslib.pyx
{ "avatar_url": "https://avatars.githubusercontent.com/u/9273653?v=4", "events_url": "https://api.github.com/users/gfyoung/events{/privacy}", "followers_url": "https://api.github.com/users/gfyoung/followers", "following_url": "https://api.github.com/users/gfyoung/following{/other_user}", "gists_url": "https://api.github.com/users/gfyoung/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/gfyoung", "id": 9273653, "login": "gfyoung", "node_id": "MDQ6VXNlcjkyNzM2NTM=", "organizations_url": "https://api.github.com/users/gfyoung/orgs", "received_events_url": "https://api.github.com/users/gfyoung/received_events", "repos_url": "https://api.github.com/users/gfyoung/repos", "site_admin": false, "starred_url": "https://api.github.com/users/gfyoung/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gfyoung/subscriptions", "type": "User", "url": "https://api.github.com/users/gfyoung" }
[ { "color": "0052cc", "default": false, "description": "pandas objects compatability with Numpy or Python functions", "id": 76865106, "name": "Compat", "node_id": "MDU6TGFiZWw3Njg2NTEwNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Compat" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
1
2016-05-21T01:19:16Z
2016-05-21T14:05:21Z
2016-05-21T14:05:17Z
MEMBER
null
Title is self-explanatory. xref #13148.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13246/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13246/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13246.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13246", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13246.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13246" }
https://api.github.com/repos/pandas-dev/pandas/issues/13247
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13247/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13247/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13247/events
https://github.com/pandas-dev/pandas/issues/13247
156,085,393
MDU6SXNzdWUxNTYwODUzOTM=
13,247
BUG: upcasting on reshaping ops
{ "avatar_url": "https://avatars.githubusercontent.com/u/10360673?v=4", "events_url": "https://api.github.com/users/jennolsen84/events{/privacy}", "followers_url": "https://api.github.com/users/jennolsen84/followers", "following_url": "https://api.github.com/users/jennolsen84/following{/other_user}", "gists_url": "https://api.github.com/users/jennolsen84/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jennolsen84", "id": 10360673, "login": "jennolsen84", "node_id": "MDQ6VXNlcjEwMzYwNjcz", "organizations_url": "https://api.github.com/users/jennolsen84/orgs", "received_events_url": "https://api.github.com/users/jennolsen84/received_events", "repos_url": "https://api.github.com/users/jennolsen84/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jennolsen84/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jennolsen84/subscriptions", "type": "User", "url": "https://api.github.com/users/jennolsen84" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "d7e102", "default": false, "description": "np.nan, pd.NaT, pd.NA, dropna, isnull, interpolate", "id": 2822342, "name": "Missing-data", "node_id": "MDU6TGFiZWwyODIyMzQy", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Missing-data" }, { "color": "02d7e1", "default": false, "description": "Concat, Merge/Join, Stack/Unstack, Explode", "id": 13098779, "name": "Reshaping", "node_id": "MDU6TGFiZWwxMzA5ODc3OQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Reshaping" }, { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" } ]
closed
false
null
[]
{ "closed_at": "2017-05-06T10:20:19Z", "closed_issues": 987, "created_at": "2016-02-08T15:30:21Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "after 0.19.x series", "due_on": "2017-05-12T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/39", "id": 1570595, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/39/labels", "node_id": "MDk6TWlsZXN0b25lMTU3MDU5NQ==", "number": 39, "open_issues": 0, "state": "closed", "title": "0.20.0", "updated_at": "2018-10-28T08:18:42Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/39" }
6
2016-05-21T05:34:17Z
2017-03-14T13:33:58Z
2017-03-14T13:33:58Z
CONTRIBUTOR
null
#### Code Sample, a copy-pastable example if possible ``` import pandas as pd import numpy as np pn1 = pd.Panel(np.array([1.0], dtype=np.float32, ndmin=3)) # panel of 1.0 pn2 = pd.Panel(np.array([np.nan], dtype=np.float32, ndmin=3)) # panel of nan print(pd.concat([pn1, pn1]).values.dtype) print(pd.concat([pn2, pn2]).values.dtype) ``` #### Current Output ``` float32 float64 ``` #### Expected Output ``` float32 float32 ``` #### output of `pd.show_versions()` ``` INSTALLED VERSIONS ------------------ commit: None python: 3.5.1.final.0 python-bits: 64 OS: Darwin OS-release: 14.5.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: None LANG: en_US.UTF-8 pandas: 0.18.1 nose: 1.3.7 pip: 8.1.0 setuptools: 20.2.2 Cython: 0.23.4 numpy: 1.11.0 scipy: 0.17.0 statsmodels: None xarray: None IPython: 4.0.1 sphinx: 1.3.1 patsy: None dateutil: 2.4.2 pytz: 2015.7 blosc: None bottleneck: 1.1.0dev tables: 3.2.2 numexpr: 2.5.1 matplotlib: 1.5.1 openpyxl: None xlrd: None xlwt: None xlsxwriter: None lxml: None bs4: None html5lib: None httplib2: 0.9.2 apiclient: None sqlalchemy: 1.0.12 pymysql: 0.6.7.None psycopg2: 2.6.1 (dt dec pq3 ext) jinja2: 2.8 boto: None pandas_datareader: None ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13247/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13247/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13248
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13248/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13248/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13248/events
https://github.com/pandas-dev/pandas/issues/13248
156,086,390
MDU6SXNzdWUxNTYwODYzOTA=
13,248
BUG: DataFrame and datetime scalar ops may results in incorrect dtype
{ "avatar_url": "https://avatars.githubusercontent.com/u/1696302?v=4", "events_url": "https://api.github.com/users/sinhrks/events{/privacy}", "followers_url": "https://api.github.com/users/sinhrks/followers", "following_url": "https://api.github.com/users/sinhrks/following{/other_user}", "gists_url": "https://api.github.com/users/sinhrks/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sinhrks", "id": 1696302, "login": "sinhrks", "node_id": "MDQ6VXNlcjE2OTYzMDI=", "organizations_url": "https://api.github.com/users/sinhrks/orgs", "received_events_url": "https://api.github.com/users/sinhrks/received_events", "repos_url": "https://api.github.com/users/sinhrks/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sinhrks/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sinhrks/subscriptions", "type": "User", "url": "https://api.github.com/users/sinhrks" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "009800", "default": false, "description": "Duplicate issue or pull request", "id": 40153326, "name": "Duplicate Report", "node_id": "MDU6TGFiZWw0MDE1MzMyNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Duplicate%20Report" }, { "color": "006b75", "default": false, "description": "Arithmetic, Comparison, and Logical operations", "id": 47223669, "name": "Numeric Operations", "node_id": "MDU6TGFiZWw0NzIyMzY2OQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Numeric%20Operations" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
1
2016-05-21T06:05:08Z
2016-05-21T18:46:03Z
2016-05-21T18:45:57Z
MEMBER
null
#### Code Sample, a copy-pastable example if possible `Timestamp` subtraction resuts in `Timedelta` ``` pd.Timestamp('2011-01-01') - pd.Timestamp('2010-01-01') # Timedelta('365 days 00:00:00') ``` But it doesn't when broadcasted to `DataFrame`. It's because `DataFrame` op calls `_try_corce_results` which coerces the result to `datetime64`. ``` df = pd.DataFrame({'a': [pd.Timestamp('2011-01-01')]}) df - pd.Timestamp('2010-01-01') # a #0 1971-01-01 ``` #### Expected Output ``` # a #0 365 days ``` #### output of `pd.show_versions()` current master
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13248/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13248/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13249
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13249/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13249/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13249/events
https://github.com/pandas-dev/pandas/pull/13249
156,102,647
MDExOlB1bGxSZXF1ZXN0NzA5NDk4NDE=
13,249
TST: check internal Categorical
{ "avatar_url": "https://avatars.githubusercontent.com/u/1696302?v=4", "events_url": "https://api.github.com/users/sinhrks/events{/privacy}", "followers_url": "https://api.github.com/users/sinhrks/followers", "following_url": "https://api.github.com/users/sinhrks/following{/other_user}", "gists_url": "https://api.github.com/users/sinhrks/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sinhrks", "id": 1696302, "login": "sinhrks", "node_id": "MDQ6VXNlcjE2OTYzMDI=", "organizations_url": "https://api.github.com/users/sinhrks/orgs", "received_events_url": "https://api.github.com/users/sinhrks/received_events", "repos_url": "https://api.github.com/users/sinhrks/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sinhrks/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sinhrks/subscriptions", "type": "User", "url": "https://api.github.com/users/sinhrks" }
[ { "color": "C4A000", "default": false, "description": "pandas testing functions or related to the test suite", "id": 127685, "name": "Testing", "node_id": "MDU6TGFiZWwxMjc2ODU=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Testing" }, { "color": "e11d21", "default": false, "description": "Categorical Data Type", "id": 78527356, "name": "Categorical", "node_id": "MDU6TGFiZWw3ODUyNzM1Ng==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Categorical" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
1
2016-05-21T13:43:29Z
2016-05-21T23:58:48Z
2016-05-21T23:58:25Z
MEMBER
null
- [x] closes #13076 - [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff`
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13249/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13249/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13249.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13249", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13249.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13249" }
https://api.github.com/repos/pandas-dev/pandas/issues/13250
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13250/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13250/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13250/events
https://github.com/pandas-dev/pandas/pull/13250
156,102,890
MDExOlB1bGxSZXF1ZXN0NzA5NDk5NDM=
13,250
TST/ERR: Add Period ops tests / fix error message
{ "avatar_url": "https://avatars.githubusercontent.com/u/1696302?v=4", "events_url": "https://api.github.com/users/sinhrks/events{/privacy}", "followers_url": "https://api.github.com/users/sinhrks/followers", "following_url": "https://api.github.com/users/sinhrks/following{/other_user}", "gists_url": "https://api.github.com/users/sinhrks/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sinhrks", "id": 1696302, "login": "sinhrks", "node_id": "MDQ6VXNlcjE2OTYzMDI=", "organizations_url": "https://api.github.com/users/sinhrks/orgs", "received_events_url": "https://api.github.com/users/sinhrks/received_events", "repos_url": "https://api.github.com/users/sinhrks/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sinhrks/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sinhrks/subscriptions", "type": "User", "url": "https://api.github.com/users/sinhrks" }
[ { "color": "C4A000", "default": false, "description": "pandas testing functions or related to the test suite", "id": 127685, "name": "Testing", "node_id": "MDU6TGFiZWwxMjc2ODU=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Testing" }, { "color": "eb6420", "default": false, "description": "Period data type", "id": 60635328, "name": "Period", "node_id": "MDU6TGFiZWw2MDYzNTMyOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Period" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
2
2016-05-21T13:48:54Z
2016-05-22T00:05:48Z
2016-05-22T00:05:22Z
MEMBER
null
- [x] related to #13242 closes #13251 - [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` This must be after #13079.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13250/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13250/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13250.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13250", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13250.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13250" }
https://api.github.com/repos/pandas-dev/pandas/issues/13251
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13251/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13251/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13251/events
https://github.com/pandas-dev/pandas/issues/13251
156,104,072
MDU6SXNzdWUxNTYxMDQwNzI=
13,251
TST: assert that IncompatibleFrequency is raise (rather than ValueError)
{ "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }
[ { "color": "C4A000", "default": false, "description": "pandas testing functions or related to the test suite", "id": 127685, "name": "Testing", "node_id": "MDU6TGFiZWwxMjc2ODU=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Testing" }, { "color": "eb6420", "default": false, "description": "Period data type", "id": 60635328, "name": "Period", "node_id": "MDU6TGFiZWw2MDYzNTMyOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Period" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
3
2016-05-21T14:16:25Z
2016-05-22T00:05:22Z
2016-05-22T00:05:22Z
CONTRIBUTOR
null
https://github.com/pydata/pandas/pull/13079#issuecomment-220780044 just need to make sure that we are raising IncompatibleFrequency as appropriate (and testing explicity for this rather than ValueError) when constructing Periods.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13251/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13251/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13252
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13252/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13252/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13252/events
https://github.com/pandas-dev/pandas/pull/13252
156,110,039
MDExOlB1bGxSZXF1ZXN0NzA5NTM2NTg=
13,252
ENH: Allow to_sql to recognize single sql type #11886
{ "avatar_url": "https://avatars.githubusercontent.com/u/4871132?v=4", "events_url": "https://api.github.com/users/RahulHP/events{/privacy}", "followers_url": "https://api.github.com/users/RahulHP/followers", "following_url": "https://api.github.com/users/RahulHP/following{/other_user}", "gists_url": "https://api.github.com/users/RahulHP/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/RahulHP", "id": 4871132, "login": "RahulHP", "node_id": "MDQ6VXNlcjQ4NzExMzI=", "organizations_url": "https://api.github.com/users/RahulHP/orgs", "received_events_url": "https://api.github.com/users/RahulHP/received_events", "repos_url": "https://api.github.com/users/RahulHP/repos", "site_admin": false, "starred_url": "https://api.github.com/users/RahulHP/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/RahulHP/subscriptions", "type": "User", "url": "https://api.github.com/users/RahulHP" }
[ { "color": "4E9A06", "default": false, "description": null, "id": 76812, "name": "Enhancement", "node_id": "MDU6TGFiZWw3NjgxMg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Enhancement" }, { "color": "5319e7", "default": false, "description": "to_sql, read_sql, read_sql_query", "id": 47232590, "name": "IO SQL", "node_id": "MDU6TGFiZWw0NzIzMjU5MA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20SQL" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 2361, "created_at": "2015-02-26T19:29:05Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1020496?v=4", "events_url": "https://api.github.com/users/jorisvandenbossche/events{/privacy}", "followers_url": "https://api.github.com/users/jorisvandenbossche/followers", "following_url": "https://api.github.com/users/jorisvandenbossche/following{/other_user}", "gists_url": "https://api.github.com/users/jorisvandenbossche/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jorisvandenbossche", "id": 1020496, "login": "jorisvandenbossche", "node_id": "MDQ6VXNlcjEwMjA0OTY=", "organizations_url": "https://api.github.com/users/jorisvandenbossche/orgs", "received_events_url": "https://api.github.com/users/jorisvandenbossche/received_events", "repos_url": "https://api.github.com/users/jorisvandenbossche/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jorisvandenbossche/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jorisvandenbossche/subscriptions", "type": "User", "url": "https://api.github.com/users/jorisvandenbossche" }, "description": "A milestone for closed or open issues for which there is no action needed (eg not a bug, just a question / discussion, nothing to resolve, wontfix, etc).\r\n\r\n", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/33", "id": 997544, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33/labels", "node_id": "MDk6TWlsZXN0b25lOTk3NTQ0", "number": 33, "open_issues": 11, "state": "open", "title": "No action", "updated_at": "2021-11-19T17:33:16Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33" }
10
2016-05-21T16:27:20Z
2016-07-11T10:18:53Z
2016-07-11T10:18:22Z
CONTRIBUTOR
null
Follow-up in https://github.com/pydata/pandas/pull/13614 --- This solves #11886 It checks whether the passed dtype variable is a dictionary. If not, it creates a new dictionary with keys as the columns of the dataframe. It then passes this dictionary to the pandasSQL_builder.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13252/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13252/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13252.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13252", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13252.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13252" }
https://api.github.com/repos/pandas-dev/pandas/issues/13253
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13253/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13253/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13253/events
https://github.com/pandas-dev/pandas/issues/13253
156,124,261
MDU6SXNzdWUxNTYxMjQyNjE=
13,253
BUG: pd.read_csv() fails when usecols contains multibyte unicode values
{ "avatar_url": "https://avatars.githubusercontent.com/u/1965378?v=4", "events_url": "https://api.github.com/users/hassanshamim/events{/privacy}", "followers_url": "https://api.github.com/users/hassanshamim/followers", "following_url": "https://api.github.com/users/hassanshamim/following{/other_user}", "gists_url": "https://api.github.com/users/hassanshamim/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/hassanshamim", "id": 1965378, "login": "hassanshamim", "node_id": "MDQ6VXNlcjE5NjUzNzg=", "organizations_url": "https://api.github.com/users/hassanshamim/orgs", "received_events_url": "https://api.github.com/users/hassanshamim/received_events", "repos_url": "https://api.github.com/users/hassanshamim/repos", "site_admin": false, "starred_url": "https://api.github.com/users/hassanshamim/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/hassanshamim/subscriptions", "type": "User", "url": "https://api.github.com/users/hassanshamim" }
[ { "color": "444444", "default": false, "description": "Unicode strings", "id": 36380025, "name": "Unicode", "node_id": "MDU6TGFiZWwzNjM4MDAyNQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Unicode" }, { "color": "5319e7", "default": false, "description": "read_csv, to_csv", "id": 47229171, "name": "IO CSV", "node_id": "MDU6TGFiZWw0NzIyOTE3MQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20CSV" } ]
closed
false
null
[]
{ "closed_at": "2019-01-26T00:51:26Z", "closed_issues": 2048, "created_at": "2018-03-29T12:00:12Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1020496?v=4", "events_url": "https://api.github.com/users/jorisvandenbossche/events{/privacy}", "followers_url": "https://api.github.com/users/jorisvandenbossche/followers", "following_url": "https://api.github.com/users/jorisvandenbossche/following{/other_user}", "gists_url": "https://api.github.com/users/jorisvandenbossche/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jorisvandenbossche", "id": 1020496, "login": "jorisvandenbossche", "node_id": "MDQ6VXNlcjEwMjA0OTY=", "organizations_url": "https://api.github.com/users/jorisvandenbossche/orgs", "received_events_url": "https://api.github.com/users/jorisvandenbossche/received_events", "repos_url": "https://api.github.com/users/jorisvandenbossche/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jorisvandenbossche/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jorisvandenbossche/subscriptions", "type": "User", "url": "https://api.github.com/users/jorisvandenbossche" }, "description": "", "due_on": "2019-01-31T08:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/55", "id": 3228419, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/55/labels", "node_id": "MDk6TWlsZXN0b25lMzIyODQxOQ==", "number": 55, "open_issues": 0, "state": "closed", "title": "0.24.0", "updated_at": "2019-01-29T07:42:40Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/55" }
3
2016-05-21T22:18:50Z
2019-01-21T14:21:32Z
2019-01-21T14:21:32Z
CONTRIBUTOR
null
See PR: #13233 and pandas/io/tests/parser/usecols.py `test_usecols_with_multibyte_unicode_characters` #### Code Sample, a copy-pastable example if possible ``` python import pandas as pd from pandas.compat import StringIO s = '''あああ,いい,ううう,ええええ 0.056674973,8,True,a 2.613230982,2,False,b 3.568935038,7,False,a ''' data = { 'あああ': { 0: 0.056674972999999997, 1: 2.6132309819999997, 2: 3.5689350380000002 }, 'いい': {0: 8, 1: 2, 2: 7} } expected = pd.DataFrame(data) df = pd.read_csv(StringIO(s), usecols=[u'あああ', u'いい']) ``` ``` >>> df = pd.read_csv(StringIO(s), usecols=[u'あああ', u'いい']) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "pandas/io/parsers.py", line 562, in parser_f return _read(filepath_or_buffer, kwds) File "pandas/io/parsers.py", line 315, in _read parser = TextFileReader(filepath_or_buffer, **kwds) File "pandas/io/parsers.py", line 645, in __init__ self._make_engine(self.engine) File "pandas/io/parsers.py", line 799, in _make_engine self._engine = CParserWrapper(self.f, **self.options) File "pandas/io/parsers.py", line 1263, in __init__ raise ValueError("Usecols do not match names.") ValueError: Usecols do not match names. >>> df = pd.read_csv(StringIO(s), usecols=[u'あああ', u'いい'], engine='python') Traceback (most recent call last): File "<stdin>", line 1, in <module> File "pandas/io/parsers.py", line 562, in parser_f return _read(filepath_or_buffer, kwds) File "pandas/io/parsers.py", line 315, in _read parser = TextFileReader(filepath_or_buffer, **kwds) File "pandas/io/parsers.py", line 645, in __init__ self._make_engine(self.engine) File "pandas/io/parsers.py", line 805, in _make_engine self._engine = klass(self.f, **self.options) File "pandas/io/parsers.py", line 1609, in __init__ self.columns, self.num_original_columns = self._infer_columns() File "pandas/io/parsers.py", line 1905, in _infer_columns columns = self._handle_usecols(columns, columns[0]) File "pandas/io/parsers.py", line 1958, in _handle_usecols col_indices.append(usecols_key.index(u)) ValueError: u'\u3042\u3042\u3042' is not in list ``` #### Expected Output ``` あああ いい 0 0.056675 8 1 2.613231 2 2 3.568935 7 ``` #### output of `pd.show_versions()` ## INSTALLED VERSIONS commit: 71f5139f14b38a1a3c1d9fd7d9219947399faec0 python: 2.7.11.final.0 python-bits: 64 OS: Darwin OS-release: 15.3.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: None LANG: en_US.UTF-8 pandas: 0.18.1+54.g71f5139.dirty nose: 1.3.7 pip: 8.1.2 setuptools: 20.7.0 Cython: 0.24 numpy: 1.11.0 scipy: None statsmodels: None xarray: None IPython: None sphinx: None patsy: None dateutil: 2.5.3 pytz: 2016.4 blosc: None bottleneck: None tables: None numexpr: None matplotlib: None openpyxl: None xlrd: None xlwt: None xlsxwriter: None lxml: None bs4: None html5lib: None httplib2: None apiclient: None sqlalchemy: None pymysql: None psycopg2: None jinja2: None boto: None pandas_datareader: None
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13253/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13253/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13254
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13254/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13254/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13254/events
https://github.com/pandas-dev/pandas/issues/13254
156,154,168
MDU6SXNzdWUxNTYxNTQxNjg=
13,254
PERF/COMPAT: use kahan summation in .rolling(..).sum()
{ "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }
[ { "color": "a10c02", "default": false, "description": "Memory or execution speed performance", "id": 8935311, "name": "Performance", "node_id": "MDU6TGFiZWw4OTM1MzEx", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Performance" }, { "color": "006b75", "default": false, "description": "Arithmetic, Comparison, and Logical operations", "id": 47223669, "name": "Numeric Operations", "node_id": "MDU6TGFiZWw0NzIyMzY2OQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Numeric%20Operations" }, { "color": "eb6420", "default": false, "description": "Non-arithmetic algos: value_counts, factorize, sorting, isin, clip, shift, diff", "id": 57296398, "name": "Algos", "node_id": "MDU6TGFiZWw1NzI5NjM5OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Algos" }, { "color": "d4c5f9", "default": false, "description": "rolling, ewma, expanding", "id": 1045950827, "name": "Window", "node_id": "MDU6TGFiZWwxMDQ1OTUwODI3", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Window" } ]
closed
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/61934744?v=4", "events_url": "https://api.github.com/users/phofl/events{/privacy}", "followers_url": "https://api.github.com/users/phofl/followers", "following_url": "https://api.github.com/users/phofl/following{/other_user}", "gists_url": "https://api.github.com/users/phofl/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/phofl", "id": 61934744, "login": "phofl", "node_id": "MDQ6VXNlcjYxOTM0NzQ0", "organizations_url": "https://api.github.com/users/phofl/orgs", "received_events_url": "https://api.github.com/users/phofl/received_events", "repos_url": "https://api.github.com/users/phofl/repos", "site_admin": false, "starred_url": "https://api.github.com/users/phofl/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/phofl/subscriptions", "type": "User", "url": "https://api.github.com/users/phofl" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/61934744?v=4", "events_url": "https://api.github.com/users/phofl/events{/privacy}", "followers_url": "https://api.github.com/users/phofl/followers", "following_url": "https://api.github.com/users/phofl/following{/other_user}", "gists_url": "https://api.github.com/users/phofl/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/phofl", "id": 61934744, "login": "phofl", "node_id": "MDQ6VXNlcjYxOTM0NzQ0", "organizations_url": "https://api.github.com/users/phofl/orgs", "received_events_url": "https://api.github.com/users/phofl/received_events", "repos_url": "https://api.github.com/users/phofl/repos", "site_admin": false, "starred_url": "https://api.github.com/users/phofl/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/phofl/subscriptions", "type": "User", "url": "https://api.github.com/users/phofl" } ]
{ "closed_at": "2020-12-26T13:57:50Z", "closed_issues": 1768, "created_at": "2020-05-29T23:47:32Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "on-merge: backport to 1.2.x", "due_on": "2020-12-15T08:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/73", "id": 5479819, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/73/labels", "node_id": "MDk6TWlsZXN0b25lNTQ3OTgxOQ==", "number": 73, "open_issues": 0, "state": "closed", "title": "1.2", "updated_at": "2021-04-13T15:46:43Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/73" }
1
2016-05-22T14:15:41Z
2020-09-15T22:20:49Z
2020-09-15T22:20:49Z
CONTRIBUTOR
null
from [mailing list](https://groups.google.com/forum/#!topic/pydata/Bl7QLr-Y5Z0) to avoid imprecision errors as the rolling computations are evaluated marginally (sliding the window and adding new / subtracting old). We tend to accumulate floating point errors. I looks like just an extra sum and subtract so I think the perf impact would be minimal. This might be able to be applied to `.rolling(..).mean()` as well. Note that `.rolling(..).std/var` already use Welford's algo for better precision. https://en.wikipedia.org/wiki/Kahan_summation_algorithm implementation from `numpy` ``` cdef double kahan_sum(double *darr, npy_intp n): cdef double c, y, t, sum cdef npy_intp i sum = darr[0] c = 0.0 for i from 1 <= i < n: y = darr[i] - c t = sum + y c = (t-sum) - y sum = t return sum ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13254/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13254/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13255
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13255/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13255/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13255/events
https://github.com/pandas-dev/pandas/issues/13255
156,181,419
MDU6SXNzdWUxNTYxODE0MTk=
13,255
df.groupby(col).resample('x') returning both unstacked or multiindex result
{ "avatar_url": "https://avatars.githubusercontent.com/u/370930?v=4", "events_url": "https://api.github.com/users/mikepqr/events{/privacy}", "followers_url": "https://api.github.com/users/mikepqr/followers", "following_url": "https://api.github.com/users/mikepqr/following{/other_user}", "gists_url": "https://api.github.com/users/mikepqr/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mikepqr", "id": 370930, "login": "mikepqr", "node_id": "MDQ6VXNlcjM3MDkzMA==", "organizations_url": "https://api.github.com/users/mikepqr/orgs", "received_events_url": "https://api.github.com/users/mikepqr/received_events", "repos_url": "https://api.github.com/users/mikepqr/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mikepqr/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mikepqr/subscriptions", "type": "User", "url": "https://api.github.com/users/mikepqr" }
[ { "color": "729FCF", "default": false, "description": null, "id": 233160, "name": "Groupby", "node_id": "MDU6TGFiZWwyMzMxNjA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Groupby" }, { "color": "207de5", "default": false, "description": "resample method", "id": 74975453, "name": "Resample", "node_id": "MDU6TGFiZWw3NDk3NTQ1Mw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Resample" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 2361, "created_at": "2015-02-26T19:29:05Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1020496?v=4", "events_url": "https://api.github.com/users/jorisvandenbossche/events{/privacy}", "followers_url": "https://api.github.com/users/jorisvandenbossche/followers", "following_url": "https://api.github.com/users/jorisvandenbossche/following{/other_user}", "gists_url": "https://api.github.com/users/jorisvandenbossche/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jorisvandenbossche", "id": 1020496, "login": "jorisvandenbossche", "node_id": "MDQ6VXNlcjEwMjA0OTY=", "organizations_url": "https://api.github.com/users/jorisvandenbossche/orgs", "received_events_url": "https://api.github.com/users/jorisvandenbossche/received_events", "repos_url": "https://api.github.com/users/jorisvandenbossche/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jorisvandenbossche/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jorisvandenbossche/subscriptions", "type": "User", "url": "https://api.github.com/users/jorisvandenbossche" }, "description": "A milestone for closed or open issues for which there is no action needed (eg not a bug, just a question / discussion, nothing to resolve, wontfix, etc).\r\n\r\n", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/33", "id": 997544, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33/labels", "node_id": "MDk6TWlsZXN0b25lOTk3NTQ0", "number": 33, "open_issues": 11, "state": "open", "title": "No action", "updated_at": "2021-11-19T17:33:16Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33" }
3
2016-05-23T00:13:47Z
2016-07-08T13:32:53Z
2016-05-23T12:20:46Z
NONE
null
``` python import pandas as pd from itertools import cycle, islice N = 4 df = pd.DataFrame(index=pd.date_range('2000', periods=N)) df['col1'] = list(islice(cycle(['A', 'B']), N)) df['col2'] = list(islice(cycle(['a', 'b', 'c']), N)) print(df) ``` returns ``` col1 col2 2000-01-01 A a 2000-01-02 B b 2000-01-03 A c 2000-01-04 B a ``` If I then do the following groupbys, lines 2 and 4 return the same result (a multiindex), but line 3 returns the result of running `.unstack` on line 1. ``` python print(df.groupby(['col1', pd.TimeGrouper('W')]).size()) # 1. unstacked print(df.groupby(['col2', pd.TimeGrouper('W')]).size()) # 2. unstacked print(df.groupby('col1').resample('W').size()) # 3. multiindex print(df.groupby('col2').resample('W').size()) # 4. unstacked ``` ``` col1 A 2000-01-02 1 2000-01-09 1 B 2000-01-02 1 2000-01-09 1 dtype: int64 col2 a 2000-01-02 1 2000-01-09 1 b 2000-01-02 1 c 2000-01-09 1 dtype: int64 2000-01-02 2000-01-09 col1 A 1 1 B 1 1 col2 a 2000-01-02 1 2000-01-09 1 b 2000-01-02 1 c 2000-01-09 1 dtype: int64 ``` This seems like an inconsistency to me, in the sense that, if 1 and 3 do not return the same result, neither should 2 and 4. Is this a bug, or is `df.groupby(col).resample('x')` supposed to behave like this, and is it supposed to behave differently to `df.groubpy[(col, pd.TimeGrouper(x)])`? Note that in `df` col1 has two groups of identical size, while col2 has unequal sized groups. I'm not sure if that's the problem, but this inconsistency goes away for some choices of `N` (e.g. all four lines above return multiindex for `N=3` and `N=24`?!) ``` python print(df.groupby('col1').size()) print(df.groupby('col2').size()) ``` ``` col1 A 2 B 2 dtype: int64 col2 a 2 b 1 c 1 dtype: int64 ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13255/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13255/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13256
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13256/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13256/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13256/events
https://github.com/pandas-dev/pandas/issues/13256
156,219,514
MDU6SXNzdWUxNTYyMTk1MTQ=
13,256
64bit read_csv with dtype problem
{ "avatar_url": "https://avatars.githubusercontent.com/u/1320172?v=4", "events_url": "https://api.github.com/users/wildwild/events{/privacy}", "followers_url": "https://api.github.com/users/wildwild/followers", "following_url": "https://api.github.com/users/wildwild/following{/other_user}", "gists_url": "https://api.github.com/users/wildwild/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/wildwild", "id": 1320172, "login": "wildwild", "node_id": "MDQ6VXNlcjEzMjAxNzI=", "organizations_url": "https://api.github.com/users/wildwild/orgs", "received_events_url": "https://api.github.com/users/wildwild/received_events", "repos_url": "https://api.github.com/users/wildwild/repos", "site_admin": false, "starred_url": "https://api.github.com/users/wildwild/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/wildwild/subscriptions", "type": "User", "url": "https://api.github.com/users/wildwild" }
[ { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" }, { "color": "0052cc", "default": false, "description": null, "id": 34444536, "name": "Usage Question", "node_id": "MDU6TGFiZWwzNDQ0NDUzNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Usage%20Question" }, { "color": "009800", "default": false, "description": "Duplicate issue or pull request", "id": 40153326, "name": "Duplicate Report", "node_id": "MDU6TGFiZWw0MDE1MzMyNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Duplicate%20Report" } ]
closed
false
null
[]
null
1
2016-05-23T07:52:07Z
2016-05-23T12:17:44Z
2016-05-23T12:17:12Z
NONE
null
#### Code Sample, a copy-pastable example if possible ``` test_str = u'1.7976931348623157e+308,1.7976931348623157e+308' ts_dbl = u'1.7976931348623157e+308' print np.float64(ts_dbl) dt={} tmpio = StringIO(test_str) market_head_list = [ "ClosePrice", "SettlementPrice"] dt['ClosePrice']=np.float64 dt['SettlementPrice']=np.float64 df =pd.read_csv(tmpio,engine = 'c',names=market_head_list,dtype=dt) ``` #### Expected Output ``` data = self._reader.read(nrows) ``` File "pandas\parser.pyx", line 805, in pandas.parser.TextReader.read (pandas\parser.c:8620) File "pandas\parser.pyx", line 827, in pandas.parser.TextReader._read_low_memory (pandas\parser.c:8876) File "pandas\parser.pyx", line 904, in pandas.parser.TextReader._read_rows (pandas\parser.c:9893) File "pandas\parser.pyx", line 1011, in pandas.parser.TextReader._convert_column_data (pandas\parser.c:11286) File "pandas\parser.pyx", line 1092, in pandas.parser.TextReader._convert_tokens (pandas\parser.c:12659) ValueError: cannot safely convert passed user dtype of <f8 for object dtyped data in column 0 #### output of `pd.show_versions()` ## INSTALLED VERSIONS commit: None python: 2.7.11.final.0 python-bits: 64 OS: Windows OS-release: 7 machine: AMD64 processor: Intel64 Family 6 Model 60 Stepping 3, GenuineIntel byteorder: little LC_ALL: None LANG: None pandas: 0.18.1 nose: 1.3.7 pip: 8.1.2 setuptools: 18.5 Cython: 0.23.4 numpy: 1.11.0 scipy: 0.16.0 statsmodels: None xarray: None IPython: 4.0.1 sphinx: 1.3.1 patsy: 0.4.0 dateutil: 2.5.3 pytz: 2015.7 blosc: None bottleneck: 1.0.0 tables: 3.2.2 numexpr: 2.5.2 matplotlib: 1.5.0 openpyxl: 2.2.6 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: 0.7.7 lxml: 3.4.4 bs4: 4.4.1 html5lib: None httplib2: None apiclient: None sqlalchemy: 1.0.9 pymysql: None psycopg2: None jinja2: 2.8 boto: 2.38.0 pandas_datareader: None
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13256/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13256/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13257
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13257/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13257/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13257/events
https://github.com/pandas-dev/pandas/issues/13257
156,247,715
MDU6SXNzdWUxNTYyNDc3MTU=
13,257
Pandas style.set_precision not working as expected
{ "avatar_url": "https://avatars.githubusercontent.com/u/17080502?v=4", "events_url": "https://api.github.com/users/Peter9192/events{/privacy}", "followers_url": "https://api.github.com/users/Peter9192/followers", "following_url": "https://api.github.com/users/Peter9192/following{/other_user}", "gists_url": "https://api.github.com/users/Peter9192/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Peter9192", "id": 17080502, "login": "Peter9192", "node_id": "MDQ6VXNlcjE3MDgwNTAy", "organizations_url": "https://api.github.com/users/Peter9192/orgs", "received_events_url": "https://api.github.com/users/Peter9192/received_events", "repos_url": "https://api.github.com/users/Peter9192/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Peter9192/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Peter9192/subscriptions", "type": "User", "url": "https://api.github.com/users/Peter9192" }
[ { "color": "ededed", "default": false, "description": "__repr__ of pandas objects, to_string", "id": 13101118, "name": "Output-Formatting", "node_id": "MDU6TGFiZWwxMzEwMTExOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Output-Formatting" }, { "color": "006b75", "default": false, "description": "read_html, to_html, Styler.apply, Styler.applymap", "id": 57395487, "name": "IO HTML", "node_id": "MDU6TGFiZWw1NzM5NTQ4Nw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20HTML" }, { "color": "0e8a16", "default": true, "description": null, "id": 717120670, "name": "good first issue", "node_id": "MDU6TGFiZWw3MTcxMjA2NzA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/good%20first%20issue" } ]
closed
false
null
[]
{ "closed_at": "2020-01-30T12:18:05Z", "closed_issues": 2207, "created_at": "2012-09-13T02:13:00Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/329591?v=4", "events_url": "https://api.github.com/users/wesm/events{/privacy}", "followers_url": "https://api.github.com/users/wesm/followers", "following_url": "https://api.github.com/users/wesm/following{/other_user}", "gists_url": "https://api.github.com/users/wesm/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/wesm", "id": 329591, "login": "wesm", "node_id": "MDQ6VXNlcjMyOTU5MQ==", "organizations_url": "https://api.github.com/users/wesm/orgs", "received_events_url": "https://api.github.com/users/wesm/received_events", "repos_url": "https://api.github.com/users/wesm/repos", "site_admin": false, "starred_url": "https://api.github.com/users/wesm/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/wesm/subscriptions", "type": "User", "url": "https://api.github.com/users/wesm" }, "description": "on-merge: backport to 1.0.x", "due_on": "2020-02-01T08:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/16", "id": 174211, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/16/labels", "node_id": "MDk6TWlsZXN0b25lMTc0MjEx", "number": 16, "open_issues": 0, "state": "closed", "title": "1.0.0", "updated_at": "2020-01-30T12:18:05Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/16" }
2
2016-05-23T10:22:41Z
2019-10-22T01:53:38Z
2019-10-22T01:53:38Z
NONE
null
I expected the following code to give me a representation of my data that is rounded or truncated to 2 decimals. ``` import pandas as pd import numpy as np df = pd.DataFrame(data = np.random.randn(4,4), columns=['A','B','C','D']) df.style.set_precision(2) ``` However, it will always return 2 digits instead, so for example, I want 2.37419 to be displayed as 2.37, but instead this code will give me 2.4. Am I overseeing something or is this a bug? Note that the following code works as I expected, but then I change a general setting whereas I would like to apply it only to the current output: ``` pd.set_option('display.precision',2) df ``` I'm using pandas version 0.18.1 in Jupyter notebook on Firefox, with python 2.7.11.final.0 and IPython 4.1.2 on 64-bits linux.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13257/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13257/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13258
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13258/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13258/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13258/events
https://github.com/pandas-dev/pandas/issues/13258
156,272,932
MDU6SXNzdWUxNTYyNzI5MzI=
13,258
COMPAT: box int/floats in __iter__
{ "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }
[ { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" }, { "color": "0052cc", "default": false, "description": "pandas objects compatability with Numpy or Python functions", "id": 76865106, "name": "Compat", "node_id": "MDU6TGFiZWw3Njg2NTEwNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Compat" } ]
closed
false
null
[]
{ "closed_at": "2017-10-28T18:54:27Z", "closed_issues": 764, "created_at": "2017-03-23T13:26:25Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2017-10-27T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/46", "id": 2406656, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/46/labels", "node_id": "MDk6TWlsZXN0b25lMjQwNjY1Ng==", "number": 46, "open_issues": 0, "state": "closed", "title": "0.21.0", "updated_at": "2018-07-08T21:53:21Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/46" }
12
2016-05-23T12:50:11Z
2017-11-14T18:36:41Z
2017-09-12T12:54:54Z
CONTRIBUTOR
null
xref #13236 as `.map` was recently clarified to box ints/floats (and all other dtypes) to python/pandas types (rather than numpy scalars). `__iter__` should do the same (it already is done for datetimelikes), need to add for int/floats. Furthermore `Series.tolist()` also returns python types (#10904) This will make it more consistent with pandas iteration strategy. We also already do this for `object` types ``` In [12]: type(list(Series([Timestamp('20130101'),Timestamp('20130101',tz='US/Eastern'),1,1.0,'foo']))[2]) Out[12]: int ``` .tolist() ``` In [3]: type(Series([1,2,3]).tolist()[2]) Out[3]: int ``` let's fix for pure types ``` In [14]: type(list(Series([1,2,3]))[2]) Out[14]: numpy.int64 ``` When solving this issue, also have to look at: - [ ] Inconsistent conversion in `to_dict` to numpy/python scalar (#14216)
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13258/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13258/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13259
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13259/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13259/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13259/events
https://github.com/pandas-dev/pandas/issues/13259
156,300,360
MDU6SXNzdWUxNTYzMDAzNjA=
13,259
DataFrame.to_csv(quoting=csv.QUOTE_NONNUMERIC) now also quotes numeric values
{ "avatar_url": "https://avatars.githubusercontent.com/u/835184?v=4", "events_url": "https://api.github.com/users/jeremywhelchel/events{/privacy}", "followers_url": "https://api.github.com/users/jeremywhelchel/followers", "following_url": "https://api.github.com/users/jeremywhelchel/following{/other_user}", "gists_url": "https://api.github.com/users/jeremywhelchel/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jeremywhelchel", "id": 835184, "login": "jeremywhelchel", "node_id": "MDQ6VXNlcjgzNTE4NA==", "organizations_url": "https://api.github.com/users/jeremywhelchel/orgs", "received_events_url": "https://api.github.com/users/jeremywhelchel/received_events", "repos_url": "https://api.github.com/users/jeremywhelchel/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jeremywhelchel/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jeremywhelchel/subscriptions", "type": "User", "url": "https://api.github.com/users/jeremywhelchel" }
[ { "color": "ededed", "default": false, "description": "__repr__ of pandas objects, to_string", "id": 13101118, "name": "Output-Formatting", "node_id": "MDU6TGFiZWwxMzEwMTExOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Output-Formatting" }, { "color": "009800", "default": false, "description": "Duplicate issue or pull request", "id": 40153326, "name": "Duplicate Report", "node_id": "MDU6TGFiZWw0MDE1MzMyNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Duplicate%20Report" }, { "color": "5319e7", "default": false, "description": "read_csv, to_csv", "id": 47229171, "name": "IO CSV", "node_id": "MDU6TGFiZWw0NzIyOTE3MQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20CSV" } ]
closed
false
null
[]
null
1
2016-05-23T15:03:09Z
2016-05-23T15:31:48Z
2016-05-23T15:31:20Z
NONE
null
Somewhere between 0.16.1 and 0.18.1, QUOTE_NONNUMERIC started also quoting numeric values unexpectedly. ``` import csv df = pandas.DataFrame({ 'c_string': ['a', 'b,c'], 'c_int': [42, numpy.nan], 'c_float': [1.0, 3.2], 'c_bool': [True, False], }) print df.to_csv(quoting=csv.QUOTE_NONNUMERIC) ``` In 0.16.1, the output was: ``` "","c_bool","c_float","c_int","c_string" 0,True,1.0,42.0,"a" 1,False,3.2,"","b,c" ``` In 0.18.1, the output is: ``` "","c_bool","c_float","c_int","c_string" 0,True,"1.0","42.0","a" 1,False,"3.2","","b,c" ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13259/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13259/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13260
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13260/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13260/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13260/events
https://github.com/pandas-dev/pandas/issues/13260
156,337,688
MDU6SXNzdWUxNTYzMzc2ODg=
13,260
DOC: Strange behavior when combining astype and loc
{ "avatar_url": "https://avatars.githubusercontent.com/u/8516338?v=4", "events_url": "https://api.github.com/users/rladeira/events{/privacy}", "followers_url": "https://api.github.com/users/rladeira/followers", "following_url": "https://api.github.com/users/rladeira/following{/other_user}", "gists_url": "https://api.github.com/users/rladeira/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/rladeira", "id": 8516338, "login": "rladeira", "node_id": "MDQ6VXNlcjg1MTYzMzg=", "organizations_url": "https://api.github.com/users/rladeira/orgs", "received_events_url": "https://api.github.com/users/rladeira/received_events", "repos_url": "https://api.github.com/users/rladeira/repos", "site_admin": false, "starred_url": "https://api.github.com/users/rladeira/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/rladeira/subscriptions", "type": "User", "url": "https://api.github.com/users/rladeira" }
[ { "color": "3465A4", "default": false, "description": null, "id": 134699, "name": "Docs", "node_id": "MDU6TGFiZWwxMzQ2OTk=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Docs" }, { "color": "0b02e1", "default": false, "description": "Related to indexing on series/frames, not to indexes themselves", "id": 2822098, "name": "Indexing", "node_id": "MDU6TGFiZWwyODIyMDk4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Indexing" }, { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 786, "created_at": "2015-01-13T10:53:19Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "Changes that would be nice to have in the next release. These issues are not blocking. They will be pushed to the next release if no one has time to fix them.", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/32", "id": 933188, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32/labels", "node_id": "MDk6TWlsZXN0b25lOTMzMTg4", "number": 32, "open_issues": 1053, "state": "open", "title": "Contributions Welcome", "updated_at": "2021-11-21T00:50:06Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32" }
4
2016-05-23T18:37:22Z
2016-05-26T18:15:44Z
2016-05-26T18:15:44Z
NONE
null
I am trying to use `astype` together with `loc` to convert just a subset of columns to a specified dtype. However, I can't understand what is actually happening. Is this the expected behavior when combining `astype` and `loc`? #### Code Sample, a copy-pastable example if possible ``` import pandas as pd import numpy as np df = pd.DataFrame({'a': [1,2,3], 'b': [4,5,6], 'c': [7, 8, 9]}) print df.loc[:, ['a', 'b']].astype(np.uint8).dtypes df.loc[:, ['a', 'b']] = df.loc[:, ['a', 'b']].astype(np.uint8) print df.dtypes ``` Output: ``` >>> df.loc[:, ['a', 'b']].astype(np.uint8).dtypes a uint8 b uint8 dtype: object >>> df.loc[:, ['a', 'b']] = df.loc[:, ['a', 'b']].astype(np.uint8) >>> df.dtypes a int64 b int64 c int64 dtype: object ``` #### Expected Output ``` >>> df.loc[:, ['a', 'b']].astype(np.uint8).dtypes a uint8 b uint8 dtype: object >>> df.loc[:, ['a', 'b']] = df.loc[:, ['a', 'b']].astype(np.uint8) >>> df.dtypes a uint8 b uint8 c int64 dtype: object ``` #### output of `pd.show_versions()` ## INSTALLED VERSIONS commit: None python: 2.7.6.final.0 python-bits: 64 OS: Linux OS-release: 4.2.0-36-generic machine: x86_64 processor: x86_64 byteorder: little LC_ALL: None LANG: en_US.UTF-8 pandas: 0.18.0 nose: None pip: 8.1.1 setuptools: 20.6.7 Cython: None numpy: 1.11.0 scipy: 0.17.0 statsmodels: None xarray: None IPython: 4.1.2 sphinx: None patsy: None dateutil: 2.5.2 pytz: 2016.3 blosc: None bottleneck: None tables: None numexpr: None matplotlib: 1.5.1 openpyxl: None xlrd: None xlwt: None xlsxwriter: None lxml: None bs4: None html5lib: None httplib2: None apiclient: None sqlalchemy: None pymysql: None psycopg2: None jinja2: 2.8 boto: None
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13260/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13260/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13261
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13261/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13261/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13261/events
https://github.com/pandas-dev/pandas/pull/13261
156,375,429
MDExOlB1bGxSZXF1ZXN0NzExMjY5NDM=
13,261
BUG: remove_unused_categories dtype coerces to int64
{ "avatar_url": "https://avatars.githubusercontent.com/u/1696302?v=4", "events_url": "https://api.github.com/users/sinhrks/events{/privacy}", "followers_url": "https://api.github.com/users/sinhrks/followers", "following_url": "https://api.github.com/users/sinhrks/following{/other_user}", "gists_url": "https://api.github.com/users/sinhrks/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sinhrks", "id": 1696302, "login": "sinhrks", "node_id": "MDQ6VXNlcjE2OTYzMDI=", "organizations_url": "https://api.github.com/users/sinhrks/orgs", "received_events_url": "https://api.github.com/users/sinhrks/received_events", "repos_url": "https://api.github.com/users/sinhrks/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sinhrks/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sinhrks/subscriptions", "type": "User", "url": "https://api.github.com/users/sinhrks" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" }, { "color": "e11d21", "default": false, "description": "Categorical Data Type", "id": 78527356, "name": "Categorical", "node_id": "MDU6TGFiZWw3ODUyNzM1Ng==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Categorical" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
1
2016-05-23T21:54:00Z
2016-05-24T13:23:41Z
2016-05-24T13:23:37Z
MEMBER
null
- [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` - [x] whatsnew entry ``` c = pd.Categorical(['a', 'b'], categories=['a', 'b', 'c']) c.codes # array([0, 1], dtype=int8) # NG, must be int8 dtype c = c.remove_unused_categories() c.codes # array([0, 1]) ``` It is because `np.unique` uses platform int for `unique_inverse` ``` np.unique(np.array([0, 3, 2, 3], dtype=np.int8), return_inverse=True) (array([0, 2, 3], dtype=int8), array([0, 2, 1, 2])) ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13261/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13261/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13261.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13261", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13261.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13261" }
https://api.github.com/repos/pandas-dev/pandas/issues/13262
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13262/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13262/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13262/events
https://github.com/pandas-dev/pandas/issues/13262
156,376,368
MDU6SXNzdWUxNTYzNzYzNjg=
13,262
ENH: Support mangle_dupe_cols=False in pd.read_csv()
{ "avatar_url": "https://avatars.githubusercontent.com/u/9273653?v=4", "events_url": "https://api.github.com/users/gfyoung/events{/privacy}", "followers_url": "https://api.github.com/users/gfyoung/followers", "following_url": "https://api.github.com/users/gfyoung/following{/other_user}", "gists_url": "https://api.github.com/users/gfyoung/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/gfyoung", "id": 9273653, "login": "gfyoung", "node_id": "MDQ6VXNlcjkyNzM2NTM=", "organizations_url": "https://api.github.com/users/gfyoung/orgs", "received_events_url": "https://api.github.com/users/gfyoung/received_events", "repos_url": "https://api.github.com/users/gfyoung/repos", "site_admin": false, "starred_url": "https://api.github.com/users/gfyoung/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gfyoung/subscriptions", "type": "User", "url": "https://api.github.com/users/gfyoung" }
[ { "color": "4E9A06", "default": false, "description": null, "id": 76812, "name": "Enhancement", "node_id": "MDU6TGFiZWw3NjgxMg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Enhancement" }, { "color": "5319e7", "default": false, "description": "read_csv, to_csv", "id": 47229171, "name": "IO CSV", "node_id": "MDU6TGFiZWw0NzIyOTE3MQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20CSV" } ]
open
false
null
[]
{ "closed_at": null, "closed_issues": 786, "created_at": "2015-01-13T10:53:19Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "Changes that would be nice to have in the next release. These issues are not blocking. They will be pushed to the next release if no one has time to fix them.", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/32", "id": 933188, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32/labels", "node_id": "MDk6TWlsZXN0b25lOTMzMTg4", "number": 32, "open_issues": 1053, "state": "open", "title": "Contributions Welcome", "updated_at": "2021-11-21T00:50:06Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32" }
9
2016-05-23T21:59:20Z
2021-08-20T18:42:44Z
null
MEMBER
null
#12935 added full support for duplicate column names (in header or in `names`) by mangling them. While this has been considered _acceptable_ by users, ideally, we would like to not have to mangle them.
{ "+1": 2, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 2, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13262/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13262/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13263
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13263/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13263/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13263/events
https://github.com/pandas-dev/pandas/pull/13263
156,376,390
MDExOlB1bGxSZXF1ZXN0NzExMjc2NjQ=
13,263
TST/CLN: remove np.assert_equal
{ "avatar_url": "https://avatars.githubusercontent.com/u/1696302?v=4", "events_url": "https://api.github.com/users/sinhrks/events{/privacy}", "followers_url": "https://api.github.com/users/sinhrks/followers", "following_url": "https://api.github.com/users/sinhrks/following{/other_user}", "gists_url": "https://api.github.com/users/sinhrks/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sinhrks", "id": 1696302, "login": "sinhrks", "node_id": "MDQ6VXNlcjE2OTYzMDI=", "organizations_url": "https://api.github.com/users/sinhrks/orgs", "received_events_url": "https://api.github.com/users/sinhrks/received_events", "repos_url": "https://api.github.com/users/sinhrks/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sinhrks/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sinhrks/subscriptions", "type": "User", "url": "https://api.github.com/users/sinhrks" }
[ { "color": "C4A000", "default": false, "description": "pandas testing functions or related to the test suite", "id": 127685, "name": "Testing", "node_id": "MDU6TGFiZWwxMjc2ODU=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Testing" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
3
2016-05-23T21:59:27Z
2016-05-26T16:11:08Z
2016-05-26T16:10:52Z
MEMBER
null
- [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` Not to use `np.testing.assert_equal`, as `assert_numpy_array_equal` is more strict to check dtypes.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13263/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13263/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13263.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13263", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13263.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13263" }
https://api.github.com/repos/pandas-dev/pandas/issues/13264
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13264/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13264/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13264/events
https://github.com/pandas-dev/pandas/pull/13264
156,378,982
MDExOlB1bGxSZXF1ZXN0NzExMjk1ODI=
13,264
TST: assert_dict_equal to check input type
{ "avatar_url": "https://avatars.githubusercontent.com/u/1696302?v=4", "events_url": "https://api.github.com/users/sinhrks/events{/privacy}", "followers_url": "https://api.github.com/users/sinhrks/followers", "following_url": "https://api.github.com/users/sinhrks/following{/other_user}", "gists_url": "https://api.github.com/users/sinhrks/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sinhrks", "id": 1696302, "login": "sinhrks", "node_id": "MDQ6VXNlcjE2OTYzMDI=", "organizations_url": "https://api.github.com/users/sinhrks/orgs", "received_events_url": "https://api.github.com/users/sinhrks/received_events", "repos_url": "https://api.github.com/users/sinhrks/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sinhrks/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sinhrks/subscriptions", "type": "User", "url": "https://api.github.com/users/sinhrks" }
[ { "color": "C4A000", "default": false, "description": "pandas testing functions or related to the test suite", "id": 127685, "name": "Testing", "node_id": "MDU6TGFiZWwxMjc2ODU=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Testing" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
2
2016-05-23T22:16:04Z
2016-05-24T01:11:42Z
2016-05-24T01:11:06Z
MEMBER
null
- [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` `assert_dict_equal` now checks input is `dict` instance. Fixed some tests which passes `Series` to it.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13264/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13264/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13264.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13264", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13264.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13264" }
https://api.github.com/repos/pandas-dev/pandas/issues/13265
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13265/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13265/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13265/events
https://github.com/pandas-dev/pandas/issues/13265
156,415,229
MDU6SXNzdWUxNTY0MTUyMjk=
13,265
pd.read_html, AttributeError: AttributeError: 'NoneType' object has no attribute 'next_element'
{ "avatar_url": "https://avatars.githubusercontent.com/u/7028933?v=4", "events_url": "https://api.github.com/users/booox/events{/privacy}", "followers_url": "https://api.github.com/users/booox/followers", "following_url": "https://api.github.com/users/booox/following{/other_user}", "gists_url": "https://api.github.com/users/booox/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/booox", "id": 7028933, "login": "booox", "node_id": "MDQ6VXNlcjcwMjg5MzM=", "organizations_url": "https://api.github.com/users/booox/orgs", "received_events_url": "https://api.github.com/users/booox/received_events", "repos_url": "https://api.github.com/users/booox/repos", "site_admin": false, "starred_url": "https://api.github.com/users/booox/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/booox/subscriptions", "type": "User", "url": "https://api.github.com/users/booox" }
[ { "color": "0052cc", "default": false, "description": null, "id": 34444536, "name": "Usage Question", "node_id": "MDU6TGFiZWwzNDQ0NDUzNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Usage%20Question" }, { "color": "006b75", "default": false, "description": "read_html, to_html, Styler.apply, Styler.applymap", "id": 57395487, "name": "IO HTML", "node_id": "MDU6TGFiZWw1NzM5NTQ4Nw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20HTML" } ]
closed
false
null
[]
null
2
2016-05-24T04:00:04Z
2016-05-26T08:02:58Z
2016-05-24T13:10:22Z
NONE
null
When I try to use `pa.read_html()` to extract data from a html page, I got some error infos. How to solve this? Thanks. #### Code ``` import pandas as pd url = 'http://data.earthquake.cn/datashare/globeEarthquake_csn.html' dfs = pd.read_html(html) dfs ``` #### Some Infos - `pd.__version__` : `u'0.18.1'` - `pd.get_option('display.encoding')`: `'UTF-8'` - webpage: `charset=gb2312` - Platform: Jupyter/notebook - Python : 2.7.6 #### Error: ``` AttributeError Traceback (most recent call last) <ipython-input-53-f541be1b6614> in <module>() 1 import pandas as pd 2 url = 'http://data.earthquake.cn/datashare/globeEarthquake_csn.html' ----> 3 dfs = pd.read_html(html) 4 dfs /usr/local/lib/python2.7/dist-packages/pandas/io/html.pyc in read_html(io, match, flavor, header, index_col, skiprows, attrs, parse_dates, tupleize_cols, thousands, encoding) 872 _validate_header_arg(header) 873 return _parse(flavor, io, match, header, index_col, skiprows, --> 874 parse_dates, tupleize_cols, thousands, attrs, encoding) /usr/local/lib/python2.7/dist-packages/pandas/io/html.pyc in _parse(flavor, io, match, header, index_col, skiprows, parse_dates, tupleize_cols, thousands, attrs, encoding) 737 738 ret = [] --> 739 for table in tables: 740 try: 741 ret.append(_data_to_frame(data=table, /usr/local/lib/python2.7/dist-packages/pandas/io/html.pyc in <genexpr>((table,)) 195 def parse_tables(self): 196 tables = self._parse_tables(self._build_doc(), self.match, self.attrs) --> 197 return (self._build_table(table) for table in tables) 198 199 def _parse_raw_data(self, rows): /usr/local/lib/python2.7/dist-packages/pandas/io/html.pyc in _build_table(self, table) 347 348 def _build_table(self, table): --> 349 header = self._parse_raw_thead(table) 350 body = self._parse_raw_tbody(table) 351 footer = self._parse_raw_tfoot(table) /usr/local/lib/python2.7/dist-packages/pandas/io/html.pyc in _parse_raw_thead(self, table) 353 354 def _parse_raw_thead(self, table): --> 355 thead = self._parse_thead(table) 356 res = [] 357 if thead: /usr/local/lib/python2.7/dist-packages/pandas/io/html.pyc in _parse_thead(self, table) 411 412 def _parse_thead(self, table): --> 413 return table.find_all('thead') 414 415 def _parse_tbody(self, table): /usr/local/lib/python2.7/dist-packages/bs4/element.pyc in find_all(self, name, attrs, recursive, text, limit, **kwargs) 1257 if not recursive: 1258 generator = self.children -> 1259 return self._find_all(name, attrs, text, limit, generator, **kwargs) 1260 findAll = find_all # BS3 1261 findChildren = find_all # BS2 /usr/local/lib/python2.7/dist-packages/bs4/element.pyc in _find_all(self, name, attrs, text, limit, generator, **kwargs) 527 if isinstance(element, Tag) 528 and element.name == name) --> 529 return ResultSet(strainer, result) 530 results = ResultSet(strainer) 531 while True: /usr/local/lib/python2.7/dist-packages/bs4/element.pyc in __init__(self, source, result) 1722 that created it.""" 1723 def __init__(self, source, result=()): -> 1724 super(ResultSet, self).__init__(result) 1725 self.source = source /usr/local/lib/python2.7/dist-packages/bs4/element.pyc in <genexpr>((element,)) 524 elif isinstance(name, basestring): 525 # Optimization to find all tags with a given name. --> 526 result = (element for element in generator 527 if isinstance(element, Tag) 528 and element.name == name) /usr/local/lib/python2.7/dist-packages/bs4/element.pyc in descendants(self) 1275 while current is not stopNode: 1276 yield current -> 1277 current = current.next_element 1278 1279 # CSS selector code AttributeError: 'NoneType' object has no attribute 'next_element' ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13265/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13265/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13266
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13266/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13266/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13266/events
https://github.com/pandas-dev/pandas/issues/13266
156,462,731
MDU6SXNzdWUxNTY0NjI3MzE=
13,266
style format setting subset loses column titles
{ "avatar_url": "https://avatars.githubusercontent.com/u/1199593?v=4", "events_url": "https://api.github.com/users/simonm3/events{/privacy}", "followers_url": "https://api.github.com/users/simonm3/followers", "following_url": "https://api.github.com/users/simonm3/following{/other_user}", "gists_url": "https://api.github.com/users/simonm3/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/simonm3", "id": 1199593, "login": "simonm3", "node_id": "MDQ6VXNlcjExOTk1OTM=", "organizations_url": "https://api.github.com/users/simonm3/orgs", "received_events_url": "https://api.github.com/users/simonm3/received_events", "repos_url": "https://api.github.com/users/simonm3/repos", "site_admin": false, "starred_url": "https://api.github.com/users/simonm3/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/simonm3/subscriptions", "type": "User", "url": "https://api.github.com/users/simonm3" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "ededed", "default": false, "description": "__repr__ of pandas objects, to_string", "id": 13101118, "name": "Output-Formatting", "node_id": "MDU6TGFiZWwxMzEwMTExOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Output-Formatting" }, { "color": "006b75", "default": false, "description": "conditional formatting using DataFrame.style", "id": 1728592794, "name": "Styler", "node_id": "MDU6TGFiZWwxNzI4NTkyNzk0", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Styler" } ]
closed
false
null
[]
null
13
2016-05-24T09:37:29Z
2021-05-05T19:21:07Z
2021-05-05T19:21:07Z
NONE
null
See example below. There is no "sex" in the styled table. ``` from IPython.display import display as d import pandas as pd df=pd.DataFrame.from_dict(dict(survived=[1,0,0,0,1,1,1,1], sex=["Male", "Female", "Male", "Female", "Male", "Female","Female", "Female" ])) table=pd.crosstab(df.survived, df.sex) table.loc["rate"] = table.iloc[-1] / table.sum() d(table) ftable = table.style.format("{:.0%}", subset=pd.IndexSlice["rate",:]) d(ftable) ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13266/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13266/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13267
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13267/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13267/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13267/events
https://github.com/pandas-dev/pandas/pull/13267
156,500,689
MDExOlB1bGxSZXF1ZXN0NzEyMTUwNjE=
13,267
BUG: Bug in selection from a HDFStore with a fixed format and start and/or stop will now return the selected range
{ "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "5319e7", "default": false, "description": "read_hdf, HDFStore", "id": 47229190, "name": "IO HDF5", "node_id": "MDU6TGFiZWw0NzIyOTE5MA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20HDF5" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
0
2016-05-24T12:58:38Z
2016-05-24T15:28:17Z
2016-05-24T15:28:17Z
CONTRIBUTOR
null
closes #8287
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13267/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13267/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13267.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13267", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13267.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13267" }
https://api.github.com/repos/pandas-dev/pandas/issues/13268
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13268/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13268/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13268/events
https://github.com/pandas-dev/pandas/issues/13268
156,506,487
MDU6SXNzdWUxNTY1MDY0ODc=
13,268
Import error: No module named 'pandas.compat.numpy'
{ "avatar_url": "https://avatars.githubusercontent.com/u/19549355?v=4", "events_url": "https://api.github.com/users/SabS99/events{/privacy}", "followers_url": "https://api.github.com/users/SabS99/followers", "following_url": "https://api.github.com/users/SabS99/following{/other_user}", "gists_url": "https://api.github.com/users/SabS99/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/SabS99", "id": 19549355, "login": "SabS99", "node_id": "MDQ6VXNlcjE5NTQ5MzU1", "organizations_url": "https://api.github.com/users/SabS99/orgs", "received_events_url": "https://api.github.com/users/SabS99/received_events", "repos_url": "https://api.github.com/users/SabS99/repos", "site_admin": false, "starred_url": "https://api.github.com/users/SabS99/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SabS99/subscriptions", "type": "User", "url": "https://api.github.com/users/SabS99" }
[ { "color": "75507B", "default": false, "description": "Library building on various platforms", "id": 129350, "name": "Build", "node_id": "MDU6TGFiZWwxMjkzNTA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Build" } ]
closed
false
null
[]
null
6
2016-05-24T13:25:38Z
2016-05-24T19:00:49Z
2016-05-24T13:32:24Z
NONE
null
Hi there! Just installed Anaconda for Windows (pandas 0.18.1, numpy 1.11.0) and cannot fix the following problem, when I am trying to import pandas: import pandas as pd Traceback (most recent call last): File "C:\Users\Username\AppData\Roaming\Python\Python35\site-packages\IPython\core\interactiveshell.py", line 2885, in run_code exec(code_obj, self.user_global_ns, self.user_ns) File "", line 1, in import pandas as pd File "C:\Program Files (x86)\JetBrains\PyCharm 2016.1.3\helpers\pydev_pydev_bundle\pydev_import_hook.py", line 21, in do_import module = self._system_import(name, args, *kwargs) File "C:\Users\Username\AppData\Roaming\Python\Python35\site-packages\pandas__init__.py", line 22, in from pandas.compat.numpy import * File "C:\Program Files (x86)\JetBrains\PyCharm 2016.1.3\helpers\pydev_pydev_bundle\pydev_import_hook.py", line 21, in do_import module = self._system_import(name, args, *kwargs) ImportError: No module named 'pandas.compat.numpy'
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13268/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13268/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13269
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13269/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13269/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13269/events
https://github.com/pandas-dev/pandas/issues/13269
156,538,001
MDU6SXNzdWUxNTY1MzgwMDE=
13,269
Dividing Time-series
{ "avatar_url": "https://avatars.githubusercontent.com/u/140123?v=4", "events_url": "https://api.github.com/users/fccoelho/events{/privacy}", "followers_url": "https://api.github.com/users/fccoelho/followers", "following_url": "https://api.github.com/users/fccoelho/following{/other_user}", "gists_url": "https://api.github.com/users/fccoelho/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/fccoelho", "id": 140123, "login": "fccoelho", "node_id": "MDQ6VXNlcjE0MDEyMw==", "organizations_url": "https://api.github.com/users/fccoelho/orgs", "received_events_url": "https://api.github.com/users/fccoelho/received_events", "repos_url": "https://api.github.com/users/fccoelho/repos", "site_admin": false, "starred_url": "https://api.github.com/users/fccoelho/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/fccoelho/subscriptions", "type": "User", "url": "https://api.github.com/users/fccoelho" }
[ { "color": "0052cc", "default": false, "description": null, "id": 34444536, "name": "Usage Question", "node_id": "MDU6TGFiZWwzNDQ0NDUzNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Usage%20Question" } ]
closed
false
null
[]
null
1
2016-05-24T15:28:55Z
2016-05-24T15:31:46Z
2016-05-24T15:31:34Z
NONE
null
Dividing time-series does not work as expected; #### Code Sample, a copy-pastable example if possible ``` python ts1 = pd.TimeSeries(range(10)) ts2 = pd.TimeSeries(range(10)) ts1[1:]/ts2[:-1] ``` the output of this operation is: ``` 0 NaN 1 1.0 2 1.0 3 1.0 4 1.0 5 1.0 6 1.0 7 1.0 8 1.0 9 NaN ``` #### Expected Output What I expected is the same as the division of two `np.ndarray`s ``` python ts1.values[1:]/ts2.values[:-1] ``` array([ inf, 2. , 1.5 , 1.33333333, 1.25 , 1.2 , 1.16666667, 1.14285714, 1.125 ]) #### output of `pd.show_versions()` ## INSTALLED VERSIONS commit: None python: 3.5.1.final.0 python-bits: 64 OS: Linux OS-release: 4.2.0-12-generic machine: x86_64 processor: x86_64 byteorder: little LC_ALL: None LANG: pt_BR.UTF-8 pandas: 0.18.1 nose: 1.2.1 pip: 8.1.2 setuptools: 20.1.1 Cython: 0.24 numpy: 1.11.0 scipy: 0.17.1 statsmodels: 0.6.1 xarray: None IPython: 4.2.0 sphinx: 1.3.5 patsy: 0.4.1 dateutil: 2.5.3 pytz: 2016.4 blosc: None bottleneck: None tables: None numexpr: None matplotlib: 1.5.1 openpyxl: None xlrd: 0.9.4 xlwt: None xlsxwriter: 0.7.3 lxml: None bs4: 4.4.1 html5lib: 0.999 httplib2: 0.9.1 apiclient: None sqlalchemy: 1.0.12 pymysql: 0.7.2.None psycopg2: 2.6.1 (dt dec pq3 ext lo64) jinja2: 2.8 boto: 2.39.0 pandas_datareader: None
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13269/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13269/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13270
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13270/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13270/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13270/events
https://github.com/pandas-dev/pandas/pull/13270
156,538,610
MDExOlB1bGxSZXF1ZXN0NzEyNDE5ODg=
13,270
DOC: fixed typos in GroupBy document
{ "avatar_url": "https://avatars.githubusercontent.com/u/1642081?v=4", "events_url": "https://api.github.com/users/mortada/events{/privacy}", "followers_url": "https://api.github.com/users/mortada/followers", "following_url": "https://api.github.com/users/mortada/following{/other_user}", "gists_url": "https://api.github.com/users/mortada/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mortada", "id": 1642081, "login": "mortada", "node_id": "MDQ6VXNlcjE2NDIwODE=", "organizations_url": "https://api.github.com/users/mortada/orgs", "received_events_url": "https://api.github.com/users/mortada/received_events", "repos_url": "https://api.github.com/users/mortada/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mortada/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mortada/subscriptions", "type": "User", "url": "https://api.github.com/users/mortada" }
[ { "color": "3465A4", "default": false, "description": null, "id": 134699, "name": "Docs", "node_id": "MDU6TGFiZWwxMzQ2OTk=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Docs" }, { "color": "729FCF", "default": false, "description": null, "id": 233160, "name": "Groupby", "node_id": "MDU6TGFiZWwyMzMxNjA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Groupby" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
1
2016-05-24T15:31:39Z
2016-05-24T15:35:02Z
2016-05-24T15:34:58Z
CONTRIBUTOR
null
- [ ] closes #xxxx - [ ] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` - [ ] whatsnew entry
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13270/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13270/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13270.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13270", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13270.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13270" }
https://api.github.com/repos/pandas-dev/pandas/issues/13271
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13271/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13271/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13271/events
https://github.com/pandas-dev/pandas/issues/13271
156,542,874
MDU6SXNzdWUxNTY1NDI4NzQ=
13,271
DOC: groupby by indexer to 'resample' data
{ "avatar_url": "https://avatars.githubusercontent.com/u/13205162?v=4", "events_url": "https://api.github.com/users/tomchor/events{/privacy}", "followers_url": "https://api.github.com/users/tomchor/followers", "following_url": "https://api.github.com/users/tomchor/following{/other_user}", "gists_url": "https://api.github.com/users/tomchor/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/tomchor", "id": 13205162, "login": "tomchor", "node_id": "MDQ6VXNlcjEzMjA1MTYy", "organizations_url": "https://api.github.com/users/tomchor/orgs", "received_events_url": "https://api.github.com/users/tomchor/received_events", "repos_url": "https://api.github.com/users/tomchor/repos", "site_admin": false, "starred_url": "https://api.github.com/users/tomchor/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tomchor/subscriptions", "type": "User", "url": "https://api.github.com/users/tomchor" }
[ { "color": "3465A4", "default": false, "description": null, "id": 134699, "name": "Docs", "node_id": "MDU6TGFiZWwxMzQ2OTk=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Docs" }, { "color": "729FCF", "default": false, "description": null, "id": 233160, "name": "Groupby", "node_id": "MDU6TGFiZWwyMzMxNjA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Groupby" }, { "color": "0052cc", "default": false, "description": null, "id": 34444536, "name": "Usage Question", "node_id": "MDU6TGFiZWwzNDQ0NDUzNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Usage%20Question" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
7
2016-05-24T15:48:30Z
2016-06-28T22:23:50Z
2016-06-28T22:18:02Z
NONE
null
Related to [this question](http://stackoverflow.com/questions/37396264/pandas-equivalent-of-resample-for-integer-index). I would like to propose either to expand `.resample` to work on indexes that are integers or to create another method that does the same thing (maybe more general `.upsample` and `.downsample` methods). If it was implemented as an expansion of resample I imagine something like: ``` df = pd.DataFrame(np.random.randn(10,2)) df.resample(5, np.std) ``` Which would produce: ``` python 0 1 0 1.184582 0.492113 5 0.533134 0.982562 ``` which is a pretty forward downsample case. For upsampling maybe some discussion is needed on how to return the indexes. This should be simple to program and I think it would be a very useful shortcut.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13271/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13271/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13272
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13272/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13272/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13272/events
https://github.com/pandas-dev/pandas/pull/13272
156,575,845
MDExOlB1bGxSZXF1ZXN0NzEyNjg1MDQ=
13,272
ENH: support decimal argument in read_html #12907
{ "avatar_url": "https://avatars.githubusercontent.com/u/1499184?v=4", "events_url": "https://api.github.com/users/camilocot/events{/privacy}", "followers_url": "https://api.github.com/users/camilocot/followers", "following_url": "https://api.github.com/users/camilocot/following{/other_user}", "gists_url": "https://api.github.com/users/camilocot/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/camilocot", "id": 1499184, "login": "camilocot", "node_id": "MDQ6VXNlcjE0OTkxODQ=", "organizations_url": "https://api.github.com/users/camilocot/orgs", "received_events_url": "https://api.github.com/users/camilocot/received_events", "repos_url": "https://api.github.com/users/camilocot/repos", "site_admin": false, "starred_url": "https://api.github.com/users/camilocot/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/camilocot/subscriptions", "type": "User", "url": "https://api.github.com/users/camilocot" }
[ { "color": "4E9A06", "default": false, "description": null, "id": 76812, "name": "Enhancement", "node_id": "MDU6TGFiZWw3NjgxMg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Enhancement" }, { "color": "006b75", "default": false, "description": "read_html, to_html, Styler.apply, Styler.applymap", "id": 57395487, "name": "IO HTML", "node_id": "MDU6TGFiZWw1NzM5NTQ4Nw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20HTML" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
4
2016-05-24T18:21:48Z
2016-05-27T00:15:42Z
2016-05-27T00:15:29Z
CONTRIBUTOR
null
- [x] closes #12907 - [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` - [x] whatsnew entry
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13272/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13272/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13272.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13272", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13272.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13272" }
https://api.github.com/repos/pandas-dev/pandas/issues/13273
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13273/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13273/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13273/events
https://github.com/pandas-dev/pandas/pull/13273
156,598,798
MDExOlB1bGxSZXF1ZXN0NzEyODUwODc=
13,273
improves usability of style calls on axis=1 by automatically creating…
{ "avatar_url": "https://avatars.githubusercontent.com/u/2051736?v=4", "events_url": "https://api.github.com/users/perryvais/events{/privacy}", "followers_url": "https://api.github.com/users/perryvais/followers", "following_url": "https://api.github.com/users/perryvais/following{/other_user}", "gists_url": "https://api.github.com/users/perryvais/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/perryvais", "id": 2051736, "login": "perryvais", "node_id": "MDQ6VXNlcjIwNTE3MzY=", "organizations_url": "https://api.github.com/users/perryvais/orgs", "received_events_url": "https://api.github.com/users/perryvais/received_events", "repos_url": "https://api.github.com/users/perryvais/repos", "site_admin": false, "starred_url": "https://api.github.com/users/perryvais/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/perryvais/subscriptions", "type": "User", "url": "https://api.github.com/users/perryvais" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "ededed", "default": false, "description": "__repr__ of pandas objects, to_string", "id": 13101118, "name": "Output-Formatting", "node_id": "MDU6TGFiZWwxMzEwMTExOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Output-Formatting" } ]
closed
false
null
[]
null
15
2016-05-24T20:14:54Z
2017-03-28T00:00:26Z
2017-03-28T00:00:26Z
NONE
null
- [ ] closes #xxxx - [ ] tests added / passed - [ ] passes `git diff upstream/master | flake8 --diff` - [ ] whatsnew entry … the IndexSlice same as it does for axis=1 ``` df = pd.DataFrame(index = ['x', 'y', 'z']) df['a'] = [1,2,3] df['b'] = [4,5,6] df['c'] = [7,8,9] df df.style.background_gradient(subset='x', axis=1) ``` # otherwise this throws some vague exception. seems like if you pass in axis this should just work `df.style.background_gradient(subset=pd.IndexSlice['x',], axis=1)` #same as this
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 1, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13273/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13273/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13273.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13273", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13273.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13273" }
https://api.github.com/repos/pandas-dev/pandas/issues/13274
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13274/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13274/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13274/events
https://github.com/pandas-dev/pandas/pull/13274
156,631,375
MDExOlB1bGxSZXF1ZXN0NzEzMDkwMDM=
13,274
BUG, ENH: Improve infinity parsing for read_csv
{ "avatar_url": "https://avatars.githubusercontent.com/u/9273653?v=4", "events_url": "https://api.github.com/users/gfyoung/events{/privacy}", "followers_url": "https://api.github.com/users/gfyoung/followers", "following_url": "https://api.github.com/users/gfyoung/following{/other_user}", "gists_url": "https://api.github.com/users/gfyoung/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/gfyoung", "id": 9273653, "login": "gfyoung", "node_id": "MDQ6VXNlcjkyNzM2NTM=", "organizations_url": "https://api.github.com/users/gfyoung/orgs", "received_events_url": "https://api.github.com/users/gfyoung/received_events", "repos_url": "https://api.github.com/users/gfyoung/repos", "site_admin": false, "starred_url": "https://api.github.com/users/gfyoung/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gfyoung/subscriptions", "type": "User", "url": "https://api.github.com/users/gfyoung" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "5319e7", "default": false, "description": "read_csv, to_csv", "id": 47229171, "name": "IO CSV", "node_id": "MDU6TGFiZWw0NzIyOTE3MQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20CSV" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
11
2016-05-24T23:24:22Z
2016-05-25T19:26:55Z
2016-05-25T17:32:03Z
MEMBER
null
1) Allow mixed-case infinity strings for the Python engine Bug was traced back via `lib.maybe_convert_numeric` to the `floatify` function in `pandas/src/parse_helper.h`. In addition to correcting the bug and adding tests for it, this PR also moves the `test_inf_parsing` test from `c_parser_only.py` to `common.py` in the `pandas/io/tests/parser` dir. 2) Interpret `+inf` as positive infinity for both engines `float('+inf')` in Python is interpreted as positive infinity, so we should allow it too in parsing.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13274/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13274/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13274.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13274", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13274.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13274" }
https://api.github.com/repos/pandas-dev/pandas/issues/13275
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13275/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13275/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13275/events
https://github.com/pandas-dev/pandas/pull/13275
156,649,309
MDExOlB1bGxSZXF1ZXN0NzEzMjEyMDA=
13,275
BUG: Properly validate and parse nrows in read_csv
{ "avatar_url": "https://avatars.githubusercontent.com/u/9273653?v=4", "events_url": "https://api.github.com/users/gfyoung/events{/privacy}", "followers_url": "https://api.github.com/users/gfyoung/followers", "following_url": "https://api.github.com/users/gfyoung/following{/other_user}", "gists_url": "https://api.github.com/users/gfyoung/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/gfyoung", "id": 9273653, "login": "gfyoung", "node_id": "MDQ6VXNlcjkyNzM2NTM=", "organizations_url": "https://api.github.com/users/gfyoung/orgs", "received_events_url": "https://api.github.com/users/gfyoung/received_events", "repos_url": "https://api.github.com/users/gfyoung/repos", "site_admin": false, "starred_url": "https://api.github.com/users/gfyoung/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gfyoung/subscriptions", "type": "User", "url": "https://api.github.com/users/gfyoung" }
[ { "color": "ffa0ff", "default": false, "description": "Incorrect or improved errors from pandas", "id": 42670965, "name": "Error Reporting", "node_id": "MDU6TGFiZWw0MjY3MDk2NQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Error%20Reporting" }, { "color": "5319e7", "default": false, "description": "read_csv, to_csv", "id": 47229171, "name": "IO CSV", "node_id": "MDU6TGFiZWw0NzIyOTE3MQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20CSV" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
2
2016-05-25T02:20:41Z
2016-05-25T12:09:28Z
2016-05-25T12:09:25Z
MEMBER
null
1) Allows `float` values for `nrows` for the Python engine 2) Prevents abuse of the `nrows` argument for the CParser (e.g. you can passing `nrows=1.2`) Closes #10476.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13275/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13275/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13275.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13275", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13275.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13275" }
https://api.github.com/repos/pandas-dev/pandas/issues/13276
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13276/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13276/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13276/events
https://github.com/pandas-dev/pandas/pull/13276
156,658,645
MDExOlB1bGxSZXF1ZXN0NzEzMjc0Mzg=
13,276
DOC: Added additional example for groupby by indexer.
{ "avatar_url": "https://avatars.githubusercontent.com/u/10297394?v=4", "events_url": "https://api.github.com/users/pfrcks/events{/privacy}", "followers_url": "https://api.github.com/users/pfrcks/followers", "following_url": "https://api.github.com/users/pfrcks/following{/other_user}", "gists_url": "https://api.github.com/users/pfrcks/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pfrcks", "id": 10297394, "login": "pfrcks", "node_id": "MDQ6VXNlcjEwMjk3Mzk0", "organizations_url": "https://api.github.com/users/pfrcks/orgs", "received_events_url": "https://api.github.com/users/pfrcks/received_events", "repos_url": "https://api.github.com/users/pfrcks/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pfrcks/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pfrcks/subscriptions", "type": "User", "url": "https://api.github.com/users/pfrcks" }
[ { "color": "3465A4", "default": false, "description": null, "id": 134699, "name": "Docs", "node_id": "MDU6TGFiZWwxMzQ2OTk=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Docs" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
6
2016-05-25T04:01:05Z
2016-06-28T22:23:40Z
2016-06-28T22:18:03Z
CONTRIBUTOR
null
- [x] closes #13271 - [ ] tests added / passed - [ ] passes `git diff upstream/master | flake8 --diff` - [ ] whatsnew entry
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13276/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13276/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13276.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13276", "merged_at": "2016-06-28T22:18:02Z", "patch_url": "https://github.com/pandas-dev/pandas/pull/13276.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13276" }
https://api.github.com/repos/pandas-dev/pandas/issues/13277
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13277/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13277/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13277/events
https://github.com/pandas-dev/pandas/pull/13277
156,659,232
MDExOlB1bGxSZXF1ZXN0NzEzMjc4MjU=
13,277
clean up PeriodIndex constructor
{ "avatar_url": "https://avatars.githubusercontent.com/u/5635139?v=4", "events_url": "https://api.github.com/users/max-sixty/events{/privacy}", "followers_url": "https://api.github.com/users/max-sixty/followers", "following_url": "https://api.github.com/users/max-sixty/following{/other_user}", "gists_url": "https://api.github.com/users/max-sixty/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/max-sixty", "id": 5635139, "login": "max-sixty", "node_id": "MDQ6VXNlcjU2MzUxMzk=", "organizations_url": "https://api.github.com/users/max-sixty/orgs", "received_events_url": "https://api.github.com/users/max-sixty/received_events", "repos_url": "https://api.github.com/users/max-sixty/repos", "site_admin": false, "starred_url": "https://api.github.com/users/max-sixty/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/max-sixty/subscriptions", "type": "User", "url": "https://api.github.com/users/max-sixty" }
[ { "color": "eb6420", "default": false, "description": "Period data type", "id": 60635328, "name": "Period", "node_id": "MDU6TGFiZWw2MDYzNTMyOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Period" }, { "color": "0052cc", "default": false, "description": "pandas objects compatability with Numpy or Python functions", "id": 76865106, "name": "Compat", "node_id": "MDU6TGFiZWw3Njg2NTEwNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Compat" } ]
closed
false
null
[]
{ "closed_at": "2017-05-06T10:20:19Z", "closed_issues": 987, "created_at": "2016-02-08T15:30:21Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "after 0.19.x series", "due_on": "2017-05-12T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/39", "id": 1570595, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/39/labels", "node_id": "MDk6TWlsZXN0b25lMTU3MDU5NQ==", "number": 39, "open_issues": 0, "state": "closed", "title": "0.20.0", "updated_at": "2018-10-28T08:18:42Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/39" }
33
2016-05-25T04:08:22Z
2017-03-04T21:16:03Z
2017-03-04T21:15:37Z
CONTRIBUTOR
null
- [x] closes #13232 - [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` - [x] whatsnew entry Material clean up of PeriodIndex constructor, which was doing a few weird things (https://github.com/pydata/pandas/issues/13232#issuecomment-220788816), and generally getting messy.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13277/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13277/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13277.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13277", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13277.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13277" }
https://api.github.com/repos/pandas-dev/pandas/issues/13278
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13278/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13278/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13278/events
https://github.com/pandas-dev/pandas/pull/13278
156,662,166
MDExOlB1bGxSZXF1ZXN0NzEzMjk4MDE=
13,278
DOC: Added an example of pitfalls when using astype
{ "avatar_url": "https://avatars.githubusercontent.com/u/10297394?v=4", "events_url": "https://api.github.com/users/pfrcks/events{/privacy}", "followers_url": "https://api.github.com/users/pfrcks/followers", "following_url": "https://api.github.com/users/pfrcks/following{/other_user}", "gists_url": "https://api.github.com/users/pfrcks/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pfrcks", "id": 10297394, "login": "pfrcks", "node_id": "MDQ6VXNlcjEwMjk3Mzk0", "organizations_url": "https://api.github.com/users/pfrcks/orgs", "received_events_url": "https://api.github.com/users/pfrcks/received_events", "repos_url": "https://api.github.com/users/pfrcks/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pfrcks/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pfrcks/subscriptions", "type": "User", "url": "https://api.github.com/users/pfrcks" }
[ { "color": "3465A4", "default": false, "description": null, "id": 134699, "name": "Docs", "node_id": "MDU6TGFiZWwxMzQ2OTk=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Docs" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
7
2016-05-25T04:42:56Z
2016-05-26T18:15:56Z
2016-05-26T18:15:44Z
CONTRIBUTOR
null
- [x] closes #13260 - [ ] tests added / passed - [ ] passes `git diff upstream/master | flake8 --diff` - [ ] whatsnew entry
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13278/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13278/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13278.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13278", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13278.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13278" }
https://api.github.com/repos/pandas-dev/pandas/issues/13279
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13279/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13279/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13279/events
https://github.com/pandas-dev/pandas/issues/13279
156,694,989
MDU6SXNzdWUxNTY2OTQ5ODk=
13,279
BUG: pd.crosstab cannot handle series with the same name
{ "avatar_url": "https://avatars.githubusercontent.com/u/19567878?v=4", "events_url": "https://api.github.com/users/stefandw/events{/privacy}", "followers_url": "https://api.github.com/users/stefandw/followers", "following_url": "https://api.github.com/users/stefandw/following{/other_user}", "gists_url": "https://api.github.com/users/stefandw/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/stefandw", "id": 19567878, "login": "stefandw", "node_id": "MDQ6VXNlcjE5NTY3ODc4", "organizations_url": "https://api.github.com/users/stefandw/orgs", "received_events_url": "https://api.github.com/users/stefandw/received_events", "repos_url": "https://api.github.com/users/stefandw/repos", "site_admin": false, "starred_url": "https://api.github.com/users/stefandw/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/stefandw/subscriptions", "type": "User", "url": "https://api.github.com/users/stefandw" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "02d7e1", "default": false, "description": "Concat, Merge/Join, Stack/Unstack, Explode", "id": 13098779, "name": "Reshaping", "node_id": "MDU6TGFiZWwxMzA5ODc3OQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Reshaping" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 786, "created_at": "2015-01-13T10:53:19Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "Changes that would be nice to have in the next release. These issues are not blocking. They will be pushed to the next release if no one has time to fix them.", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/32", "id": 933188, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32/labels", "node_id": "MDk6TWlsZXN0b25lOTMzMTg4", "number": 32, "open_issues": 1053, "state": "open", "title": "Contributions Welcome", "updated_at": "2021-11-21T00:50:06Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32" }
10
2016-05-25T08:47:58Z
2017-07-30T22:54:02Z
2017-07-30T22:54:02Z
NONE
null
the following works fine > > > c = pd.Series(rand(3)) > > > pd.crosstab(c,c) however, when giving the series a name, it fails: > > > c.name='test' > > > pd.crosstab(c,c) Traceback (most recent call last): File "C:\Python35\Lib\site-packages\pandas\indexes\multi.py", line 515, in _get_level_number 'level number' % level) ValueError: The name test occurs multiple times, use a level number During handling of the above exception, another exception occurred: Traceback (most recent call last): File "<pyshell#56>", line 1, in <module> pd.crosstab(c,c) File "C:\Python35\Lib\site-packages\pandas\tools\pivot.py", line 462, in crosstab aggfunc=len, margins=margins, dropna=dropna) File "C:\Python35\Lib\site-packages\pandas\tools\pivot.py", line 127, in pivot_table table = agged.unstack(to_unstack) File "C:\Python35\Lib\site-packages\pandas\core\frame.py", line 3946, in unstack return unstack(self, level, fill_value) File "C:\Python35\Lib\site-packages\pandas\core\reshape.py", line 398, in unstack return _unstack_multiple(obj, level) File "C:\Python35\Lib\site-packages\pandas\core\reshape.py", line 252, in _unstack_multiple clocs = [index._get_level_number(i) for i in clocs] File "C:\Python35\Lib\site-packages\pandas\core\reshape.py", line 252, in <listcomp> clocs = [index._get_level_number(i) for i in clocs] File "C:\Python35\Lib\site-packages\pandas\indexes\multi.py", line 519, in _get_level_number raise KeyError('Level %s not found' % str(level)) KeyError: 'Level test not found' The use case for having series with the same name is e.g. where you want to crosstab data selected from a dataframe with a multi index. For example: c1 = mydf.xs(val1).mycolumn and c2 = mydf.xs(val2).mycolumn and then you want to do pd.crosstab(c1,c2). This will produce the error as in the simple example above.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13279/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13279/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13280
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13280/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13280/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13280/events
https://github.com/pandas-dev/pandas/issues/13280
156,703,266
MDU6SXNzdWUxNTY3MDMyNjY=
13,280
python pandas changes column value when setting with enlargement
{ "avatar_url": "https://avatars.githubusercontent.com/u/3994844?v=4", "events_url": "https://api.github.com/users/jameshume/events{/privacy}", "followers_url": "https://api.github.com/users/jameshume/followers", "following_url": "https://api.github.com/users/jameshume/following{/other_user}", "gists_url": "https://api.github.com/users/jameshume/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jameshume", "id": 3994844, "login": "jameshume", "node_id": "MDQ6VXNlcjM5OTQ4NDQ=", "organizations_url": "https://api.github.com/users/jameshume/orgs", "received_events_url": "https://api.github.com/users/jameshume/received_events", "repos_url": "https://api.github.com/users/jameshume/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jameshume/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jameshume/subscriptions", "type": "User", "url": "https://api.github.com/users/jameshume" }
[ { "color": "0b02e1", "default": false, "description": "Related to indexing on series/frames, not to indexes themselves", "id": 2822098, "name": "Indexing", "node_id": "MDU6TGFiZWwyODIyMDk4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Indexing" }, { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" }, { "color": "0052cc", "default": false, "description": null, "id": 34444536, "name": "Usage Question", "node_id": "MDU6TGFiZWwzNDQ0NDUzNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Usage%20Question" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 2361, "created_at": "2015-02-26T19:29:05Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1020496?v=4", "events_url": "https://api.github.com/users/jorisvandenbossche/events{/privacy}", "followers_url": "https://api.github.com/users/jorisvandenbossche/followers", "following_url": "https://api.github.com/users/jorisvandenbossche/following{/other_user}", "gists_url": "https://api.github.com/users/jorisvandenbossche/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jorisvandenbossche", "id": 1020496, "login": "jorisvandenbossche", "node_id": "MDQ6VXNlcjEwMjA0OTY=", "organizations_url": "https://api.github.com/users/jorisvandenbossche/orgs", "received_events_url": "https://api.github.com/users/jorisvandenbossche/received_events", "repos_url": "https://api.github.com/users/jorisvandenbossche/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jorisvandenbossche/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jorisvandenbossche/subscriptions", "type": "User", "url": "https://api.github.com/users/jorisvandenbossche" }, "description": "A milestone for closed or open issues for which there is no action needed (eg not a bug, just a question / discussion, nothing to resolve, wontfix, etc).\r\n\r\n", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/33", "id": 997544, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33/labels", "node_id": "MDk6TWlsZXN0b25lOTk3NTQ0", "number": 33, "open_issues": 11, "state": "open", "title": "No action", "updated_at": "2021-11-19T17:33:16Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33" }
1
2016-05-25T09:27:40Z
2016-05-25T11:50:25Z
2016-05-25T11:50:10Z
NONE
null
I've boiled my problem down to this example. I am running Python 2.7 on Windows 7 and using pandas 0.17.1. ``` >>> import pandas as pd >>> print pd.__version__ 0.17.1 >>> x = pd.DataFrame({"a":["james"], "b":[True], "c":["john"]}) >>> x a b c 0 james True john >>> x.loc[1] = None >>> x a b c 0 james 1 john ##<< THE TYPE HAS CHANGED 1 NaN NaN NaN >>> x.loc[1,"a"] = "james1" >>> x.loc[1,"c"] = "john1" >>> x.loc[1,"b"] = True >>> x a b c 0 james 1 john 1 james1 True john1 ## << BUT THE NEXT INSERT WAS OK >>> x.loc[2] = None ## << AND THIS DOESN'T REPLICATE THE ISSUE >>> x a b c 0 james 1 john 1 james1 True john1 2 NaN NaN NaN ``` In the above I try to add an extra row to the DF. I fill the row "by hand", so to speak, because in my actual situation I don't know all the column values yet and I might need to add an extra column so I fill in the known data first. The first enlargement however changes the `True` to a `1`. Subsequent enlargements don't have this issue. But this does mean eventually I have a DF with a column of 0's, 1's and bools, which is annoying. I've posted this on SO too: http://stackoverflow.com/questions/37431232/python-pandas-changes-column-value-when-setting-with-enlargement?noredirect=1#comment62368221_37431232 Some suggestions indicate this may well be a bug, so I'm posting it as an issue Interestingly, if I add the complete row at a time in the above example, the problem doesn't occur... ``` >>> x = pd.DataFrame({"a":["james"], "b":[True], "c":["john"]}) >>> x a b c 0 james True john >>> x.loc[1] = {"a": "james", "b" : False, "c" : "henry"} >>> x a b c 0 james True john 1 james False henry ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13280/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13280/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13281
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13281/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13281/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13281/events
https://github.com/pandas-dev/pandas/issues/13281
156,708,037
MDU6SXNzdWUxNTY3MDgwMzc=
13,281
Wrong behaviour of groupby with diff and merge
{ "avatar_url": "https://avatars.githubusercontent.com/u/19568452?v=4", "events_url": "https://api.github.com/users/rmoutie/events{/privacy}", "followers_url": "https://api.github.com/users/rmoutie/followers", "following_url": "https://api.github.com/users/rmoutie/following{/other_user}", "gists_url": "https://api.github.com/users/rmoutie/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/rmoutie", "id": 19568452, "login": "rmoutie", "node_id": "MDQ6VXNlcjE5NTY4NDUy", "organizations_url": "https://api.github.com/users/rmoutie/orgs", "received_events_url": "https://api.github.com/users/rmoutie/received_events", "repos_url": "https://api.github.com/users/rmoutie/repos", "site_admin": false, "starred_url": "https://api.github.com/users/rmoutie/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/rmoutie/subscriptions", "type": "User", "url": "https://api.github.com/users/rmoutie" }
[ { "color": "729FCF", "default": false, "description": null, "id": 233160, "name": "Groupby", "node_id": "MDU6TGFiZWwyMzMxNjA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Groupby" }, { "color": "0052cc", "default": false, "description": null, "id": 34444536, "name": "Usage Question", "node_id": "MDU6TGFiZWwzNDQ0NDUzNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Usage%20Question" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 2361, "created_at": "2015-02-26T19:29:05Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1020496?v=4", "events_url": "https://api.github.com/users/jorisvandenbossche/events{/privacy}", "followers_url": "https://api.github.com/users/jorisvandenbossche/followers", "following_url": "https://api.github.com/users/jorisvandenbossche/following{/other_user}", "gists_url": "https://api.github.com/users/jorisvandenbossche/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jorisvandenbossche", "id": 1020496, "login": "jorisvandenbossche", "node_id": "MDQ6VXNlcjEwMjA0OTY=", "organizations_url": "https://api.github.com/users/jorisvandenbossche/orgs", "received_events_url": "https://api.github.com/users/jorisvandenbossche/received_events", "repos_url": "https://api.github.com/users/jorisvandenbossche/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jorisvandenbossche/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jorisvandenbossche/subscriptions", "type": "User", "url": "https://api.github.com/users/jorisvandenbossche" }, "description": "A milestone for closed or open issues for which there is no action needed (eg not a bug, just a question / discussion, nothing to resolve, wontfix, etc).\r\n\r\n", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/33", "id": 997544, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33/labels", "node_id": "MDk6TWlsZXN0b25lOTk3NTQ0", "number": 33, "open_issues": 11, "state": "open", "title": "No action", "updated_at": "2021-11-19T17:33:16Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33" }
5
2016-05-25T09:49:49Z
2016-05-25T17:15:54Z
2016-05-25T12:00:32Z
NONE
null
While writing a piece of code similar to the example below, I stumbled on a problematic interaction between groupby, diff and merge. My debugging efforts showed that this problem is likely related to the "fast_apply" optimisation Pandas uses when using apply(). As shown below, when using string values as grouping keys, the first value encountered overrides all the others. Removing either the diff call, the merge, or replacing "a" and "b" by numerical values all solve the issue, and give a correct (albeit obviously incomplete for my purpose) result. #### Code ``` import pandas as pd import numpy as np bar = np.random.randint(0, 10, 4) foo = ['a'] * 2 + ['b'] * 2 values = zip(foo, bar) df = pd.DataFrame(values, columns=['foo', 'bar']) print df def try_diff_merge(df): df['inf_bar'] = df.bar < 6 df['inf_bar_diff'] = df['inf_bar'].diff() df_merge = df.groupby(['inf_bar']).count() df_merge.drop(['inf_bar_diff'], axis=1, inplace=True) df_merge = pd.merge(df, df_merge, how='left', right_index=True, left_on=['inf_bar']) return df_merge df_group = df.groupby(['foo']).apply(try_diff_merge) print df_group ``` #### Output ``` foo bar 0 a 2 1 a 0 2 b 6 3 b 8 foo_x bar_x inf_bar inf_bar_diff foo_y bar_y 0 a 2 True NaN 2 2 1 a 0 True False 2 2 2 a 6 False NaN 2 2 3 a 8 False False 2 2 ``` #### Expected Output ``` foo bar 0 a 2 1 a 0 2 b 6 3 b 8 foo_x bar_x inf_bar inf_bar_diff foo_y bar_y 0 a 2 True NaN 2 2 1 a 0 True False 2 2 2 b 6 False NaN 2 2 3 b 8 False False 2 2 ``` #### output of `pd.show_versions()` ``` INSTALLED VERSIONS ------------------ commit: None python: 2.7.11.final.0 python-bits: 64 OS: Windows OS-release: 7 machine: AMD64 processor: Intel64 Family 6 Model 61 Stepping 4, GenuineIntel byteorder: little LC_ALL: None LANG: None pandas: 0.18.0 nose: 1.3.7 pip: 8.1.1 setuptools: 20.3 Cython: 0.23.4 numpy: 1.10.4 scipy: 0.17.0 statsmodels: 0.6.1 xarray: None IPython: 4.1.2 sphinx: 1.3.5 patsy: 0.4.0 dateutil: 2.5.1 pytz: 2016.2 blosc: None bottleneck: 1.0.0 tables: 3.2.2 numexpr: 2.5 matplotlib: 1.5.1 openpyxl: 2.3.2 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: 0.8.4 lxml: 3.6.0 bs4: 4.4.1 html5lib: None httplib2: None apiclient: None sqlalchemy: 1.0.12 pymysql: None psycopg2: 2.6.1 (dt dec pq3 ext lo64) jinja2: 2.8 boto: 2.39.0 None ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13281/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13281/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13282
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13282/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13282/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13282/events
https://github.com/pandas-dev/pandas/issues/13282
156,710,959
MDU6SXNzdWUxNTY3MTA5NTk=
13,282
pandas.show_versions causing malloc_error_break
{ "avatar_url": "https://avatars.githubusercontent.com/u/6215361?v=4", "events_url": "https://api.github.com/users/nparley/events{/privacy}", "followers_url": "https://api.github.com/users/nparley/followers", "following_url": "https://api.github.com/users/nparley/following{/other_user}", "gists_url": "https://api.github.com/users/nparley/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nparley", "id": 6215361, "login": "nparley", "node_id": "MDQ6VXNlcjYyMTUzNjE=", "organizations_url": "https://api.github.com/users/nparley/orgs", "received_events_url": "https://api.github.com/users/nparley/received_events", "repos_url": "https://api.github.com/users/nparley/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nparley/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nparley/subscriptions", "type": "User", "url": "https://api.github.com/users/nparley" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "0052cc", "default": false, "description": "pandas objects compatability with Numpy or Python functions", "id": 76865106, "name": "Compat", "node_id": "MDU6TGFiZWw3Njg2NTEwNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Compat" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
1
2016-05-25T10:03:45Z
2016-05-25T17:35:10Z
2016-05-25T17:35:10Z
CONTRIBUTOR
null
If blosc is installed show_versions() will caused python to produce a malloc_error_break (double free) error on exiting. This can be seen in the travis runs under `source activate pandas && ci/print_versions.py` section but can also be easily replicated on Linux and Mac. The fix for this is to replace imp (which has been deprecated) with importlib. I will create and link a PR. `````` python >>> import pandas >>> pandas.show_versions() INSTALLED VERSIONS ------------------ commit: e0a2e3bc51f9e178f72c44e6de06700ee0bf31c6 python: 2.7.11.final.0 python-bits: 64 OS: Darwin OS-release: 15.5.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: None LANG: en_GB.UTF-8 pandas: 0.18.1+66.ge0a2e3b nose: 1.3.7 pip: 8.1.1 setuptools: 20.7.0 Cython: 0.24 numpy: 1.11.0 scipy: 0.17.0 statsmodels: None xarray: None IPython: 4.1.2 sphinx: None patsy: None dateutil: 2.5.2 pytz: 2016.3 blosc: 1.3.2 bottleneck: None tables: None numexpr: None matplotlib: 1.5.1 openpyxl: None xlrd: 0.9.4 xlwt: None xlsxwriter: None lxml: None bs4: None html5lib: None httplib2: None apiclient: None sqlalchemy: None pymysql: None psycopg2: None jinja2: 2.8 boto: None pandas_datareader: None``` >>> python(1726,0x7fff77074000) malloc: *** error for object 0x102573a00: pointer being freed was not allocated *** set a breakpoint in malloc_error_break to debug Abort trap: 6 ``````
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13282/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13282/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13283
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13283/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13283/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13283/events
https://github.com/pandas-dev/pandas/pull/13283
156,722,601
MDExOlB1bGxSZXF1ZXN0NzEzNzE0MDU=
13,283
Change get_dummies() to return columns of dtype=bool instead of np.float64
{ "avatar_url": "https://avatars.githubusercontent.com/u/3015410?v=4", "events_url": "https://api.github.com/users/avishaylivne/events{/privacy}", "followers_url": "https://api.github.com/users/avishaylivne/followers", "following_url": "https://api.github.com/users/avishaylivne/following{/other_user}", "gists_url": "https://api.github.com/users/avishaylivne/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/avishaylivne", "id": 3015410, "login": "avishaylivne", "node_id": "MDQ6VXNlcjMwMTU0MTA=", "organizations_url": "https://api.github.com/users/avishaylivne/orgs", "received_events_url": "https://api.github.com/users/avishaylivne/received_events", "repos_url": "https://api.github.com/users/avishaylivne/repos", "site_admin": false, "starred_url": "https://api.github.com/users/avishaylivne/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/avishaylivne/subscriptions", "type": "User", "url": "https://api.github.com/users/avishaylivne" }
[ { "color": "02d7e1", "default": false, "description": "Concat, Merge/Join, Stack/Unstack, Explode", "id": 13098779, "name": "Reshaping", "node_id": "MDU6TGFiZWwxMzA5ODc3OQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Reshaping" }, { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" }, { "color": "e11d21", "default": false, "description": "Categorical Data Type", "id": 78527356, "name": "Categorical", "node_id": "MDU6TGFiZWw3ODUyNzM1Ng==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Categorical" } ]
closed
false
null
[]
null
2
2016-05-25T11:04:47Z
2016-05-31T15:30:06Z
2016-05-31T15:30:06Z
NONE
null
- closes #8725
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13283/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13283/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13283.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13283", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13283.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13283" }
https://api.github.com/repos/pandas-dev/pandas/issues/13284
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13284/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13284/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13284/events
https://github.com/pandas-dev/pandas/pull/13284
156,754,986
MDExOlB1bGxSZXF1ZXN0NzEzOTM5NzU=
13,284
Remove imp and just use importlib to avoid memory error when importin…
{ "avatar_url": "https://avatars.githubusercontent.com/u/6215361?v=4", "events_url": "https://api.github.com/users/nparley/events{/privacy}", "followers_url": "https://api.github.com/users/nparley/followers", "following_url": "https://api.github.com/users/nparley/following{/other_user}", "gists_url": "https://api.github.com/users/nparley/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nparley", "id": 6215361, "login": "nparley", "node_id": "MDQ6VXNlcjYyMTUzNjE=", "organizations_url": "https://api.github.com/users/nparley/orgs", "received_events_url": "https://api.github.com/users/nparley/received_events", "repos_url": "https://api.github.com/users/nparley/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nparley/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nparley/subscriptions", "type": "User", "url": "https://api.github.com/users/nparley" }
[ { "color": "75507B", "default": false, "description": "Library building on various platforms", "id": 129350, "name": "Build", "node_id": "MDU6TGFiZWwxMjkzNTA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Build" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
5
2016-05-25T13:46:46Z
2016-05-25T17:35:50Z
2016-05-25T17:35:10Z
CONTRIBUTOR
null
- [ ] closes #13282 Remove imp from pandas.show_versions() to fix memory problem.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13284/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13284/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13284.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13284", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13284.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13284" }
https://api.github.com/repos/pandas-dev/pandas/issues/13285
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13285/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13285/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13285/events
https://github.com/pandas-dev/pandas/pull/13285
156,803,250
MDExOlB1bGxSZXF1ZXN0NzE0Mjg5MzQ=
13,285
COMPAT: extension dtypes (DatetimeTZ, Categorical) are now Singleton cached objects
{ "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "0052cc", "default": false, "description": "pandas objects compatability with Numpy or Python functions", "id": 76865106, "name": "Compat", "node_id": "MDU6TGFiZWw3Njg2NTEwNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Compat" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
1
2016-05-25T17:11:32Z
2016-05-26T16:13:01Z
2016-05-26T16:13:01Z
CONTRIBUTOR
null
allows for proper is / == comparisons Had this odd semantic difference as these were really different objects (though they DID hash the same) This doesn't actually affect any user code. ``` In [1]: from pandas.core import common as com In [2]: t1 = com.DatetimeTZDtype('datetime64[ns, US/Eastern]') In [3]: t2 = com.DatetimeTZDtype('datetime64[ns, US/Eastern]') In [4]: t1 == t2 Out[4]: True In [5]: t1 is t2 Out[5]: False In [6]: hash(t1) Out[6]: 5756291921003024619 In [7]: hash(t2) Out[7]: 5756291921003024619 ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13285/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13285/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13285.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13285", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13285.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13285" }
https://api.github.com/repos/pandas-dev/pandas/issues/13286
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13286/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13286/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13286/events
https://github.com/pandas-dev/pandas/issues/13286
156,812,176
MDU6SXNzdWUxNTY4MTIxNzY=
13,286
COMPAT: can we reduce pathological cases in Index comparisons
{ "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "AFEEEE", "default": false, "description": null, "id": 211840, "name": "Timeseries", "node_id": "MDU6TGFiZWwyMTE4NDA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Timeseries" }, { "color": "e99695", "default": false, "description": "Related to the Index class or subclasses", "id": 1218227310, "name": "Index", "node_id": "MDU6TGFiZWwxMjE4MjI3MzEw", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Index" }, { "color": "d4c5f9", "default": false, "description": "Series/DataFrame/Index/pd.array Constructors", "id": 1465286368, "name": "Constructors", "node_id": "MDU6TGFiZWwxNDY1Mjg2MzY4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Constructors" }, { "color": "b60205", "default": false, "description": "Internal Consistency of API/Behavior", "id": 1741841389, "name": "API - Consistency", "node_id": "MDU6TGFiZWwxNzQxODQxMzg5", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/API%20-%20Consistency" } ]
open
false
null
[]
{ "closed_at": null, "closed_issues": 786, "created_at": "2015-01-13T10:53:19Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "Changes that would be nice to have in the next release. These issues are not blocking. They will be pushed to the next release if no one has time to fix them.", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/32", "id": 933188, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32/labels", "node_id": "MDk6TWlsZXN0b25lOTMzMTg4", "number": 32, "open_issues": 1053, "state": "open", "title": "Contributions Welcome", "updated_at": "2021-11-21T00:50:06Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32" }
2
2016-05-25T17:55:40Z
2020-09-21T00:04:38Z
null
CONTRIBUTOR
null
from [SO](http://stackoverflow.com/questions/37444307/equality-of-pandas-index-objects-with-different-dtypes-and-elements/37444423#37444423) ``` In [1]: i1 = pd.DatetimeIndex(['1971-10-01'], dtype='datetime64[ns]', freq=None) In [2]: i2 = pd.Index([u'100171'], dtype='object') In [3]: i1 Out[3]: DatetimeIndex(['1971-10-01'], dtype='datetime64[ns]', freq=None) In [4]: pd.DatetimeIndex(i2) Out[4]: DatetimeIndex(['1971-10-01'], dtype='datetime64[ns]', freq=None) ``` We _might_ be able to elminate the coercion in `.equals()` in some cases.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13286/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13286/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13287
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13287/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13287/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13287/events
https://github.com/pandas-dev/pandas/issues/13287
156,844,837
MDU6SXNzdWUxNTY4NDQ4Mzc=
13,287
BUG: Pandas cannot create DataFrame from Numpy Array of TimeStamps
{ "avatar_url": "https://avatars.githubusercontent.com/u/4992803?v=4", "events_url": "https://api.github.com/users/jameskelleher/events{/privacy}", "followers_url": "https://api.github.com/users/jameskelleher/followers", "following_url": "https://api.github.com/users/jameskelleher/following{/other_user}", "gists_url": "https://api.github.com/users/jameskelleher/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jameskelleher", "id": 4992803, "login": "jameskelleher", "node_id": "MDQ6VXNlcjQ5OTI4MDM=", "organizations_url": "https://api.github.com/users/jameskelleher/orgs", "received_events_url": "https://api.github.com/users/jameskelleher/received_events", "repos_url": "https://api.github.com/users/jameskelleher/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jameskelleher/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jameskelleher/subscriptions", "type": "User", "url": "https://api.github.com/users/jameskelleher" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "AFEEEE", "default": false, "description": null, "id": 211840, "name": "Timeseries", "node_id": "MDU6TGFiZWwyMTE4NDA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Timeseries" }, { "color": "02d7e1", "default": false, "description": "Concat, Merge/Join, Stack/Unstack, Explode", "id": 13098779, "name": "Reshaping", "node_id": "MDU6TGFiZWwxMzA5ODc3OQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Reshaping" }, { "color": "5319e7", "default": false, "description": "Timedelta data type", "id": 49597148, "name": "Timedelta", "node_id": "MDU6TGFiZWw0OTU5NzE0OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Timedelta" } ]
closed
false
null
[]
{ "closed_at": "2019-07-19T00:34:29Z", "closed_issues": 1289, "created_at": "2018-10-23T02:34:15Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2019-07-01T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/61", "id": 3759483, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/61/labels", "node_id": "MDk6TWlsZXN0b25lMzc1OTQ4Mw==", "number": 61, "open_issues": 0, "state": "closed", "title": "0.25.0", "updated_at": "2020-01-02T15:10:40Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/61" }
3
2016-05-25T20:38:41Z
2019-06-27T20:39:25Z
2019-06-27T20:39:25Z
NONE
null
I have the following array of Timestamps: ``` python ts_array = np.array([[Timestamp('2016-05-02 15:50:00+0000', tz='UTC', offset='5T'), Timestamp('2016-05-02 15:50:00+0000', tz='UTC', offset='5T'), Timestamp('2016-05-02 15:50:00+0000', tz='UTC', offset='5T')], [Timestamp('2016-05-02 17:10:00+0000', tz='UTC', offset='5T'), Timestamp('2016-05-02 17:10:00+0000', tz='UTC', offset='5T'), Timestamp('2016-05-02 17:10:00+0000', tz='UTC', offset='5T')], [Timestamp('2016-05-02 20:25:00+0000', tz='UTC', offset='5T'), Timestamp('2016-05-02 20:25:00+0000', tz='UTC', offset='5T'), Timestamp('2016-05-02 20:25:00+0000', tz='UTC', offset='5T')]], dtype=object) ``` I can't create a DataFrame from this array using the DataFrame constructor: ``` python pd.DataFrame(ts_array) ``` ``` Traceback (most recent call last): File "/Users/jkelleher/anaconda/lib/python2.7/site-packages/IPython/core/interactiveshell.py", line 2885, in run_code exec(code_obj, self.user_global_ns, self.user_ns) File "<ipython-input-46-ae20c6b6248f>", line 1, in <module> pd.DataFrame(ts_array) File "/Users/jkelleher/anaconda/lib/python2.7/site-packages/pandas/core/frame.py", line 255, in __init__ copy=copy) File "/Users/jkelleher/anaconda/lib/python2.7/site-packages/pandas/core/frame.py", line 432, in _init_ndarray return create_block_manager_from_blocks([values], [columns, index]) File "/Users/jkelleher/anaconda/lib/python2.7/site-packages/pandas/core/internals.py", line 3986, in create_block_manager_from_blocks mgr = BlockManager(blocks, axes) File "/Users/jkelleher/anaconda/lib/python2.7/site-packages/pandas/core/internals.py", line 2591, in __init__ (block.ndim, self.ndim)) AssertionError: Number of Block dimensions (1) must equal number of axes (2) ``` I can create the DataFrame from the array using `from_records`: ``` python ts_df = pd.DataFrame.from_records(ts_array) ``` However, when I attempt to transpose this DataFrame, I wind up with the same `AssertionError` as before. ``` AssertionError: Number of Block dimensions (1) must equal number of axes (2) ``` If I convert the Timestamps to Datetimes, the error persists. I can, however, convert the Timestamps to Datetime64 objects, and this fixes the problem. ``` python dt64_array = np.array([[ts.to_datetime64() for ts in sublist] for sublist in ts_array]) pd.DataFrame(dt64_array) ``` ``` Out[56]: 0 1 2 0 2016-05-02 15:50:00 2016-05-02 15:50:00 2016-05-02 15:50:00 1 2016-05-02 17:10:00 2016-05-02 17:10:00 2016-05-02 17:10:00 2 2016-05-02 20:25:00 2016-05-02 20:25:00 2016-05-02 20:25:00 ``` ``` python pd.DataFrame(dt64_array).transpose() ``` ``` Out[57]: 0 1 2 0 2016-05-02 15:50:00 2016-05-02 17:10:00 2016-05-02 20:25:00 1 2016-05-02 15:50:00 2016-05-02 17:10:00 2016-05-02 20:25:00 2 2016-05-02 15:50:00 2016-05-02 17:10:00 2016-05-02 20:25:00 ``` Though I found a suitable workaround, I feel like pandas should be able to construct and operate on DataFrames of Timestamps as easily as other other objects. #### output of `pd.show_versions()` ``` INSTALLED VERSIONS ------------------ commit: None python: 2.7.11.final.0 python-bits: 64 OS: Darwin OS-release: 15.5.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: None LANG: None pandas: 0.18.1 nose: 1.3.7 pip: 8.1.2 setuptools: 20.3 Cython: 0.24 numpy: 1.11.0 scipy: 0.17.1 statsmodels: 0.8.0.dev0+970e99e xarray: None IPython: 4.1.2 sphinx: 1.3.5 patsy: 0.4.0 dateutil: 2.5.3 pytz: 2016.4 blosc: None bottleneck: 1.0.0 tables: 3.2.2 numexpr: 2.5 matplotlib: 1.5.1 openpyxl: 2.3.2 xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: 0.8.4 lxml: 3.6.0 bs4: 4.4.1 html5lib: None httplib2: None apiclient: None sqlalchemy: 1.0.12 pymysql: None psycopg2: None jinja2: 2.8 boto: 2.39.0 pandas_datareader: None ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13287/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13287/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13288
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13288/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13288/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13288/events
https://github.com/pandas-dev/pandas/issues/13288
156,863,011
MDU6SXNzdWUxNTY4NjMwMTE=
13,288
BUG: DataFrame.describe() breaks with a column index of object type and numeric entries
{ "avatar_url": "https://avatars.githubusercontent.com/u/9507544?v=4", "events_url": "https://api.github.com/users/pijucha/events{/privacy}", "followers_url": "https://api.github.com/users/pijucha/followers", "following_url": "https://api.github.com/users/pijucha/following{/other_user}", "gists_url": "https://api.github.com/users/pijucha/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pijucha", "id": 9507544, "login": "pijucha", "node_id": "MDQ6VXNlcjk1MDc1NDQ=", "organizations_url": "https://api.github.com/users/pijucha/orgs", "received_events_url": "https://api.github.com/users/pijucha/received_events", "repos_url": "https://api.github.com/users/pijucha/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pijucha/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pijucha/subscriptions", "type": "User", "url": "https://api.github.com/users/pijucha" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
7
2016-05-25T22:17:16Z
2016-05-31T14:12:51Z
2016-05-31T14:12:51Z
CONTRIBUTOR
null
Preparing a commit for another issue in `.describe()`, I encountered this puzzling bug, surprisingly easy to trigger. #### Symptoms ``` python df = pd.DataFrame({'A': list("BCDE"), 0: [1,2,3,4]}) df.describe() # Long traceback listing formatting and internal functions... ValueError: Buffer dtype mismatch, expected 'Python object' but got 'long' ``` However: ``` python df.describe(include='all') 0 A count 4.000000 4 unique NaN 4 top NaN D freq NaN 1 mean 2.500000 NaN std 1.290994 NaN min 1.000000 NaN 25% 1.750000 NaN 50% 2.500000 NaN 75% 3.250000 NaN max 4.000000 NaN # It's OK if we don't print on screen: x = df.describe() x.columns Out[8]: Index([0], dtype='int64') # Fixing this suspicious index (int works too): x.columns = x.columns.astype(object) x Out[10]: 0 count 4.000000 mean 2.500000 std 1.290994 min 1.000000 25% 1.750000 50% 2.500000 75% 3.250000 max 4.000000 ``` Same issue happens with a simpler data frame: ``` python df0 = pd.DataFrame([1,2,3,4]) # It's OK now df0.describe() Out[28]: 0 count 4.000000 mean 2.500000 std 1.290994 min 1.000000 25% 1.750000 50% 2.500000 75% 3.250000 max 4.000000 # Modify column index: df0.columns = pd.Index([0], dtype=object) df0.describe() # ... ValueError: Buffer dtype mismatch, expected 'Python object' but got 'long' ``` Current version (but the bug is also present in pandas release 0.18.1): ``` pd.show_versions() INSTALLED VERSIONS ------------------ commit: None python: 3.5.1.final.0 python-bits: 64 OS: Linux OS-release: 4.1.20-1 machine: x86_64 processor: Intel(R)_Core(TM)_i5-2520M_CPU_@_2.50GHz byteorder: little LC_ALL: None LANG: en_US.UTF-8 pandas: 0.18.1+64.g7ed22fe.dirty nose: 1.3.7 pip: 8.1.2 setuptools: 21.0.0 Cython: 0.24 numpy: 1.11.0 scipy: 0.17.0.dev0+3f3c371 IPython: 4.0.1 ... ``` #### Reason Some internal function gets confused by dtypes of a column index, I guess. But the faulty index is created in `.describe()`. ``` python # Output from %debug df.describe() # NDFrame.describe() in pandas/core/generic.py: # 4943 data = self 4944 else: 4945 data = self.select_dtypes(include=include, exclude=exclude) 4946 4947 ldesc = [describe_1d(s, percentiles) for _, s in data.iteritems()] 4948 # set a convenient order for rows 4949 names = [] 4950 ldesc_indexes = sorted([x.index for x in ldesc], key=len) 4951 for idxnames in ldesc_indexes: 4952 for name in idxnames: 4953 if name not in names: 4954 names.append(name) 4955 4956 d = pd.concat(ldesc, join_axes=pd.Index([names]), axis=1) 1> 4957 d.columns = self.columns._shallow_copy(values=d.columns.values) 4958 d.columns.names = data.columns.names 4959 return d ``` `_shallow_copy()` in the marked line changes `d.columns`: ``` python ipdb> p d.columns Int64Index([0], dtype='int64') ipdb> n > /home/users/piotr/workspace/pandas-pijucha/pandas/core/generic.py(4958)describe() 1 4957 d.columns = self.columns._shallow_copy(values=d.columns.values) -> 4958 d.columns.names = data.columns.names 4959 return d ipdb> p d.columns Index([0], dtype='int64') ``` #### Possible solutions Lines 4957-4958 are actually used to fix issues that `pd.concat` brings about. They try to pass the column structure from `self` to `d`. I think a simpler solution is replacing these lines with: ``` python d = pd.concat(ldesc, join_axes=pd.Index([names]), axis=1) d.columns = data.columns return d ``` or ``` python d = pd.DataFrame(pd.concat(ldesc, axis=1), index = pd.Index(names), columns = data.columns) return d ``` `data` is a subframe of `self` and retains the same column structure. `pd.concat` has some parameters that help pass a hierarchical index but can't do anything on its own with a categorical one. I'm going to submit a pull request with this fix together with some others related with `describe()`. I hope I haven't overlooked anything obvious. But if so, any comments are very welcome.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13288/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13288/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13289
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13289/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13289/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13289/events
https://github.com/pandas-dev/pandas/issues/13289
156,918,133
MDU6SXNzdWUxNTY5MTgxMzM=
13,289
defining min_itemsize creates "data_columns"
{ "avatar_url": "https://avatars.githubusercontent.com/u/2927161?v=4", "events_url": "https://api.github.com/users/cchrysostomou/events{/privacy}", "followers_url": "https://api.github.com/users/cchrysostomou/followers", "following_url": "https://api.github.com/users/cchrysostomou/following{/other_user}", "gists_url": "https://api.github.com/users/cchrysostomou/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/cchrysostomou", "id": 2927161, "login": "cchrysostomou", "node_id": "MDQ6VXNlcjI5MjcxNjE=", "organizations_url": "https://api.github.com/users/cchrysostomou/orgs", "received_events_url": "https://api.github.com/users/cchrysostomou/received_events", "repos_url": "https://api.github.com/users/cchrysostomou/repos", "site_admin": false, "starred_url": "https://api.github.com/users/cchrysostomou/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/cchrysostomou/subscriptions", "type": "User", "url": "https://api.github.com/users/cchrysostomou" }
[ { "color": "0052cc", "default": false, "description": null, "id": 34444536, "name": "Usage Question", "node_id": "MDU6TGFiZWwzNDQ0NDUzNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Usage%20Question" }, { "color": "5319e7", "default": false, "description": "read_hdf, HDFStore", "id": 47229190, "name": "IO HDF5", "node_id": "MDU6TGFiZWw0NzIyOTE5MA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20HDF5" } ]
closed
false
null
[]
null
5
2016-05-26T07:05:58Z
2016-05-27T00:50:06Z
2016-05-26T10:58:22Z
NONE
null
I am trying to write results from a dataframe to hdf using the append (or .to_hdf) function. A few of my columns are large string whose length will vary (around 1k characters). Because its length will vary, I have to set, min_itemsize, for each of the variable columns. I do not want these fields to be treated as data_columns, but each time I define the column in the field min_itemsize, they become data_columns when looking at the result in hdf. ``` >>> df = pd.DataFrame(columns=['long string', 'a', 'b', 'longstring2']) >>>df.to_hdf('test', 'key', data_columns=['a']) # => only a is a data_column >>>df.to_hdf('test', 'key', data_columns=['a'], min_itemsize={'long string': 1000, 'lonstring2': 1000}) # => now a, longstring2, and long string are datacolumns. ``` Is there any way to define min_itemsizes but not make those fields data_columns? I ask because when I make them data_columns I get warnings that my rowsize is too large.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13289/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13289/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13290
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13290/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13290/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13290/events
https://github.com/pandas-dev/pandas/issues/13290
156,925,247
MDU6SXNzdWUxNTY5MjUyNDc=
13,290
combine_first breaks for MultiIndex
{ "avatar_url": "https://avatars.githubusercontent.com/u/19585788?v=4", "events_url": "https://api.github.com/users/bcm939/events{/privacy}", "followers_url": "https://api.github.com/users/bcm939/followers", "following_url": "https://api.github.com/users/bcm939/following{/other_user}", "gists_url": "https://api.github.com/users/bcm939/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/bcm939", "id": 19585788, "login": "bcm939", "node_id": "MDQ6VXNlcjE5NTg1Nzg4", "organizations_url": "https://api.github.com/users/bcm939/orgs", "received_events_url": "https://api.github.com/users/bcm939/received_events", "repos_url": "https://api.github.com/users/bcm939/repos", "site_admin": false, "starred_url": "https://api.github.com/users/bcm939/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/bcm939/subscriptions", "type": "User", "url": "https://api.github.com/users/bcm939" }
[ { "color": "d7e102", "default": false, "description": "np.nan, pd.NaT, pd.NA, dropna, isnull, interpolate", "id": 2822342, "name": "Missing-data", "node_id": "MDU6TGFiZWwyODIyMzQy", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Missing-data" }, { "color": "02d7e1", "default": false, "description": "Concat, Merge/Join, Stack/Unstack, Explode", "id": 13098779, "name": "Reshaping", "node_id": "MDU6TGFiZWwxMzA5ODc3OQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Reshaping" }, { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 2361, "created_at": "2015-02-26T19:29:05Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1020496?v=4", "events_url": "https://api.github.com/users/jorisvandenbossche/events{/privacy}", "followers_url": "https://api.github.com/users/jorisvandenbossche/followers", "following_url": "https://api.github.com/users/jorisvandenbossche/following{/other_user}", "gists_url": "https://api.github.com/users/jorisvandenbossche/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jorisvandenbossche", "id": 1020496, "login": "jorisvandenbossche", "node_id": "MDQ6VXNlcjEwMjA0OTY=", "organizations_url": "https://api.github.com/users/jorisvandenbossche/orgs", "received_events_url": "https://api.github.com/users/jorisvandenbossche/received_events", "repos_url": "https://api.github.com/users/jorisvandenbossche/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jorisvandenbossche/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jorisvandenbossche/subscriptions", "type": "User", "url": "https://api.github.com/users/jorisvandenbossche" }, "description": "A milestone for closed or open issues for which there is no action needed (eg not a bug, just a question / discussion, nothing to resolve, wontfix, etc).\r\n\r\n", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/33", "id": 997544, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33/labels", "node_id": "MDk6TWlsZXN0b25lOTk3NTQ0", "number": 33, "open_issues": 11, "state": "open", "title": "No action", "updated_at": "2021-11-19T17:33:16Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/33" }
3
2016-05-26T07:54:13Z
2016-05-27T12:39:37Z
2016-05-27T12:39:27Z
NONE
null
I am not getting the expected output of the command `a.combine_first(b)`. All values are _NaN_. As you will see in my code, I want my index and columns to be the union of the indices and columns and the values to be of _a_ and only of _b_ if it does not exist in _a_ or is _NaN_ in _a_. Hence, I do not believe _DataFrame.merge_ is appropriate for this task, but I may be wrong. Here is the code to reproduce: ``` from __future__ import print_function import pandas as pd import dateutil.parser import numpy as np date = dateutil.parser.parse('2016-05-03').date() a_values = [[100.0, 0.0, 0, 0, 100], [97.29, 2.70, np.nan, 0, 100], [97.33, 2.66, 0, 0, 100]] a_index = pd.MultiIndex.from_tuples([('an', date), ('rc', date), ('avg/total', '')], names=['ls', 'date']) a_columns = ['complete', 'no', 'over', 'partial', 'total'] a = pd.DataFrame(a_values, index=a_index, columns=a_columns) b_values = np.arange(5 * 4).reshape(5, 4) b_index = pd.MultiIndex.from_product([['ad', 'aj', 'an', 'rc', 'ra'], pd.Index([date])], names=['ls', 'date']) b_columns = ['no', 'partial', 'complete', 'over'] b = pd.DataFrame(b_values, index=b_index, columns=b_columns) c_values = [[2, 0, 3, 1, np.nan], [6, 4, 7, 5, np.nan], [100.0, 0.0, 0, 0, 100], [97.33, 2.66, 0, 0, 100], [14, 12, 15, 13, np.nan], [97.29, 2.70,\ 14, 0, 100]] c_index = pd.MultiIndex.from_tuples([('ad', date), ('aj', date), ('an', date), ('avg/total', ''), ('ra', date), ('rc', date)], names=['ls', 'date'\ ]) c_columns = ['complete', 'no', 'over', 'partial', 'total'] c = pd.DataFrame(c_values, index=c_index, columns=c_columns) print('=========================') print('DataFrame a:') print(a) print() print('DataFrame b:') print(b) print() print('=========================') print() print("a.index[0] == b.index[2]? {0}".format(a.index[0] == b.index[2])) print("a.index[1] == b.index[3]? {0}".format(a.index[1] == b.index[3])) print() print('=========================') print() print("a.combine_first(b):") print(a.combine_first(b)) print() print("expected:") print(c) ``` And here is the expected output, along with some intermediate steps: ``` ========================= DataFrame a: complete no over partial total ls date an 2016-05-03 100.00 0.00 0 0 100 rc 2016-05-03 97.29 2.70 NaN 0 100 avg/total 97.33 2.66 0 0 100 DataFrame b: no partial complete over ls date ad 2016-05-03 0 1 2 3 aj 2016-05-03 4 5 6 7 an 2016-05-03 8 9 10 11 rc 2016-05-03 12 13 14 15 ra 2016-05-03 16 17 18 19 ========================= a.index[0] == b.index[2]? True a.index[1] == b.index[3]? True ========================= a.combine_first(b): complete no over partial total ls date ad 2016-05-03 NaN NaN NaN NaN NaN aj 2016-05-03 NaN NaN NaN NaN NaN an 2016-05-03 NaN NaN NaN NaN NaN avg/total NaT NaN NaN NaN NaN NaN ra 2016-05-03 NaN NaN NaN NaN NaN rc 2016-05-03 NaN NaN NaN NaN NaN expected: complete no over partial total ls date ad 2016-05-03 2.00 0.00 3 1 NaN aj 2016-05-03 6.00 4.00 7 5 NaN an 2016-05-03 100.00 0.00 0 0 100 avg/total NaT 97.33 2.66 0 0 100 ra 2016-05-03 14.00 12.00 15 13 NaN rc 2016-05-03 97.29 2.70 14 0 100 ``` #### output of `pd.show_versions()` ``` In [270]: pd.show_versions() INSTALLED VERSIONS ------------------ commit: None python: 2.7.3.final.0 python-bits: 64 OS: Linux OS-release: 3.11.0-26-generic machine: x86_64 processor: x86_64 byteorder: little LC_ALL: None LANG: en_US.UTF-8 pandas: 0.16.2 nose: 1.3.3 Cython: 0.19.2 numpy: 1.8.0 scipy: 0.13.0 statsmodels: 0.5.0 IPython: 0.12.1 sphinx: None patsy: 0.2.1 dateutil: 1.5 pytz: 2013.7 bottleneck: None tables: 3.0.0 numexpr: 2.2.2 matplotlib: 1.4.2 openpyxl: None xlrd: 0.9.3 xlwt: None xlsxwriter: None lxml: None bs4: None html5lib: None httplib2: 0.7.2 apiclient: None sqlalchemy: 0.9.8 pymysql: None psycopg2: None ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13290/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13290/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13291
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13291/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13291/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13291/events
https://github.com/pandas-dev/pandas/issues/13291
156,945,325
MDU6SXNzdWUxNTY5NDUzMjU=
13,291
format ignored in HDFStore.open
{ "avatar_url": "https://avatars.githubusercontent.com/u/3305496?v=4", "events_url": "https://api.github.com/users/simonkamronn/events{/privacy}", "followers_url": "https://api.github.com/users/simonkamronn/followers", "following_url": "https://api.github.com/users/simonkamronn/following{/other_user}", "gists_url": "https://api.github.com/users/simonkamronn/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/simonkamronn", "id": 3305496, "login": "simonkamronn", "node_id": "MDQ6VXNlcjMzMDU0OTY=", "organizations_url": "https://api.github.com/users/simonkamronn/orgs", "received_events_url": "https://api.github.com/users/simonkamronn/received_events", "repos_url": "https://api.github.com/users/simonkamronn/repos", "site_admin": false, "starred_url": "https://api.github.com/users/simonkamronn/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/simonkamronn/subscriptions", "type": "User", "url": "https://api.github.com/users/simonkamronn" }
[ { "color": "ffa0ff", "default": false, "description": "Incorrect or improved errors from pandas", "id": 42670965, "name": "Error Reporting", "node_id": "MDU6TGFiZWw0MjY3MDk2NQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Error%20Reporting" }, { "color": "5319e7", "default": false, "description": "read_hdf, HDFStore", "id": 47229190, "name": "IO HDF5", "node_id": "MDU6TGFiZWw0NzIyOTE5MA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20HDF5" }, { "color": "0e8a16", "default": true, "description": null, "id": 717120670, "name": "good first issue", "node_id": "MDU6TGFiZWw3MTcxMjA2NzA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/good%20first%20issue" } ]
closed
false
null
[]
{ "closed_at": "2019-01-26T00:51:26Z", "closed_issues": 2048, "created_at": "2018-03-29T12:00:12Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1020496?v=4", "events_url": "https://api.github.com/users/jorisvandenbossche/events{/privacy}", "followers_url": "https://api.github.com/users/jorisvandenbossche/followers", "following_url": "https://api.github.com/users/jorisvandenbossche/following{/other_user}", "gists_url": "https://api.github.com/users/jorisvandenbossche/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jorisvandenbossche", "id": 1020496, "login": "jorisvandenbossche", "node_id": "MDQ6VXNlcjEwMjA0OTY=", "organizations_url": "https://api.github.com/users/jorisvandenbossche/orgs", "received_events_url": "https://api.github.com/users/jorisvandenbossche/received_events", "repos_url": "https://api.github.com/users/jorisvandenbossche/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jorisvandenbossche/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jorisvandenbossche/subscriptions", "type": "User", "url": "https://api.github.com/users/jorisvandenbossche" }, "description": "", "due_on": "2019-01-31T08:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/55", "id": 3228419, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/55/labels", "node_id": "MDk6TWlsZXN0b25lMzIyODQxOQ==", "number": 55, "open_issues": 0, "state": "closed", "title": "0.24.0", "updated_at": "2019-01-29T07:42:40Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/55" }
1
2016-05-26T09:47:41Z
2018-12-09T16:10:58Z
2018-12-09T16:10:58Z
NONE
null
``` new_store = pd.HDFStore('data/test.h5', format='table') new_store['df'] = pd.DataFrame(np.random.rand(5,1)) new_store.put('df2', pd.DataFrame(np.random.rand(5,1)), format='table') print('df stored as table: %s' % new_store.get_storer('df').is_table) print('df2 stored as table: %s' % new_store.get_storer('df2').is_table) ``` df stored as table: False df2 stored as table: True ## INSTALLED VERSIONS commit: None python: 2.7.11.final.0 python-bits: 64 OS: Linux OS-release: 3.16.0-30-generic machine: x86_64 processor: x86_64 byteorder: little LC_ALL: None LANG: None pandas: 0.18.0
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13291/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13291/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13292
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13292/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13292/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13292/events
https://github.com/pandas-dev/pandas/issues/13292
156,953,903
MDU6SXNzdWUxNTY5NTM5MDM=
13,292
Exception when adding a unicode margins_name in pivot_table
{ "avatar_url": "https://avatars.githubusercontent.com/u/3911074?v=4", "events_url": "https://api.github.com/users/spapas/events{/privacy}", "followers_url": "https://api.github.com/users/spapas/followers", "following_url": "https://api.github.com/users/spapas/following{/other_user}", "gists_url": "https://api.github.com/users/spapas/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/spapas", "id": 3911074, "login": "spapas", "node_id": "MDQ6VXNlcjM5MTEwNzQ=", "organizations_url": "https://api.github.com/users/spapas/orgs", "received_events_url": "https://api.github.com/users/spapas/received_events", "repos_url": "https://api.github.com/users/spapas/repos", "site_admin": false, "starred_url": "https://api.github.com/users/spapas/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/spapas/subscriptions", "type": "User", "url": "https://api.github.com/users/spapas" }
[ { "color": "444444", "default": false, "description": "Unicode strings", "id": 36380025, "name": "Unicode", "node_id": "MDU6TGFiZWwzNjM4MDAyNQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Unicode" }, { "color": "ffa0ff", "default": false, "description": "Incorrect or improved errors from pandas", "id": 42670965, "name": "Error Reporting", "node_id": "MDU6TGFiZWw0MjY3MDk2NQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Error%20Reporting" } ]
closed
false
null
[]
{ "closed_at": "2017-10-28T18:54:27Z", "closed_issues": 764, "created_at": "2017-03-23T13:26:25Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2017-10-27T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/46", "id": 2406656, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/46/labels", "node_id": "MDk6TWlsZXN0b25lMjQwNjY1Ng==", "number": 46, "open_issues": 0, "state": "closed", "title": "0.21.0", "updated_at": "2018-07-08T21:53:21Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/46" }
3
2016-05-26T10:34:36Z
2017-09-12T10:31:32Z
2017-09-12T10:31:32Z
NONE
null
#### Code Sample, a copy-pastable example if possible This throws UnicodeDecodeError in python2 `pd.pivot_table(pd.DataFrame({'foo': [1,2,3]}), index=['foo'], aggfunc=len, margins=True, margins_name=u'Δοκιμή')` #### Expected Output Not throwing exception! #### output of `pd.show_versions()` <pre> INSTALLED VERSIONS ------------------ commit: None python: 2.7.11.final.0 python-bits: 32 OS: Windows OS-release: 10 machine: AMD64 processor: Intel64 Family 6 Model 58 Stepping 9, GenuineIntel byteorder: little LC_ALL: None LANG: None pandas: 0.18.1 nose: None pip: 8.1.2 setuptools: 20.10.1 Cython: None numpy: 1.11.0 scipy: None statsmodels: None xarray: None IPython: None sphinx: None patsy: None dateutil: 2.5.2 pytz: 2016.4 blosc: None bottleneck: None tables: None numexpr: None matplotlib: None openpyxl: None xlrd: 0.9.4 xlwt: 1.0.0 xlsxwriter: None lxml: None bs4: None html5lib: None httplib2: None apiclient: None sqlalchemy: None pymysql: None psycopg2: 2.6.1 (dt dec pq3 ext) jinja2: None boto: None pandas_datareader: None </pre> The above is a well-known problem when mixing unicode and non-unicode strings in python2: The fix (for python 2) is very simple, just add a `u` in front of the `exception_msg` string literal in https://github.com/pydata/pandas/blob/master/pandas/tools/pivot.py#L178 i.e line 178 should be `exception_msg = u'Conflicting name "{0}" in margins'.format(margins_name)` I am not sure what's the correct way to fix that in python 3 and a python2-3 compatible way so I won't provide a PR for that.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13292/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13292/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13293
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13293/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13293/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13293/events
https://github.com/pandas-dev/pandas/pull/13293
156,959,235
MDExOlB1bGxSZXF1ZXN0NzE1Mzc5MzA=
13,293
DOC: low_memory in read_csv
{ "avatar_url": "https://avatars.githubusercontent.com/u/1924092?v=4", "events_url": "https://api.github.com/users/chris-b1/events{/privacy}", "followers_url": "https://api.github.com/users/chris-b1/followers", "following_url": "https://api.github.com/users/chris-b1/following{/other_user}", "gists_url": "https://api.github.com/users/chris-b1/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/chris-b1", "id": 1924092, "login": "chris-b1", "node_id": "MDQ6VXNlcjE5MjQwOTI=", "organizations_url": "https://api.github.com/users/chris-b1/orgs", "received_events_url": "https://api.github.com/users/chris-b1/received_events", "repos_url": "https://api.github.com/users/chris-b1/repos", "site_admin": false, "starred_url": "https://api.github.com/users/chris-b1/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/chris-b1/subscriptions", "type": "User", "url": "https://api.github.com/users/chris-b1" }
[ { "color": "3465A4", "default": false, "description": null, "id": 134699, "name": "Docs", "node_id": "MDU6TGFiZWwxMzQ2OTk=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Docs" }, { "color": "5319e7", "default": false, "description": "read_csv, to_csv", "id": 47229171, "name": "IO CSV", "node_id": "MDU6TGFiZWw0NzIyOTE3MQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20CSV" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
3
2016-05-26T11:06:58Z
2016-05-26T23:56:27Z
2016-05-26T23:56:09Z
CONTRIBUTOR
null
- [x] closes #5888, xref #12686 - [x] passes `git diff upstream/master | flake8 --diff`
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13293/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13293/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13293.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13293", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13293.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13293" }
https://api.github.com/repos/pandas-dev/pandas/issues/13294
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13294/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13294/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13294/events
https://github.com/pandas-dev/pandas/issues/13294
156,972,420
MDU6SXNzdWUxNTY5NzI0MjA=
13,294
ERR: _shallow_copy should assert dtype
{ "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }
[ { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" }, { "color": "0052cc", "default": false, "description": "pandas objects compatability with Numpy or Python functions", "id": 76865106, "name": "Compat", "node_id": "MDU6TGFiZWw3Njg2NTEwNg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Compat" }, { "color": "e99695", "default": false, "description": "Related to the Index class or subclasses", "id": 1218227310, "name": "Index", "node_id": "MDU6TGFiZWwxMjE4MjI3MzEw", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Index" }, { "color": "d4c5f9", "default": false, "description": "Series/DataFrame/Index/pd.array Constructors", "id": 1465286368, "name": "Constructors", "node_id": "MDU6TGFiZWwxNDY1Mjg2MzY4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Constructors" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 786, "created_at": "2015-01-13T10:53:19Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "Changes that would be nice to have in the next release. These issues are not blocking. They will be pushed to the next release if no one has time to fix them.", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/32", "id": 933188, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32/labels", "node_id": "MDk6TWlsZXN0b25lOTMzMTg4", "number": 32, "open_issues": 1053, "state": "open", "title": "Contributions Welcome", "updated_at": "2021-11-21T00:50:06Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32" }
7
2016-05-26T12:29:22Z
2020-04-10T03:40:25Z
2020-04-10T03:40:24Z
CONTRIBUTOR
null
xref #13288 ``` In [2]: i = Index([0,'A']) In [3]: i._shallow_copy([0]) Out[3]: Index([0], dtype='int64') ``` We should assert that we have a valid dtype in the constructed object (so should do this in `_simple_new` to avoid these guarantee violations)
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13294/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13294/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13295
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13295/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13295/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13295/events
https://github.com/pandas-dev/pandas/issues/13295
156,975,686
MDU6SXNzdWUxNTY5NzU2ODY=
13,295
TST: doc-build and html styling
{ "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }
[ { "color": "C4A000", "default": false, "description": "pandas testing functions or related to the test suite", "id": 127685, "name": "Testing", "node_id": "MDU6TGFiZWwxMjc2ODU=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Testing" }, { "color": "006b75", "default": false, "description": "read_html, to_html, Styler.apply, Styler.applymap", "id": 57395487, "name": "IO HTML", "node_id": "MDU6TGFiZWw1NzM5NTQ4Nw==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20HTML" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
2
2016-05-26T12:47:55Z
2016-05-26T15:47:57Z
2016-05-26T15:47:57Z
CONTRIBUTOR
null
https://travis-ci.org/pydata/pandas/jobs/132906479#L1631 seems specifying the path wrong? @TomAugspurger @jorisvandenbossche
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13295/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13295/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13296
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13296/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13296/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13296/events
https://github.com/pandas-dev/pandas/issues/13296
157,042,603
MDU6SXNzdWUxNTcwNDI2MDM=
13,296
ERR: Series must have a singluar dtype otherwise should raise
{ "avatar_url": "https://avatars.githubusercontent.com/u/1377457?v=4", "events_url": "https://api.github.com/users/pganssle/events{/privacy}", "followers_url": "https://api.github.com/users/pganssle/followers", "following_url": "https://api.github.com/users/pganssle/following{/other_user}", "gists_url": "https://api.github.com/users/pganssle/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pganssle", "id": 1377457, "login": "pganssle", "node_id": "MDQ6VXNlcjEzNzc0NTc=", "organizations_url": "https://api.github.com/users/pganssle/orgs", "received_events_url": "https://api.github.com/users/pganssle/received_events", "repos_url": "https://api.github.com/users/pganssle/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pganssle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pganssle/subscriptions", "type": "User", "url": "https://api.github.com/users/pganssle" }
[ { "color": "e102d8", "default": false, "description": "Unexpected or buggy dtype conversions", "id": 31404521, "name": "Dtype Conversions", "node_id": "MDU6TGFiZWwzMTQwNDUyMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Dtype%20Conversions" }, { "color": "AD7FA8", "default": false, "description": null, "id": 35818298, "name": "API Design", "node_id": "MDU6TGFiZWwzNTgxODI5OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/API%20Design" }, { "color": "ffa0ff", "default": false, "description": "Incorrect or improved errors from pandas", "id": 42670965, "name": "Error Reporting", "node_id": "MDU6TGFiZWw0MjY3MDk2NQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Error%20Reporting" }, { "color": "0e8a16", "default": true, "description": null, "id": 717120670, "name": "good first issue", "node_id": "MDU6TGFiZWw3MTcxMjA2NzA=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/good%20first%20issue" }, { "color": "d4c5f9", "default": false, "description": "Series/DataFrame/Index/pd.array Constructors", "id": 1465286368, "name": "Constructors", "node_id": "MDU6TGFiZWwxNDY1Mjg2MzY4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Constructors" } ]
closed
false
null
[]
{ "closed_at": "2020-01-30T12:18:05Z", "closed_issues": 2207, "created_at": "2012-09-13T02:13:00Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/329591?v=4", "events_url": "https://api.github.com/users/wesm/events{/privacy}", "followers_url": "https://api.github.com/users/wesm/followers", "following_url": "https://api.github.com/users/wesm/following{/other_user}", "gists_url": "https://api.github.com/users/wesm/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/wesm", "id": 329591, "login": "wesm", "node_id": "MDQ6VXNlcjMyOTU5MQ==", "organizations_url": "https://api.github.com/users/wesm/orgs", "received_events_url": "https://api.github.com/users/wesm/received_events", "repos_url": "https://api.github.com/users/wesm/repos", "site_admin": false, "starred_url": "https://api.github.com/users/wesm/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/wesm/subscriptions", "type": "User", "url": "https://api.github.com/users/wesm" }, "description": "on-merge: backport to 1.0.x", "due_on": "2020-02-01T08:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/16", "id": 174211, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/16/labels", "node_id": "MDk6TWlsZXN0b25lMTc0MjEx", "number": 16, "open_issues": 0, "state": "closed", "title": "1.0.0", "updated_at": "2020-01-30T12:18:05Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/16" }
14
2016-05-26T17:59:00Z
2019-12-26T21:19:17Z
2019-12-26T21:19:17Z
CONTRIBUTOR
null
When constructing a `Series` object using a numpy structured data array, if you try and cast it to a `str` (or print it), it throws: ``` TypeError(ufunc 'isnan' not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ''safe'') ``` You can print a single value from the series, but not the whole series. #### Code Sample, a copy-pastable example if possible ``` python import pandas as pd import numpy as np c_dtype = np.dtype([('a', 'i8'), ('b', 'f4')]) cdt_arr = np.array([(1, 0.4), (256, -13)], dtype=c_dtype) pds = pd.Series(cdt_arr, index=['A', 'B']) print('pds.iloc[0]: {}'.format(str(pds.iloc[0]))) # (1, 0.4000000059604645) print('pds.iloc[1]: {}'.format(str(pds.iloc[1]))) # (256, -13.0) print('pds.loc["A"]: {}'.format(str(pds.loc['A']))) # Works print('pds.loc["B"]: {}'.format(str(pds.loc['B']))) # Works def print_error(x): try: o = str(x) # repr(x) also causes the same errors print(o) except TypeError as e: print('TypeError({})'.format(e.args[0])) a = pds.iloc[0:1] b = pds.loc[['A', 'B']] print('pds.iloc[0:1]:') print_error(a) print('pds.loc["A", "B"]:') print_error(b) print('pds:') print_error(pds) print('pd.DataFrame([pds]).T:') print_error(pd.DataFrame([pds]).T) print('pds2:') cdt_arr_2 = np.array([(1, 0.4)], dtype=c_dtype) pds2 = pd.Series(cdt_arr_2, index=['A']) print_error(pds2) ``` #### Output (actual): ``` $ python demo_index_bug.py pds.iloc[0]: (1, 0.4000000059604645) pds.iloc[1]: (256, -13.0) pds.loc["A"]: (1, 0.4000000059604645) pds.loc["B"]: (256, -13.0) pds.iloc[0:1]: TypeError(ufunc 'isnan' not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ''safe'') pds.loc["A", "B"]: TypeError(ufunc 'isnan' not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ''safe'') pds: TypeError(ufunc 'isnan' not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ''safe'') pd.DataFrame([pds]).T: 0 A (1, 0.4000000059604645) B (256, -13.0) pds2: TypeError(ufunc 'isnan' not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ''safe'') ``` #### output of `pd.show_versions()`: ``` INSTALLED VERSIONS ------------------ commit: None python: 3.5.1.final.0 python-bits: 64 OS: Linux OS-release: 4.5.2-1-ARCH machine: x86_64 processor: byteorder: little LC_ALL: None LANG: en_US.UTF-8 pandas: 0.18.1 nose: None pip: 8.1.2 setuptools: 21.0.0 Cython: 0.24 numpy: 1.11.0 scipy: 0.17.1 statsmodels: None xarray: None IPython: 4.2.0 sphinx: 1.4.1 patsy: None dateutil: 2.5.3 pytz: 2016.4 blosc: None bottleneck: None tables: None numexpr: None matplotlib: 1.5.1 openpyxl: None xlrd: None xlwt: None xlsxwriter: None lxml: None bs4: None html5lib: None httplib2: None apiclient: None sqlalchemy: None pymysql: None psycopg2: None jinja2: 2.8 boto: None pandas_datareader: None ``` #### Stack Trace I swallowed the stack traces to show where this was failing, so here's the traceback for that last error: ``` Traceback (most recent call last): File "demo_dtype_bug.py", line 37, in <module> print(pds2) File "~/.local/lib/python3.5/site-packages/pandas/core/base.py", line 46, in __str__ return self.__unicode__() File "~/.local/lib/python3.5/site-packages/pandas/core/series.py", line 984, in __unicode__ max_rows=max_rows) File "~/.local/lib/python3.5/site-packages/pandas/core/series.py", line 1025, in to_string dtype=dtype, name=name, max_rows=max_rows) File "~/.local/lib/python3.5/site-packages/pandas/core/series.py", line 1053, in _get_repr result = formatter.to_string() File "~/.local/lib/python3.5/site-packages/pandas/formats/format.py", line 225, in to_string fmt_values = self._get_formatted_values() File "~/.local/lib/python3.5/site-packages/pandas/formats/format.py", line 215, in _get_formatted_values float_format=self.float_format, na_rep=self.na_rep) File "~/.local/lib/python3.5/site-packages/pandas/formats/format.py", line 2007, in format_array return fmt_obj.get_result() File "~/.local/lib/python3.5/site-packages/pandas/formats/format.py", line 2026, in get_result fmt_values = self._format_strings() File "~/.local/lib/python3.5/site-packages/pandas/formats/format.py", line 2059, in _format_strings is_float = lib.map_infer(vals, com.is_float) & notnull(vals) File "~/.local/lib/python3.5/site-packages/pandas/core/common.py", line 250, in notnull res = isnull(obj) File "~/.local/lib/python3.5/site-packages/pandas/core/common.py", line 91, in isnull return _isnull(obj) File "~/.local/lib/python3.5/site-packages/pandas/core/common.py", line 101, in _isnull_new return _isnull_ndarraylike(obj) File "~/.local/lib/python3.5/site-packages/pandas/core/common.py", line 192, in _isnull_ndarraylike result = np.isnan(values) TypeError: ufunc 'isnan' not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ''safe'' ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13296/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13296/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13297
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13297/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13297/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13297/events
https://github.com/pandas-dev/pandas/issues/13297
157,071,384
MDU6SXNzdWUxNTcwNzEzODQ=
13,297
ENH: EWM Sum?
{ "avatar_url": "https://avatars.githubusercontent.com/u/5635139?v=4", "events_url": "https://api.github.com/users/max-sixty/events{/privacy}", "followers_url": "https://api.github.com/users/max-sixty/followers", "following_url": "https://api.github.com/users/max-sixty/following{/other_user}", "gists_url": "https://api.github.com/users/max-sixty/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/max-sixty", "id": 5635139, "login": "max-sixty", "node_id": "MDQ6VXNlcjU2MzUxMzk=", "organizations_url": "https://api.github.com/users/max-sixty/orgs", "received_events_url": "https://api.github.com/users/max-sixty/received_events", "repos_url": "https://api.github.com/users/max-sixty/repos", "site_admin": false, "starred_url": "https://api.github.com/users/max-sixty/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/max-sixty/subscriptions", "type": "User", "url": "https://api.github.com/users/max-sixty" }
[ { "color": "4E9A06", "default": false, "description": null, "id": 76812, "name": "Enhancement", "node_id": "MDU6TGFiZWw3NjgxMg==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Enhancement" }, { "color": "d4c5f9", "default": false, "description": "rolling, ewma, expanding", "id": 1045950827, "name": "Window", "node_id": "MDU6TGFiZWwxMDQ1OTUwODI3", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Window" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 1203, "created_at": "2021-06-09T18:28:42Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2021-12-31T08:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/86", "id": 6840253, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/86/labels", "node_id": "MDk6TWlsZXN0b25lNjg0MDI1Mw==", "number": 86, "open_issues": 77, "state": "open", "title": "1.4", "updated_at": "2021-11-21T02:34:31Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/86" }
2
2016-05-26T20:25:57Z
2021-10-06T12:57:43Z
2021-10-06T12:57:43Z
CONTRIBUTOR
null
I _think_ this would be just: `.ewm(span).mean() * span` Now: ``` python In [4]: pd.Series(range(10)).ewm(span=2).sum() --------------------------------------------------------------------------- AttributeError Traceback (most recent call last) <ipython-input-4-8e0e72f35eb3> in <module>() ----> 1 pd.Series(range(10)).ewm(span=2).sum() /Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/pandas/core/window.py in __getattr__(self, attr) 122 123 raise AttributeError("%r object has no attribute %r" % --> 124 (type(self).__name__, attr)) 125 126 def _dir_additions(self): AttributeError: 'EWM' object has no attribute 'sum' ``` CC @erbian
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13297/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13297/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13298
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13298/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13298/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13298/events
https://github.com/pandas-dev/pandas/pull/13298
157,074,043
MDExOlB1bGxSZXF1ZXN0NzE2MjA3NTM=
13,298
BUG: Fix describe(): percentiles (#13104), col index (#13288)
{ "avatar_url": "https://avatars.githubusercontent.com/u/9507544?v=4", "events_url": "https://api.github.com/users/pijucha/events{/privacy}", "followers_url": "https://api.github.com/users/pijucha/followers", "following_url": "https://api.github.com/users/pijucha/following{/other_user}", "gists_url": "https://api.github.com/users/pijucha/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pijucha", "id": 9507544, "login": "pijucha", "node_id": "MDQ6VXNlcjk1MDc1NDQ=", "organizations_url": "https://api.github.com/users/pijucha/orgs", "received_events_url": "https://api.github.com/users/pijucha/received_events", "repos_url": "https://api.github.com/users/pijucha/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pijucha/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pijucha/subscriptions", "type": "User", "url": "https://api.github.com/users/pijucha" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "ededed", "default": false, "description": "__repr__ of pandas objects, to_string", "id": 13101118, "name": "Output-Formatting", "node_id": "MDU6TGFiZWwxMzEwMTExOA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Output-Formatting" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
6
2016-05-26T20:39:43Z
2016-05-31T15:48:24Z
2016-05-31T14:12:51Z
CONTRIBUTOR
null
- [x] closes #13104, #13288 - [x] tests added / passed - [x] passes `git diff upstream/master | flake8 --diff` - [x] whatsnew entry BUG #13104: - Percentiles are now rounded to the least precision that keeps them unique. - Supplying duplicates in percentiles will raise ValueError. BUG #13288 - Fixed a column index of the output data frame. Previously, if a data frame had a column index of object type and the index contained numeric values, the output column index could be corrupt. It led to ValueError if the output was displayed.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13298/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13298/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13298.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13298", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13298.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13298" }
https://api.github.com/repos/pandas-dev/pandas/issues/13299
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13299/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13299/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13299/events
https://github.com/pandas-dev/pandas/issues/13299
157,091,734
MDU6SXNzdWUxNTcwOTE3MzQ=
13,299
API: New callable indexing makes storing functions in a Series difficult
{ "avatar_url": "https://avatars.githubusercontent.com/u/1621449?v=4", "events_url": "https://api.github.com/users/evanpw/events{/privacy}", "followers_url": "https://api.github.com/users/evanpw/followers", "following_url": "https://api.github.com/users/evanpw/following{/other_user}", "gists_url": "https://api.github.com/users/evanpw/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/evanpw", "id": 1621449, "login": "evanpw", "node_id": "MDQ6VXNlcjE2MjE0NDk=", "organizations_url": "https://api.github.com/users/evanpw/orgs", "received_events_url": "https://api.github.com/users/evanpw/received_events", "repos_url": "https://api.github.com/users/evanpw/repos", "site_admin": false, "starred_url": "https://api.github.com/users/evanpw/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/evanpw/subscriptions", "type": "User", "url": "https://api.github.com/users/evanpw" }
[ { "color": "0b02e1", "default": false, "description": "Related to indexing on series/frames, not to indexes themselves", "id": 2822098, "name": "Indexing", "node_id": "MDU6TGFiZWwyODIyMDk4", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Indexing" }, { "color": "e11d21", "default": false, "description": "Functionality that used to work in a prior pandas version", "id": 32815646, "name": "Regression", "node_id": "MDU6TGFiZWwzMjgxNTY0Ng==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Regression" }, { "color": "AD7FA8", "default": false, "description": null, "id": 35818298, "name": "API Design", "node_id": "MDU6TGFiZWwzNTgxODI5OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/API%20Design" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
8
2016-05-26T22:18:51Z
2016-07-01T14:18:37Z
2016-07-01T14:18:37Z
CONTRIBUTOR
null
Example of something that previously worked (before 7bbd031104ee161b2fb79ba6f5732910661f94f8): ``` .python >>> s = pd.Series([lambda x: x] * 10) >>> s[s.index > 5] = lambda x: x + 1 ``` But now the second line tries to apply the function in the rhs to the elements of the Series, rather than assigning them (and throws an exception). This is very counter-intuitive when using `__setitem__` rather than calling `Series.where` directly.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13299/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13299/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13300
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13300/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13300/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13300/events
https://github.com/pandas-dev/pandas/pull/13300
157,092,051
MDExOlB1bGxSZXF1ZXN0NzE2MzQwNjc=
13,300
TST: split up test_merge
{ "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }
[ { "color": "C4A000", "default": false, "description": "pandas testing functions or related to the test suite", "id": 127685, "name": "Testing", "node_id": "MDU6TGFiZWwxMjc2ODU=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Testing" }, { "color": "5319e7", "default": false, "description": "Timezone data dtype", "id": 60458168, "name": "Timezones", "node_id": "MDU6TGFiZWw2MDQ1ODE2OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Timezones" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
0
2016-05-26T22:21:08Z
2016-05-26T22:28:35Z
2016-05-26T22:28:35Z
CONTRIBUTOR
null
very small bug fix w.r.t. tz concatting
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13300/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13300/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13300.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13300", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13300.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13300" }
https://api.github.com/repos/pandas-dev/pandas/issues/13301
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13301/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13301/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13301/events
https://github.com/pandas-dev/pandas/pull/13301
157,092,561
MDExOlB1bGxSZXF1ZXN0NzE2MzQ0MTg=
13,301
TST: reorg datetime with tz tests a bit
{ "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }
[ { "color": "C4A000", "default": false, "description": "pandas testing functions or related to the test suite", "id": 127685, "name": "Testing", "node_id": "MDU6TGFiZWwxMjc2ODU=", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Testing" }, { "color": "5319e7", "default": false, "description": "Timezone data dtype", "id": 60458168, "name": "Timezones", "node_id": "MDU6TGFiZWw2MDQ1ODE2OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Timezones" } ]
closed
false
null
[]
{ "closed_at": "2016-10-03T08:52:13Z", "closed_issues": 733, "created_at": "2016-03-11T21:24:45Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "", "due_on": "2016-09-30T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/40", "id": 1639795, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40/labels", "node_id": "MDk6TWlsZXN0b25lMTYzOTc5NQ==", "number": 40, "open_issues": 0, "state": "closed", "title": "0.19.0", "updated_at": "2017-11-06T02:01:14Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/40" }
0
2016-05-26T22:24:50Z
2016-05-26T23:44:04Z
2016-05-26T23:44:04Z
CONTRIBUTOR
null
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13301/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13301/timeline
null
0
{ "diff_url": "https://github.com/pandas-dev/pandas/pull/13301.diff", "html_url": "https://github.com/pandas-dev/pandas/pull/13301", "merged_at": null, "patch_url": "https://github.com/pandas-dev/pandas/pull/13301.patch", "url": "https://api.github.com/repos/pandas-dev/pandas/pulls/13301" }
https://api.github.com/repos/pandas-dev/pandas/issues/13302
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13302/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13302/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13302/events
https://github.com/pandas-dev/pandas/issues/13302
157,104,029
MDU6SXNzdWUxNTcxMDQwMjk=
13,302
Inconsistent Handling of na_values and converters in read_csv
{ "avatar_url": "https://avatars.githubusercontent.com/u/9273653?v=4", "events_url": "https://api.github.com/users/gfyoung/events{/privacy}", "followers_url": "https://api.github.com/users/gfyoung/followers", "following_url": "https://api.github.com/users/gfyoung/following{/other_user}", "gists_url": "https://api.github.com/users/gfyoung/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/gfyoung", "id": 9273653, "login": "gfyoung", "node_id": "MDQ6VXNlcjkyNzM2NTM=", "organizations_url": "https://api.github.com/users/gfyoung/orgs", "received_events_url": "https://api.github.com/users/gfyoung/received_events", "repos_url": "https://api.github.com/users/gfyoung/repos", "site_admin": false, "starred_url": "https://api.github.com/users/gfyoung/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gfyoung/subscriptions", "type": "User", "url": "https://api.github.com/users/gfyoung" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "5319e7", "default": false, "description": "read_csv, to_csv", "id": 47229171, "name": "IO CSV", "node_id": "MDU6TGFiZWw0NzIyOTE3MQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/IO%20CSV" } ]
open
false
null
[]
{ "closed_at": null, "closed_issues": 786, "created_at": "2015-01-13T10:53:19Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "Changes that would be nice to have in the next release. These issues are not blocking. They will be pushed to the next release if no one has time to fix them.", "due_on": null, "html_url": "https://github.com/pandas-dev/pandas/milestone/32", "id": 933188, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32/labels", "node_id": "MDk6TWlsZXN0b25lOTMzMTg4", "number": 32, "open_issues": 1053, "state": "open", "title": "Contributions Welcome", "updated_at": "2021-11-21T00:50:06Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/32" }
3
2016-05-26T23:58:42Z
2019-10-21T19:34:18Z
null
MEMBER
null
On `master` (commit <a href="https://github.com/pydata/pandas/commit/40b4bb4bb2a7018ed08025c5c93cd1080a0b5f7f">40b4bb4</a>): ``` python >>> data = """A 1 CAT 3""" >>> f = lambda x: x >>> read_csv(StringIO(data), na_values='CAT', converters={'A': f}, engine='c') A 0 1 1 CAT 2 3 >>> read_csv(StringIO(data), na_values='CAT', converters={'A': f}, engine='python') A 0 1 1 NaN 2 3 ``` I expect both to give the same output, though I believe the Python output is more correct because it respects `na_values` unlike the C engine. I thought the simple fix would be to remove the `continue` statement <a href="https://github.com/pydata/pandas/blob/master/pandas/parser.pyx#L1008">here</a>, but that causes test failures, so probably a more involved refactoring might be needed to align the order of converter application, `NaN` value conversion, and `dtype` conversion. IMO this should be added to #12686, as this is a difference in behaviour between the two engines. xref #5232
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13302/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13302/timeline
null
null
null
https://api.github.com/repos/pandas-dev/pandas/issues/13303
https://api.github.com/repos/pandas-dev/pandas
https://api.github.com/repos/pandas-dev/pandas/issues/13303/labels{/name}
https://api.github.com/repos/pandas-dev/pandas/issues/13303/comments
https://api.github.com/repos/pandas-dev/pandas/issues/13303/events
https://github.com/pandas-dev/pandas/issues/13303
157,123,828
MDU6SXNzdWUxNTcxMjM4Mjg=
13,303
Timezone aware Timestamp.dayofyear does not report correct day
{ "avatar_url": "https://avatars.githubusercontent.com/u/7747568?v=4", "events_url": "https://api.github.com/users/tumalow-will/events{/privacy}", "followers_url": "https://api.github.com/users/tumalow-will/followers", "following_url": "https://api.github.com/users/tumalow-will/following{/other_user}", "gists_url": "https://api.github.com/users/tumalow-will/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/tumalow-will", "id": 7747568, "login": "tumalow-will", "node_id": "MDQ6VXNlcjc3NDc1Njg=", "organizations_url": "https://api.github.com/users/tumalow-will/orgs", "received_events_url": "https://api.github.com/users/tumalow-will/received_events", "repos_url": "https://api.github.com/users/tumalow-will/repos", "site_admin": false, "starred_url": "https://api.github.com/users/tumalow-will/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tumalow-will/subscriptions", "type": "User", "url": "https://api.github.com/users/tumalow-will" }
[ { "color": "e10c02", "default": false, "description": null, "id": 76811, "name": "Bug", "node_id": "MDU6TGFiZWw3NjgxMQ==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Bug" }, { "color": "5319e7", "default": false, "description": "Timezone data dtype", "id": 60458168, "name": "Timezones", "node_id": "MDU6TGFiZWw2MDQ1ODE2OA==", "url": "https://api.github.com/repos/pandas-dev/pandas/labels/Timezones" } ]
closed
false
null
[]
{ "closed_at": "2017-05-06T10:20:19Z", "closed_issues": 987, "created_at": "2016-02-08T15:30:21Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/953992?v=4", "events_url": "https://api.github.com/users/jreback/events{/privacy}", "followers_url": "https://api.github.com/users/jreback/followers", "following_url": "https://api.github.com/users/jreback/following{/other_user}", "gists_url": "https://api.github.com/users/jreback/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jreback", "id": 953992, "login": "jreback", "node_id": "MDQ6VXNlcjk1Mzk5Mg==", "organizations_url": "https://api.github.com/users/jreback/orgs", "received_events_url": "https://api.github.com/users/jreback/received_events", "repos_url": "https://api.github.com/users/jreback/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jreback/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jreback/subscriptions", "type": "User", "url": "https://api.github.com/users/jreback" }, "description": "after 0.19.x series", "due_on": "2017-05-12T07:00:00Z", "html_url": "https://github.com/pandas-dev/pandas/milestone/39", "id": 1570595, "labels_url": "https://api.github.com/repos/pandas-dev/pandas/milestones/39/labels", "node_id": "MDk6TWlsZXN0b25lMTU3MDU5NQ==", "number": 39, "open_issues": 0, "state": "closed", "title": "0.20.0", "updated_at": "2018-10-28T08:18:42Z", "url": "https://api.github.com/repos/pandas-dev/pandas/milestones/39" }
1
2016-05-27T03:40:45Z
2017-03-20T17:51:28Z
2017-03-20T17:51:28Z
NONE
null
#### Code Sample, a copy-pastable example if possible ``` import pandas as PD time_str = '2015-10-01 23:59:00-04:00' pd_dto = PD.to_datetime(time_str, utc=True).tz_convert('US/Eastern') actual_yday = pd_dto.date().timetuple().tm_yday print 'pandas thinks', pd_dto, 'is the', pd_dto.dayofyear, 'yday' print 'when really its the', actual_yday ``` #### Expected Output I expect the dayofyear to agree with tm_yday, but they do not. #### output of `pd.show_versions()` <details> ## INSTALLED VERSIONS commit: None python: 2.7.10.final.0 python-bits: 64 OS: Windows OS-release: 8 machine: AMD64 processor: Intel64 Family 6 Model 61 Stepping 4, GenuineIntel byteorder: little LC_ALL: None LANG: None pandas: 0.16.2 nose: 1.3.7 Cython: 0.22.1 numpy: 1.9.2 scipy: 0.15.1 statsmodels: 0.6.1 IPython: 3.2.0 sphinx: 1.3.1 patsy: 0.3.0 dateutil: 2.4.2 pytz: 2015.4 bottleneck: 1.0.0 tables: 3.2.0 numexpr: 2.4.3 matplotlib: 1.4.3 openpyxl: 1.8.5 xlrd: 0.9.3 xlwt: 1.0.0 xlsxwriter: 0.7.3 lxml: 3.4.4 bs4: 4.3.2 html5lib: None httplib2: None apiclient: None sqlalchemy: 1.0.5 pymysql: None psycopg2: None </details>
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/pandas-dev/pandas/issues/13303/reactions" }
https://api.github.com/repos/pandas-dev/pandas/issues/13303/timeline
null
null
null