{"action":"created","comment":{"url":"https://api.github.com/repos/geopandas/geopandas/pulls/comments/351696285","pull_request_review_id":324184262,"id":351696285,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDM1MTY5NjI4NQ==","diff_hunk":"@@ -340,16 +337,22 @@ def plot_series(s, cmap=None, color=None, ax=None, figsize=None, **style_kwds):\n         style_kwds[\"vmin\"] = style_kwds.get(\"vmin\", values.min())\n         style_kwds[\"vmax\"] = style_kwds.get(\"vmax\", values.max())\n \n-    geom_types = s.geometry.type\n+    # decompose GeometryCollections\n+    geoms, multiindex = _flatten_multi_geoms(s.geometry, prefix=\"Geom\")\n+    values = np.take(values, multiindex, axis=0) if cmap else None\n+    expl_series = gpd.GeoSeries(geoms)","path":"geopandas/plotting.py","position":98,"original_position":98,"commit_id":"97101d3fa8dc098067d37a32c2cbf9f673c7b698","original_commit_id":"97101d3fa8dc098067d37a32c2cbf9f673c7b698","user":{"login":"martinfleis","id":36797143,"node_id":"MDQ6VXNlcjM2Nzk3MTQz","avatar_url":"https://avatars2.githubusercontent.com/u/36797143?v=4","gravatar_id":"","url":"https://api.github.com/users/martinfleis","html_url":"https://github.com/martinfleis","followers_url":"https://api.github.com/users/martinfleis/followers","following_url":"https://api.github.com/users/martinfleis/following{/other_user}","gists_url":"https://api.github.com/users/martinfleis/gists{/gist_id}","starred_url":"https://api.github.com/users/martinfleis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/martinfleis/subscriptions","organizations_url":"https://api.github.com/users/martinfleis/orgs","repos_url":"https://api.github.com/users/martinfleis/repos","events_url":"https://api.github.com/users/martinfleis/events{/privacy}","received_events_url":"https://api.github.com/users/martinfleis/received_events","type":"User","site_admin":false},"body":"I tried to make couple more changes to use GeometryArray, but it breaks the code at multiple places. I would keep GeoSeries there, but I am not aware how to import it without using `import geopandas` here.","created_at":"2019-11-28T10:18:40Z","updated_at":"2019-11-28T10:18:40Z","html_url":"https://github.com/geopandas/geopandas/pull/1225#discussion_r351696285","pull_request_url":"https://api.github.com/repos/geopandas/geopandas/pulls/1225","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/geopandas/geopandas/pulls/comments/351696285"},"html":{"href":"https://github.com/geopandas/geopandas/pull/1225#discussion_r351696285"},"pull_request":{"href":"https://api.github.com/repos/geopandas/geopandas/pulls/1225"}},"in_reply_to_id":351636455},"pull_request":{"url":"https://api.github.com/repos/geopandas/geopandas/pulls/1225","id":346423814,"node_id":"MDExOlB1bGxSZXF1ZXN0MzQ2NDIzODE0","html_url":"https://github.com/geopandas/geopandas/pull/1225","diff_url":"https://github.com/geopandas/geopandas/pull/1225.diff","patch_url":"https://github.com/geopandas/geopandas/pull/1225.patch","issue_url":"https://api.github.com/repos/geopandas/geopandas/issues/1225","number":1225,"state":"open","locked":false,"title":"ENH: support GeometryCollection and LinearRing in plotting","user":{"login":"martinfleis","id":36797143,"node_id":"MDQ6VXNlcjM2Nzk3MTQz","avatar_url":"https://avatars2.githubusercontent.com/u/36797143?v=4","gravatar_id":"","url":"https://api.github.com/users/martinfleis","html_url":"https://github.com/martinfleis","followers_url":"https://api.github.com/users/martinfleis/followers","following_url":"https://api.github.com/users/martinfleis/following{/other_user}","gists_url":"https://api.github.com/users/martinfleis/gists{/gist_id}","starred_url":"https://api.github.com/users/martinfleis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/martinfleis/subscriptions","organizations_url":"https://api.github.com/users/martinfleis/orgs","repos_url":"https://api.github.com/users/martinfleis/repos","events_url":"https://api.github.com/users/martinfleis/events{/privacy}","received_events_url":"https://api.github.com/users/martinfleis/received_events","type":"User","site_admin":false},"body":"Added support for GeometryCollections and LinearRings in `.plot()` for both GeoSeries and GeoDataFrame. As you can see, it first decomposes GeometryCollections  in `plot_dataframe` and then explodes MultiGeometries in `plot_XX_collection` as it did till now. I was thinking about decomposing everything at once, but since we can get MultiGeometry inside GeometryCollection,  we would have to do the check twice anyway. This way is seems to be more understandable for future maintenance.\r\n\r\nAs I am using `_flatten_multi_geoms` to decompose both Multi and GeometryCollections now, I have slightly changed it, so we can select what to decompose. And as we already returned multiindex instead of actual values, I have removed color attribute.\r\n\r\nLinearRings are easy, they can be plotted exactly the same way as LineStrings.\r\n\r\nCloses #953","created_at":"2019-11-27T21:00:49Z","updated_at":"2019-11-28T10:18:40Z","closed_at":null,"merged_at":null,"merge_commit_sha":"03ef14101ea4da198842174e1eabb26e46ddba2a","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":398135286,"node_id":"MDU6TGFiZWwzOTgxMzUyODY=","url":"https://api.github.com/repos/geopandas/geopandas/labels/plotting","name":"plotting","color":"0e8a16","default":false,"description":null}],"milestone":{"url":"https://api.github.com/repos/geopandas/geopandas/milestones/10","html_url":"https://github.com/geopandas/geopandas/milestone/10","labels_url":"https://api.github.com/repos/geopandas/geopandas/milestones/10/labels","id":4730011,"node_id":"MDk6TWlsZXN0b25lNDczMDAxMQ==","number":10,"title":"0.7.0","description":null,"creator":{"login":"jorisvandenbossche","id":1020496,"node_id":"MDQ6VXNlcjEwMjA0OTY=","avatar_url":"https://avatars2.githubusercontent.com/u/1020496?v=4","gravatar_id":"","url":"https://api.github.com/users/jorisvandenbossche","html_url":"https://github.com/jorisvandenbossche","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}","starred_url":"https://api.github.com/users/jorisvandenbossche/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jorisvandenbossche/subscriptions","organizations_url":"https://api.github.com/users/jorisvandenbossche/orgs","repos_url":"https://api.github.com/users/jorisvandenbossche/repos","events_url":"https://api.github.com/users/jorisvandenbossche/events{/privacy}","received_events_url":"https://api.github.com/users/jorisvandenbossche/received_events","type":"User","site_admin":false},"open_issues":9,"closed_issues":1,"state":"open","created_at":"2019-10-07T22:19:34Z","updated_at":"2019-11-27T21:00:49Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/geopandas/geopandas/pulls/1225/commits","review_comments_url":"https://api.github.com/repos/geopandas/geopandas/pulls/1225/comments","review_comment_url":"https://api.github.com/repos/geopandas/geopandas/pulls/comments{/number}","comments_url":"https://api.github.com/repos/geopandas/geopandas/issues/1225/comments","statuses_url":"https://api.github.com/repos/geopandas/geopandas/statuses/97101d3fa8dc098067d37a32c2cbf9f673c7b698","head":{"label":"martinfleis:geometry_collection_plot","ref":"geometry_collection_plot","sha":"97101d3fa8dc098067d37a32c2cbf9f673c7b698","user":{"login":"martinfleis","id":36797143,"node_id":"MDQ6VXNlcjM2Nzk3MTQz","avatar_url":"https://avatars2.githubusercontent.com/u/36797143?v=4","gravatar_id":"","url":"https://api.github.com/users/martinfleis","html_url":"https://github.com/martinfleis","followers_url":"https://api.github.com/users/martinfleis/followers","following_url":"https://api.github.com/users/martinfleis/following{/other_user}","gists_url":"https://api.github.com/users/martinfleis/gists{/gist_id}","starred_url":"https://api.github.com/users/martinfleis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/martinfleis/subscriptions","organizations_url":"https://api.github.com/users/martinfleis/orgs","repos_url":"https://api.github.com/users/martinfleis/repos","events_url":"https://api.github.com/users/martinfleis/events{/privacy}","received_events_url":"https://api.github.com/users/martinfleis/received_events","type":"User","site_admin":false},"repo":{"id":160849341,"node_id":"MDEwOlJlcG9zaXRvcnkxNjA4NDkzNDE=","name":"geopandas","full_name":"martinfleis/geopandas","private":false,"owner":{"login":"martinfleis","id":36797143,"node_id":"MDQ6VXNlcjM2Nzk3MTQz","avatar_url":"https://avatars2.githubusercontent.com/u/36797143?v=4","gravatar_id":"","url":"https://api.github.com/users/martinfleis","html_url":"https://github.com/martinfleis","followers_url":"https://api.github.com/users/martinfleis/followers","following_url":"https://api.github.com/users/martinfleis/following{/other_user}","gists_url":"https://api.github.com/users/martinfleis/gists{/gist_id}","starred_url":"https://api.github.com/users/martinfleis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/martinfleis/subscriptions","organizations_url":"https://api.github.com/users/martinfleis/orgs","repos_url":"https://api.github.com/users/martinfleis/repos","events_url":"https://api.github.com/users/martinfleis/events{/privacy}","received_events_url":"https://api.github.com/users/martinfleis/received_events","type":"User","site_admin":false},"html_url":"https://github.com/martinfleis/geopandas","description":"Python tools for geographic data","fork":true,"url":"https://api.github.com/repos/martinfleis/geopandas","forks_url":"https://api.github.com/repos/martinfleis/geopandas/forks","keys_url":"https://api.github.com/repos/martinfleis/geopandas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/martinfleis/geopandas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/martinfleis/geopandas/teams","hooks_url":"https://api.github.com/repos/martinfleis/geopandas/hooks","issue_events_url":"https://api.github.com/repos/martinfleis/geopandas/issues/events{/number}","events_url":"https://api.github.com/repos/martinfleis/geopandas/events","assignees_url":"https://api.github.com/repos/martinfleis/geopandas/assignees{/user}","branches_url":"https://api.github.com/repos/martinfleis/geopandas/branches{/branch}","tags_url":"https://api.github.com/repos/martinfleis/geopandas/tags","blobs_url":"https://api.github.com/repos/martinfleis/geopandas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/martinfleis/geopandas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/martinfleis/geopandas/git/refs{/sha}","trees_url":"https://api.github.com/repos/martinfleis/geopandas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/martinfleis/geopandas/statuses/{sha}","languages_url":"https://api.github.com/repos/martinfleis/geopandas/languages","stargazers_url":"https://api.github.com/repos/martinfleis/geopandas/stargazers","contributors_url":"https://api.github.com/repos/martinfleis/geopandas/contributors","subscribers_url":"https://api.github.com/repos/martinfleis/geopandas/subscribers","subscription_url":"https://api.github.com/repos/martinfleis/geopandas/subscription","commits_url":"https://api.github.com/repos/martinfleis/geopandas/commits{/sha}","git_commits_url":"https://api.github.com/repos/martinfleis/geopandas/git/commits{/sha}","comments_url":"https://api.github.com/repos/martinfleis/geopandas/comments{/number}","issue_comment_url":"https://api.github.com/repos/martinfleis/geopandas/issues/comments{/number}","contents_url":"https://api.github.com/repos/martinfleis/geopandas/contents/{+path}","compare_url":"https://api.github.com/repos/martinfleis/geopandas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/martinfleis/geopandas/merges","archive_url":"https://api.github.com/repos/martinfleis/geopandas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/martinfleis/geopandas/downloads","issues_url":"https://api.github.com/repos/martinfleis/geopandas/issues{/number}","pulls_url":"https://api.github.com/repos/martinfleis/geopandas/pulls{/number}","milestones_url":"https://api.github.com/repos/martinfleis/geopandas/milestones{/number}","notifications_url":"https://api.github.com/repos/martinfleis/geopandas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/martinfleis/geopandas/labels{/name}","releases_url":"https://api.github.com/repos/martinfleis/geopandas/releases{/id}","deployments_url":"https://api.github.com/repos/martinfleis/geopandas/deployments","created_at":"2018-12-07T16:34:44Z","updated_at":"2019-11-27T09:45:21Z","pushed_at":"2019-11-27T21:41:37Z","git_url":"git://github.com/martinfleis/geopandas.git","ssh_url":"git@github.com:martinfleis/geopandas.git","clone_url":"https://github.com/martinfleis/geopandas.git","svn_url":"https://github.com/martinfleis/geopandas","homepage":"http://geopandas.readthedocs.io/","size":23392,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"disabled":false,"open_issues_count":0,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause","node_id":"MDc6TGljZW5zZTU="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"geopandas:master","ref":"master","sha":"6ac19052c811b39fea88b40625c69246f733709d","user":{"login":"geopandas","id":8130715,"node_id":"MDEyOk9yZ2FuaXphdGlvbjgxMzA3MTU=","avatar_url":"https://avatars2.githubusercontent.com/u/8130715?v=4","gravatar_id":"","url":"https://api.github.com/users/geopandas","html_url":"https://github.com/geopandas","followers_url":"https://api.github.com/users/geopandas/followers","following_url":"https://api.github.com/users/geopandas/following{/other_user}","gists_url":"https://api.github.com/users/geopandas/gists{/gist_id}","starred_url":"https://api.github.com/users/geopandas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/geopandas/subscriptions","organizations_url":"https://api.github.com/users/geopandas/orgs","repos_url":"https://api.github.com/users/geopandas/repos","events_url":"https://api.github.com/users/geopandas/events{/privacy}","received_events_url":"https://api.github.com/users/geopandas/received_events","type":"Organization","site_admin":false},"repo":{"id":11002815,"node_id":"MDEwOlJlcG9zaXRvcnkxMTAwMjgxNQ==","name":"geopandas","full_name":"geopandas/geopandas","private":false,"owner":{"login":"geopandas","id":8130715,"node_id":"MDEyOk9yZ2FuaXphdGlvbjgxMzA3MTU=","avatar_url":"https://avatars2.githubusercontent.com/u/8130715?v=4","gravatar_id":"","url":"https://api.github.com/users/geopandas","html_url":"https://github.com/geopandas","followers_url":"https://api.github.com/users/geopandas/followers","following_url":"https://api.github.com/users/geopandas/following{/other_user}","gists_url":"https://api.github.com/users/geopandas/gists{/gist_id}","starred_url":"https://api.github.com/users/geopandas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/geopandas/subscriptions","organizations_url":"https://api.github.com/users/geopandas/orgs","repos_url":"https://api.github.com/users/geopandas/repos","events_url":"https://api.github.com/users/geopandas/events{/privacy}","received_events_url":"https://api.github.com/users/geopandas/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/geopandas/geopandas","description":"Python tools for geographic data","fork":false,"url":"https://api.github.com/repos/geopandas/geopandas","forks_url":"https://api.github.com/repos/geopandas/geopandas/forks","keys_url":"https://api.github.com/repos/geopandas/geopandas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/geopandas/geopandas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/geopandas/geopandas/teams","hooks_url":"https://api.github.com/repos/geopandas/geopandas/hooks","issue_events_url":"https://api.github.com/repos/geopandas/geopandas/issues/events{/number}","events_url":"https://api.github.com/repos/geopandas/geopandas/events","assignees_url":"https://api.github.com/repos/geopandas/geopandas/assignees{/user}","branches_url":"https://api.github.com/repos/geopandas/geopandas/branches{/branch}","tags_url":"https://api.github.com/repos/geopandas/geopandas/tags","blobs_url":"https://api.github.com/repos/geopandas/geopandas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/geopandas/geopandas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/geopandas/geopandas/git/refs{/sha}","trees_url":"https://api.github.com/repos/geopandas/geopandas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/geopandas/geopandas/statuses/{sha}","languages_url":"https://api.github.com/repos/geopandas/geopandas/languages","stargazers_url":"https://api.github.com/repos/geopandas/geopandas/stargazers","contributors_url":"https://api.github.com/repos/geopandas/geopandas/contributors","subscribers_url":"https://api.github.com/repos/geopandas/geopandas/subscribers","subscription_url":"https://api.github.com/repos/geopandas/geopandas/subscription","commits_url":"https://api.github.com/repos/geopandas/geopandas/commits{/sha}","git_commits_url":"https://api.github.com/repos/geopandas/geopandas/git/commits{/sha}","comments_url":"https://api.github.com/repos/geopandas/geopandas/comments{/number}","issue_comment_url":"https://api.github.com/repos/geopandas/geopandas/issues/comments{/number}","contents_url":"https://api.github.com/repos/geopandas/geopandas/contents/{+path}","compare_url":"https://api.github.com/repos/geopandas/geopandas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/geopandas/geopandas/merges","archive_url":"https://api.github.com/repos/geopandas/geopandas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/geopandas/geopandas/downloads","issues_url":"https://api.github.com/repos/geopandas/geopandas/issues{/number}","pulls_url":"https://api.github.com/repos/geopandas/geopandas/pulls{/number}","milestones_url":"https://api.github.com/repos/geopandas/geopandas/milestones{/number}","notifications_url":"https://api.github.com/repos/geopandas/geopandas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/geopandas/geopandas/labels{/name}","releases_url":"https://api.github.com/repos/geopandas/geopandas/releases{/id}","deployments_url":"https://api.github.com/repos/geopandas/geopandas/deployments","created_at":"2013-06-27T17:03:47Z","updated_at":"2019-11-28T07:45:07Z","pushed_at":"2019-11-28T07:45:05Z","git_url":"git://github.com/geopandas/geopandas.git","ssh_url":"git@github.com:geopandas/geopandas.git","clone_url":"https://github.com/geopandas/geopandas.git","svn_url":"https://github.com/geopandas/geopandas","homepage":"http://geopandas.readthedocs.io/","size":26149,"stargazers_count":1820,"watchers_count":1820,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":437,"mirror_url":null,"archived":false,"disabled":false,"open_issues_count":245,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause","node_id":"MDc6TGljZW5zZTU="},"forks":437,"open_issues":245,"watchers":1820,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/geopandas/geopandas/pulls/1225"},"html":{"href":"https://github.com/geopandas/geopandas/pull/1225"},"issue":{"href":"https://api.github.com/repos/geopandas/geopandas/issues/1225"},"comments":{"href":"https://api.github.com/repos/geopandas/geopandas/issues/1225/comments"},"review_comments":{"href":"https://api.github.com/repos/geopandas/geopandas/pulls/1225/comments"},"review_comment":{"href":"https://api.github.com/repos/geopandas/geopandas/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/geopandas/geopandas/pulls/1225/commits"},"statuses":{"href":"https://api.github.com/repos/geopandas/geopandas/statuses/97101d3fa8dc098067d37a32c2cbf9f673c7b698"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"martinfleis"}}