{"action":"opened","number":48,"pull_request":{"url":"https://api.github.com/repos/benhamner/Metrics/pulls/48","id":198087935,"node_id":"MDExOlB1bGxSZXF1ZXN0MTk4MDg3OTM1","html_url":"https://github.com/benhamner/Metrics/pull/48","diff_url":"https://github.com/benhamner/Metrics/pull/48.diff","patch_url":"https://github.com/benhamner/Metrics/pull/48.patch","issue_url":"https://api.github.com/repos/benhamner/Metrics/issues/48","number":48,"state":"open","locked":false,"title":"Refactor auc to avoid multiplication","user":{"login":"Adam-Hoelscher","id":9209099,"node_id":"MDQ6VXNlcjkyMDkwOTk=","avatar_url":"https://avatars1.githubusercontent.com/u/9209099?v=4","gravatar_id":"","url":"https://api.github.com/users/Adam-Hoelscher","html_url":"https://github.com/Adam-Hoelscher","followers_url":"https://api.github.com/users/Adam-Hoelscher/followers","following_url":"https://api.github.com/users/Adam-Hoelscher/following{/other_user}","gists_url":"https://api.github.com/users/Adam-Hoelscher/gists{/gist_id}","starred_url":"https://api.github.com/users/Adam-Hoelscher/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Adam-Hoelscher/subscriptions","organizations_url":"https://api.github.com/users/Adam-Hoelscher/orgs","repos_url":"https://api.github.com/users/Adam-Hoelscher/repos","events_url":"https://api.github.com/users/Adam-Hoelscher/events{/privacy}","received_events_url":"https://api.github.com/users/Adam-Hoelscher/received_events","type":"User","site_admin":false},"body":"Multiplying n_pos and n_neg can result in integer overflow. A little algebraic manipulation can avoid the multiplication, removing the possibility of overflow.","created_at":"2018-06-28T16:37:38Z","updated_at":"2018-06-28T16:37:38Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/benhamner/Metrics/pulls/48/commits","review_comments_url":"https://api.github.com/repos/benhamner/Metrics/pulls/48/comments","review_comment_url":"https://api.github.com/repos/benhamner/Metrics/pulls/comments{/number}","comments_url":"https://api.github.com/repos/benhamner/Metrics/issues/48/comments","statuses_url":"https://api.github.com/repos/benhamner/Metrics/statuses/dd476e08897b408a7120d5f091a686657aee77ec","head":{"label":"Adam-Hoelscher:patch-1","ref":"patch-1","sha":"dd476e08897b408a7120d5f091a686657aee77ec","user":{"login":"Adam-Hoelscher","id":9209099,"node_id":"MDQ6VXNlcjkyMDkwOTk=","avatar_url":"https://avatars1.githubusercontent.com/u/9209099?v=4","gravatar_id":"","url":"https://api.github.com/users/Adam-Hoelscher","html_url":"https://github.com/Adam-Hoelscher","followers_url":"https://api.github.com/users/Adam-Hoelscher/followers","following_url":"https://api.github.com/users/Adam-Hoelscher/following{/other_user}","gists_url":"https://api.github.com/users/Adam-Hoelscher/gists{/gist_id}","starred_url":"https://api.github.com/users/Adam-Hoelscher/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Adam-Hoelscher/subscriptions","organizations_url":"https://api.github.com/users/Adam-Hoelscher/orgs","repos_url":"https://api.github.com/users/Adam-Hoelscher/repos","events_url":"https://api.github.com/users/Adam-Hoelscher/events{/privacy}","received_events_url":"https://api.github.com/users/Adam-Hoelscher/received_events","type":"User","site_admin":false},"repo":{"id":139043608,"node_id":"MDEwOlJlcG9zaXRvcnkxMzkwNDM2MDg=","name":"Metrics","full_name":"Adam-Hoelscher/Metrics","owner":{"login":"Adam-Hoelscher","id":9209099,"node_id":"MDQ6VXNlcjkyMDkwOTk=","avatar_url":"https://avatars1.githubusercontent.com/u/9209099?v=4","gravatar_id":"","url":"https://api.github.com/users/Adam-Hoelscher","html_url":"https://github.com/Adam-Hoelscher","followers_url":"https://api.github.com/users/Adam-Hoelscher/followers","following_url":"https://api.github.com/users/Adam-Hoelscher/following{/other_user}","gists_url":"https://api.github.com/users/Adam-Hoelscher/gists{/gist_id}","starred_url":"https://api.github.com/users/Adam-Hoelscher/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Adam-Hoelscher/subscriptions","organizations_url":"https://api.github.com/users/Adam-Hoelscher/orgs","repos_url":"https://api.github.com/users/Adam-Hoelscher/repos","events_url":"https://api.github.com/users/Adam-Hoelscher/events{/privacy}","received_events_url":"https://api.github.com/users/Adam-Hoelscher/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Adam-Hoelscher/Metrics","description":"Machine learning evaluation metrics, implemented in Python, R, Haskell, and MATLAB / Octave","fork":true,"url":"https://api.github.com/repos/Adam-Hoelscher/Metrics","forks_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/forks","keys_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/teams","hooks_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/hooks","issue_events_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/issues/events{/number}","events_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/events","assignees_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/assignees{/user}","branches_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/branches{/branch}","tags_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/tags","blobs_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/git/refs{/sha}","trees_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/statuses/{sha}","languages_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/languages","stargazers_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/stargazers","contributors_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/contributors","subscribers_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/subscribers","subscription_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/subscription","commits_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/commits{/sha}","git_commits_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/git/commits{/sha}","comments_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/comments{/number}","issue_comment_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/issues/comments{/number}","contents_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/contents/{+path}","compare_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/merges","archive_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/downloads","issues_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/issues{/number}","pulls_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/pulls{/number}","milestones_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/milestones{/number}","notifications_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/labels{/name}","releases_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/releases{/id}","deployments_url":"https://api.github.com/repos/Adam-Hoelscher/Metrics/deployments","created_at":"2018-06-28T16:30:26Z","updated_at":"2018-06-28T16:30:28Z","pushed_at":"2018-06-28T16:37:12Z","git_url":"git://github.com/Adam-Hoelscher/Metrics.git","ssh_url":"git@github.com:Adam-Hoelscher/Metrics.git","clone_url":"https://github.com/Adam-Hoelscher/Metrics.git","svn_url":"https://github.com/Adam-Hoelscher/Metrics","homepage":"","size":803,"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,"open_issues_count":0,"license":{"key":"other","name":"Other","spdx_id":null,"url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"benhamner:master","ref":"master","sha":"9a637aea795dc6f2333f022b0863398de0a1ca77","user":{"login":"benhamner","id":582878,"node_id":"MDQ6VXNlcjU4Mjg3OA==","avatar_url":"https://avatars0.githubusercontent.com/u/582878?v=4","gravatar_id":"","url":"https://api.github.com/users/benhamner","html_url":"https://github.com/benhamner","followers_url":"https://api.github.com/users/benhamner/followers","following_url":"https://api.github.com/users/benhamner/following{/other_user}","gists_url":"https://api.github.com/users/benhamner/gists{/gist_id}","starred_url":"https://api.github.com/users/benhamner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benhamner/subscriptions","organizations_url":"https://api.github.com/users/benhamner/orgs","repos_url":"https://api.github.com/users/benhamner/repos","events_url":"https://api.github.com/users/benhamner/events{/privacy}","received_events_url":"https://api.github.com/users/benhamner/received_events","type":"User","site_admin":false},"repo":{"id":4639444,"node_id":"MDEwOlJlcG9zaXRvcnk0NjM5NDQ0","name":"Metrics","full_name":"benhamner/Metrics","owner":{"login":"benhamner","id":582878,"node_id":"MDQ6VXNlcjU4Mjg3OA==","avatar_url":"https://avatars0.githubusercontent.com/u/582878?v=4","gravatar_id":"","url":"https://api.github.com/users/benhamner","html_url":"https://github.com/benhamner","followers_url":"https://api.github.com/users/benhamner/followers","following_url":"https://api.github.com/users/benhamner/following{/other_user}","gists_url":"https://api.github.com/users/benhamner/gists{/gist_id}","starred_url":"https://api.github.com/users/benhamner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benhamner/subscriptions","organizations_url":"https://api.github.com/users/benhamner/orgs","repos_url":"https://api.github.com/users/benhamner/repos","events_url":"https://api.github.com/users/benhamner/events{/privacy}","received_events_url":"https://api.github.com/users/benhamner/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/benhamner/Metrics","description":"Machine learning evaluation metrics, implemented in Python, R, Haskell, and MATLAB / Octave","fork":false,"url":"https://api.github.com/repos/benhamner/Metrics","forks_url":"https://api.github.com/repos/benhamner/Metrics/forks","keys_url":"https://api.github.com/repos/benhamner/Metrics/keys{/key_id}","collaborators_url":"https://api.github.com/repos/benhamner/Metrics/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/benhamner/Metrics/teams","hooks_url":"https://api.github.com/repos/benhamner/Metrics/hooks","issue_events_url":"https://api.github.com/repos/benhamner/Metrics/issues/events{/number}","events_url":"https://api.github.com/repos/benhamner/Metrics/events","assignees_url":"https://api.github.com/repos/benhamner/Metrics/assignees{/user}","branches_url":"https://api.github.com/repos/benhamner/Metrics/branches{/branch}","tags_url":"https://api.github.com/repos/benhamner/Metrics/tags","blobs_url":"https://api.github.com/repos/benhamner/Metrics/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/benhamner/Metrics/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/benhamner/Metrics/git/refs{/sha}","trees_url":"https://api.github.com/repos/benhamner/Metrics/git/trees{/sha}","statuses_url":"https://api.github.com/repos/benhamner/Metrics/statuses/{sha}","languages_url":"https://api.github.com/repos/benhamner/Metrics/languages","stargazers_url":"https://api.github.com/repos/benhamner/Metrics/stargazers","contributors_url":"https://api.github.com/repos/benhamner/Metrics/contributors","subscribers_url":"https://api.github.com/repos/benhamner/Metrics/subscribers","subscription_url":"https://api.github.com/repos/benhamner/Metrics/subscription","commits_url":"https://api.github.com/repos/benhamner/Metrics/commits{/sha}","git_commits_url":"https://api.github.com/repos/benhamner/Metrics/git/commits{/sha}","comments_url":"https://api.github.com/repos/benhamner/Metrics/comments{/number}","issue_comment_url":"https://api.github.com/repos/benhamner/Metrics/issues/comments{/number}","contents_url":"https://api.github.com/repos/benhamner/Metrics/contents/{+path}","compare_url":"https://api.github.com/repos/benhamner/Metrics/compare/{base}...{head}","merges_url":"https://api.github.com/repos/benhamner/Metrics/merges","archive_url":"https://api.github.com/repos/benhamner/Metrics/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/benhamner/Metrics/downloads","issues_url":"https://api.github.com/repos/benhamner/Metrics/issues{/number}","pulls_url":"https://api.github.com/repos/benhamner/Metrics/pulls{/number}","milestones_url":"https://api.github.com/repos/benhamner/Metrics/milestones{/number}","notifications_url":"https://api.github.com/repos/benhamner/Metrics/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/benhamner/Metrics/labels{/name}","releases_url":"https://api.github.com/repos/benhamner/Metrics/releases{/id}","deployments_url":"https://api.github.com/repos/benhamner/Metrics/deployments","created_at":"2012-06-12T15:52:50Z","updated_at":"2018-06-26T00:25:17Z","pushed_at":"2018-06-03T11:17:35Z","git_url":"git://github.com/benhamner/Metrics.git","ssh_url":"git@github.com:benhamner/Metrics.git","clone_url":"https://github.com/benhamner/Metrics.git","svn_url":"https://github.com/benhamner/Metrics","homepage":"","size":803,"stargazers_count":880,"watchers_count":880,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":333,"mirror_url":null,"archived":false,"open_issues_count":27,"license":{"key":"other","name":"Other","spdx_id":null,"url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":333,"open_issues":27,"watchers":880,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/benhamner/Metrics/pulls/48"},"html":{"href":"https://github.com/benhamner/Metrics/pull/48"},"issue":{"href":"https://api.github.com/repos/benhamner/Metrics/issues/48"},"comments":{"href":"https://api.github.com/repos/benhamner/Metrics/issues/48/comments"},"review_comments":{"href":"https://api.github.com/repos/benhamner/Metrics/pulls/48/comments"},"review_comment":{"href":"https://api.github.com/repos/benhamner/Metrics/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/benhamner/Metrics/pulls/48/commits"},"statuses":{"href":"https://api.github.com/repos/benhamner/Metrics/statuses/dd476e08897b408a7120d5f091a686657aee77ec"}},"author_association":"NONE","merged":false,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"maintainer_can_modify":true,"commits":1,"additions":1,"deletions":1,"changed_files":1}}
{"actor":{"display_login":"Adam-Hoelscher"}}