{"action":"created","issue":{"url":"https://api.github.com/repos/Turfjs/turf/issues/1122","repository_url":"https://api.github.com/repos/Turfjs/turf","labels_url":"https://api.github.com/repos/Turfjs/turf/issues/1122/labels{/name}","comments_url":"https://api.github.com/repos/Turfjs/turf/issues/1122/comments","events_url":"https://api.github.com/repos/Turfjs/turf/issues/1122/events","html_url":"https://github.com/Turfjs/turf/pull/1122","id":276767143,"number":1122,"title":"New module: Center median","user":{"login":"muziejus","id":827683,"avatar_url":"https://avatars3.githubusercontent.com/u/827683?v=4","gravatar_id":"","url":"https://api.github.com/users/muziejus","html_url":"https://github.com/muziejus","followers_url":"https://api.github.com/users/muziejus/followers","following_url":"https://api.github.com/users/muziejus/following{/other_user}","gists_url":"https://api.github.com/users/muziejus/gists{/gist_id}","starred_url":"https://api.github.com/users/muziejus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/muziejus/subscriptions","organizations_url":"https://api.github.com/users/muziejus/orgs","repos_url":"https://api.github.com/users/muziejus/repos","events_url":"https://api.github.com/users/muziejus/events{/privacy}","received_events_url":"https://api.github.com/users/muziejus/received_events","type":"User","site_admin":false},"labels":[{"id":333790692,"url":"https://api.github.com/repos/Turfjs/turf/labels/new-module","name":"new-module","color":"009800","default":false}],"state":"open","locked":false,"assignee":{"login":"muziejus","id":827683,"avatar_url":"https://avatars3.githubusercontent.com/u/827683?v=4","gravatar_id":"","url":"https://api.github.com/users/muziejus","html_url":"https://github.com/muziejus","followers_url":"https://api.github.com/users/muziejus/followers","following_url":"https://api.github.com/users/muziejus/following{/other_user}","gists_url":"https://api.github.com/users/muziejus/gists{/gist_id}","starred_url":"https://api.github.com/users/muziejus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/muziejus/subscriptions","organizations_url":"https://api.github.com/users/muziejus/orgs","repos_url":"https://api.github.com/users/muziejus/repos","events_url":"https://api.github.com/users/muziejus/events{/privacy}","received_events_url":"https://api.github.com/users/muziejus/received_events","type":"User","site_admin":false},"assignees":[{"login":"muziejus","id":827683,"avatar_url":"https://avatars3.githubusercontent.com/u/827683?v=4","gravatar_id":"","url":"https://api.github.com/users/muziejus","html_url":"https://github.com/muziejus","followers_url":"https://api.github.com/users/muziejus/followers","following_url":"https://api.github.com/users/muziejus/following{/other_user}","gists_url":"https://api.github.com/users/muziejus/gists{/gist_id}","starred_url":"https://api.github.com/users/muziejus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/muziejus/subscriptions","organizations_url":"https://api.github.com/users/muziejus/orgs","repos_url":"https://api.github.com/users/muziejus/repos","events_url":"https://api.github.com/users/muziejus/events{/privacy}","received_events_url":"https://api.github.com/users/muziejus/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/Turfjs/turf/milestones/13","html_url":"https://github.com/Turfjs/turf/milestone/13","labels_url":"https://api.github.com/repos/Turfjs/turf/milestones/13/labels","id":2798407,"number":13,"title":"5.1.0","description":"Minor release: patches, new features & new modules","creator":{"login":"DenisCarriere","id":550895,"avatar_url":"https://avatars3.githubusercontent.com/u/550895?v=4","gravatar_id":"","url":"https://api.github.com/users/DenisCarriere","html_url":"https://github.com/DenisCarriere","followers_url":"https://api.github.com/users/DenisCarriere/followers","following_url":"https://api.github.com/users/DenisCarriere/following{/other_user}","gists_url":"https://api.github.com/users/DenisCarriere/gists{/gist_id}","starred_url":"https://api.github.com/users/DenisCarriere/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DenisCarriere/subscriptions","organizations_url":"https://api.github.com/users/DenisCarriere/orgs","repos_url":"https://api.github.com/users/DenisCarriere/repos","events_url":"https://api.github.com/users/DenisCarriere/events{/privacy}","received_events_url":"https://api.github.com/users/DenisCarriere/received_events","type":"User","site_admin":false},"open_issues":8,"closed_issues":32,"state":"open","created_at":"2017-09-27T17:54:39Z","updated_at":"2017-11-25T22:50:05Z","due_on":null,"closed_at":null},"comments":3,"created_at":"2017-11-25T18:05:00Z","updated_at":"2017-11-26T05:59:18Z","closed_at":null,"author_association":"COLLABORATOR","pull_request":{"url":"https://api.github.com/repos/Turfjs/turf/pulls/1122","html_url":"https://github.com/Turfjs/turf/pull/1122","diff_url":"https://github.com/Turfjs/turf/pull/1122.diff","patch_url":"https://github.com/Turfjs/turf/pull/1122.patch"},"body":"This module algorithimically calculates the median center of a set of points. This is less sensitive to outliers. It can take a weight, like `@turf/center-mean`, and it also takes a `tolerance`, which is the minimum difference between candidate median centers that the algorithm will tolerate. The weighted tests are weird, and the Ukraine problem in Kuhn and Kuenne has at least one mistake in the data input (the latitude--at least--for Xarxiv is wrong). The solution to the Steiner problem is also not quite correct because it looks like Kuhn and Kuenne truncate their candidate's coordinates with every iteration. But the green marker ends up in the right place, more or less, all the same. Below, red is the mean center and green is the median center.\r\n\r\n<img width=\"704\" alt=\"screen shot 2017-11-25 at 12 50 11\" src=\"https://user-images.githubusercontent.com/827683/33233260-f6523e0a-d1e0-11e7-91c2-54d1d4f01209.png\">\r\nSquare coordinates\r\n\r\n<img width=\"396\" alt=\"screen shot 2017-11-25 at 12 49 43\" src=\"https://user-images.githubusercontent.com/827683/33233257-e02321bc-d1e0-11e7-8ab4-cd0d53d1575f.png\">\r\nSteiner's problem\r\n\r\n<img width=\"409\" alt=\"screen shot 2017-11-25 at 13 03 53\" src=\"https://user-images.githubusercontent.com/827683/33233268-244dd8be-d1e1-11e7-9a38-bb137418836c.png\">\r\nSteiner's problem w/ v. low tolerance\r\n\r\n<img width=\"453\" alt=\"screen shot 2017-11-25 at 12 50 33\" src=\"https://user-images.githubusercontent.com/827683/33233272-2fd874e6-d1e1-11e7-852f-e408c66c9cae.png\">\r\nUkraine problem.\r\n\r\n\r\n- [x] Use a meaningful title for the pull request. Include the name of the package modified.\r\n- [x] Have read [How To Contribute](https://github.com/Turfjs/turf/blob/master/CONTRIBUTING.md#how-to-contribute).\r\n- [x] Run `npm test` at the sub modules where changes have occurred.\r\n- [x] Run `npm run lint` to ensure code style at the turf module level.\r\n\r\nSubmitting a new TurfJS Module.\r\n\r\n- [x] Overview description of proposed module.\r\n- [x] Include JSDocs with a basic example.\r\n- [x] Execute `./scripts/generate-readmes` to create `README.md`.\r\n- [x] Add yourself to **contributors** in `package.json` using \"Full Name <@GitHub Username>\".\r\n"},"comment":{"url":"https://api.github.com/repos/Turfjs/turf/issues/comments/346986503","html_url":"https://github.com/Turfjs/turf/pull/1122#issuecomment-346986503","issue_url":"https://api.github.com/repos/Turfjs/turf/issues/1122","id":346986503,"user":{"login":"muziejus","id":827683,"avatar_url":"https://avatars3.githubusercontent.com/u/827683?v=4","gravatar_id":"","url":"https://api.github.com/users/muziejus","html_url":"https://github.com/muziejus","followers_url":"https://api.github.com/users/muziejus/followers","following_url":"https://api.github.com/users/muziejus/following{/other_user}","gists_url":"https://api.github.com/users/muziejus/gists{/gist_id}","starred_url":"https://api.github.com/users/muziejus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/muziejus/subscriptions","organizations_url":"https://api.github.com/users/muziejus/orgs","repos_url":"https://api.github.com/users/muziejus/repos","events_url":"https://api.github.com/users/muziejus/events{/privacy}","received_events_url":"https://api.github.com/users/muziejus/received_events","type":"User","site_admin":false},"created_at":"2017-11-26T05:59:18Z","updated_at":"2017-11-26T05:59:18Z","author_association":"COLLABORATOR","body":"@stebogit I've updated the README to discuss the four different center functions in turf. If we all (@DenisCarriere?) settle on a kind of boilerplate, I think we can include it in all four of the functions. IMO, this image does a good job of showing the four different functions.\r\n\r\nblue: `@turf/center`\r\ngray: `@turf/center-of-mass`\r\nred: `@turf/center-mean` (unweighted)\r\ngreen: `@turf/center-median` (unweighted)\r\n<img width=\"391\" alt=\"screen shot 2017-11-26 at 00 57 21\" src=\"https://user-images.githubusercontent.com/827683/33237565-f302ed08-d244-11e7-8635-400f551195f2.png\">\r\n\r\n"}}
{"actor":{"display_login":"muziejus"}}