{"action":"created","issue":{"url":"https://api.github.com/repos/pydata/pandas/issues/10949","labels_url":"https://api.github.com/repos/pydata/pandas/issues/10949/labels{/name}","comments_url":"https://api.github.com/repos/pydata/pandas/issues/10949/comments","events_url":"https://api.github.com/repos/pydata/pandas/issues/10949/events","html_url":"https://github.com/pydata/pandas/issues/10949","id":104057043,"number":10949,"title":"ENH: density of a categorical","user":{"login":"jreback","id":953992,"avatar_url":"https://avatars.githubusercontent.com/u/953992?v=3","gravatar_id":"","url":"https://api.github.com/users/jreback","html_url":"https://github.com/jreback","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}","starred_url":"https://api.github.com/users/jreback/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jreback/subscriptions","organizations_url":"https://api.github.com/users/jreback/orgs","repos_url":"https://api.github.com/users/jreback/repos","events_url":"https://api.github.com/users/jreback/events{/privacy}","received_events_url":"https://api.github.com/users/jreback/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/pydata/pandas/labels/Categorical","name":"Categorical","color":"e11d21"},{"url":"https://api.github.com/repos/pydata/pandas/labels/Difficulty%20Novice","name":"Difficulty Novice","color":"fbca04"},{"url":"https://api.github.com/repos/pydata/pandas/labels/Effort%20Low","name":"Effort Low","color":"006b75"},{"url":"https://api.github.com/repos/pydata/pandas/labels/Enhancement","name":"Enhancement","color":"4E9A06"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/pydata/pandas/milestones/37","html_url":"https://github.com/pydata/pandas/milestones/0.17.1","labels_url":"https://api.github.com/repos/pydata/pandas/milestones/37/labels","id":1299459,"number":37,"title":"0.17.1","description":"after 0.17.0 of course!","creator":{"login":"jreback","id":953992,"avatar_url":"https://avatars.githubusercontent.com/u/953992?v=3","gravatar_id":"","url":"https://api.github.com/users/jreback","html_url":"https://github.com/jreback","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}","starred_url":"https://api.github.com/users/jreback/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jreback/subscriptions","organizations_url":"https://api.github.com/users/jreback/orgs","repos_url":"https://api.github.com/users/jreback/repos","events_url":"https://api.github.com/users/jreback/events{/privacy}","received_events_url":"https://api.github.com/users/jreback/received_events","type":"User","site_admin":false},"open_issues":47,"closed_issues":20,"state":"open","created_at":"2015-09-10T14:30:44Z","updated_at":"2015-10-11T16:07:15Z","due_on":"2015-11-14T05:00:00Z","closed_at":null},"comments":6,"created_at":"2015-08-31T13:48:14Z","updated_at":"2015-10-12T07:17:29Z","closed_at":null,"body":"I think ``s.cat.density`` is appropriate here\r\n\r\n```\r\nIn [1]: s = Series(list('aabbcccc')).astype('category')\r\n\r\nIn [2]: 100*len(s.cat.categories)/len(s)\r\nOut[2]: 37\r\n```"},"comment":{"url":"https://api.github.com/repos/pydata/pandas/issues/comments/147309361","html_url":"https://github.com/pydata/pandas/issues/10949#issuecomment-147309361","issue_url":"https://api.github.com/repos/pydata/pandas/issues/10949","id":147309361,"user":{"login":"shoyer","id":1217238,"avatar_url":"https://avatars.githubusercontent.com/u/1217238?v=3","gravatar_id":"","url":"https://api.github.com/users/shoyer","html_url":"https://github.com/shoyer","followers_url":"https://api.github.com/users/shoyer/followers","following_url":"https://api.github.com/users/shoyer/following{/other_user}","gists_url":"https://api.github.com/users/shoyer/gists{/gist_id}","starred_url":"https://api.github.com/users/shoyer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shoyer/subscriptions","organizations_url":"https://api.github.com/users/shoyer/orgs","repos_url":"https://api.github.com/users/shoyer/repos","events_url":"https://api.github.com/users/shoyer/events{/privacy}","received_events_url":"https://api.github.com/users/shoyer/received_events","type":"User","site_admin":false},"created_at":"2015-10-12T07:17:29Z","updated_at":"2015-10-12T07:17:29Z","body":"I'm also not convinced this is necessary -- what's the use case here?"}}