{"action":"created","issue":{"url":"https://api.github.com/repos/numpy/numpy/issues/7875","repository_url":"https://api.github.com/repos/numpy/numpy","labels_url":"https://api.github.com/repos/numpy/numpy/issues/7875/labels{/name}","comments_url":"https://api.github.com/repos/numpy/numpy/issues/7875/comments","events_url":"https://api.github.com/repos/numpy/numpy/issues/7875/events","html_url":"https://github.com/numpy/numpy/issues/7875","id":167809613,"number":7875,"title":"Percentile Linear returns incorrect value. ","user":{"login":"mikep2016","id":20679722,"avatar_url":"https://avatars.githubusercontent.com/u/20679722?v=3","gravatar_id":"","url":"https://api.github.com/users/mikep2016","html_url":"https://github.com/mikep2016","followers_url":"https://api.github.com/users/mikep2016/followers","following_url":"https://api.github.com/users/mikep2016/following{/other_user}","gists_url":"https://api.github.com/users/mikep2016/gists{/gist_id}","starred_url":"https://api.github.com/users/mikep2016/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikep2016/subscriptions","organizations_url":"https://api.github.com/users/mikep2016/orgs","repos_url":"https://api.github.com/users/mikep2016/repos","events_url":"https://api.github.com/users/mikep2016/events{/privacy}","received_events_url":"https://api.github.com/users/mikep2016/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":12,"created_at":"2016-07-27T09:25:28Z","updated_at":"2016-07-29T18:27:46Z","closed_at":null,"body":"The percentile function does not return the expected values. It seems to be getting the linear distance between two points the wrong way around and returns a value closer to the lower number.\r\n\r\n\r\nFor example:\r\n\r\narray([   110531353,    167471747,    167471747,    183000406,\r\n          200000000,    759174457,    921094606,    931142911,\r\n         1300000000,   1341797102,   1380317195,   1380317195,\r\n         1500000000,   1500000000,   1500000000,   1830004057,\r\n         1932444073,   2000000000,   2000000000, 2345976525, 2500000000,\r\n       2745006085, 2847019692, 3000000000, 3000000000, 3000000000,\r\n       3000000000, 3312761268, 3500000000, 3588824707, 4000000000,\r\n       4140951585, 5000000000, 6600000000, 7100000000, 7717299940,\r\n       8445515490, 8972061767, 9662220364, 11000000000, 11042537559,\r\n       12422854754, 13000000000, 13000000000, 13803171949, 15000000000,\r\n       17000000000, 20000000000, 22085075118, 24845709508, 32025070994,\r\n       34000000000, 35000000000, 36000000000, 36000000000, 39453076027,\r\n       40000000000, 46930784627, 82819031694, 110425375592], dtype=int64)\r\n\r\n\r\n>>> np.percentile(a,75)\r\n14102378961.75\r\n>>> np.percentile(a,50)\r\n3794412353.5\r\n>>> np.percentile(a,25)\r\n1747503042.75\r\n\r\nexpected values:\r\n75 = 14700792987.25\r\n50 = 3794412353.5\r\n25 = 1582501014.25\r\n\r\n\r\nWhen reading the documentation the linear methodology seems correct but there possibly could be an issue with the fraction it is using??\r\n\r\n \r\n"},"comment":{"url":"https://api.github.com/repos/numpy/numpy/issues/comments/236257537","html_url":"https://github.com/numpy/numpy/issues/7875#issuecomment-236257537","issue_url":"https://api.github.com/repos/numpy/numpy/issues/7875","id":236257537,"user":{"login":"seberg","id":61977,"avatar_url":"https://avatars.githubusercontent.com/u/61977?v=3","gravatar_id":"","url":"https://api.github.com/users/seberg","html_url":"https://github.com/seberg","followers_url":"https://api.github.com/users/seberg/followers","following_url":"https://api.github.com/users/seberg/following{/other_user}","gists_url":"https://api.github.com/users/seberg/gists{/gist_id}","starred_url":"https://api.github.com/users/seberg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seberg/subscriptions","organizations_url":"https://api.github.com/users/seberg/orgs","repos_url":"https://api.github.com/users/seberg/repos","events_url":"https://api.github.com/users/seberg/events{/privacy}","received_events_url":"https://api.github.com/users/seberg/received_events","type":"User","site_admin":false},"created_at":"2016-07-29T18:27:45Z","updated_at":"2016-07-29T18:27:45Z","body":"R has nine different percentile types, and I doubt it covers all of these combinations.... It would be nice to clean it up for good, but we really need someone who knows this very well...."}}
{"actor":{"display_login":"seberg"}}