sjewo / cartogram

r package for cartogram creation
https://sjewo.github.io/cartogram/
148 stars 15 forks source link

Dorling Cartogram #2

Closed sjewo closed 6 years ago

sjewo commented 8 years ago

Add Dorling Cartograms

rCarto commented 6 years ago

Hi @sjewo , can you have a look at this implementation of dorling cartograms : https://gist.github.com/rCarto/3e1695c358cb898ad3fc6b939b875a7b ? If you are ok to add it in cartogram, I have a PR ready in my fork. The major change for the package would be to add packcircles in Imports.

rplot

I have tried to adapt @hrbrmstr spdorling package first (to allow sf input/output and use sf internaly) (see https://gist.github.com/rCarto/372977dd59f64b91b7e2b3e512ada159). But the solution with packcircles is much faster and IMO more configurable (see the weights argument).

Let me know.

hrbrmstr commented 6 years ago

this is way cool!

sjewo commented 6 years ago

Hi @rCarto , this would be a great addition to the package!

I'll have a look at your code this weekend.

sjewo commented 6 years ago

Hi @rCarto !

Thanks for your pull request - I think adding packcircles should be fine.