{"id":21985725,"url":"https://github.com/m-clark/confusionmatrix","last_synced_at":"2025-07-08T00:33:18.612Z","repository":{"id":74459110,"uuid":"208095828","full_name":"m-clark/confusionMatrix","owner":"m-clark","description":"Report various statistics stemming from a confusion matrix in a tidy fashion. 🎯 ","archived":false,"fork":false,"pushed_at":"2020-07-10T17:10:07.000Z","size":442,"stargazers_count":11,"open_issues_count":1,"forks_count":4,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-30T07:53:53.537Z","etag":null,"topics":["balanced-accuracy","confusion-matrix","dice-coefficient","f1-score","fallout","false-discovery-rate","false-negative-rate","false-omission-rate","false-positive-rate","kappa","negative-predictive-value","peirce","positive-predictive-value","precision-recall","rand","sensitivity","specificity","tidy","true-negative-rate","true-positive-rate"],"latest_commit_sha":null,"homepage":"https://m-clark.github.io/confusionMatrix/","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/m-clark.png","metadata":{"files":{"readme":"README.Rmd","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2019-09-12T16:29:37.000Z","updated_at":"2023-11-05T12:48:54.000Z","dependencies_parsed_at":null,"dependency_job_id":"a528c2ba-63d9-4cfd-8e92-1129e8f8c86f","html_url":"https://github.com/m-clark/confusionMatrix","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m-clark%2FconfusionMatrix","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m-clark%2FconfusionMatrix/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m-clark%2FconfusionMatrix/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m-clark%2FconfusionMatrix/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/m-clark","download_url":"https://codeload.github.com/m-clark/confusionMatrix/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251666245,"owners_count":21624292,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["balanced-accuracy","confusion-matrix","dice-coefficient","f1-score","fallout","false-discovery-rate","false-negative-rate","false-omission-rate","false-positive-rate","kappa","negative-predictive-value","peirce","positive-predictive-value","precision-recall","rand","sensitivity","specificity","tidy","true-negative-rate","true-positive-rate"],"created_at":"2024-11-29T18:14:33.398Z","updated_at":"2025-04-30T07:54:13.511Z","avatar_url":"https://github.com/m-clark.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"---\noutput: \n  github_document\nencoding: 'UTF-8'\n---\n\n\n```{r, include = FALSE}\nknitr::opts_chunk$set(\n  fig.path = \"man/figures/\",\n  comment = NA\n)\n```\n\n\u003c!-- badges: start --\u003e\n\n[![R build status](https://github.com/m-clark/confusionMatrix/workflows/R-CMD-check/badge.svg)](https://github.com/m-clark/confusionMatrix/actions)\n  [![Codecov test coverage](https://codecov.io/gh/m-clark/confusionMatrix/branch/master/graph/badge.svg)](https://codecov.io/gh/m-clark/confusionMatrix?branch=master)\n  [![Lifecycle: maturing](https://img.shields.io/badge/lifecycle-experimental-blue.svg)](https://www.tidyverse.org/lifecycle/#experimental)\n\n\u003c!-- badges: end --\u003e\n \n\n# confusionMatrix\n\n\u003cbr\u003e\n\nGiven predictions and a target variable, provide numerous statistics from the resulting confusion matrix. The goal is to provide a wealth of summary statistics that can be calculated from a single confusion matrix, and return \u003cspan class=\"emph\" style = \"\"\u003e**tidy**\u003c/span\u003e results with as few dependencies as possible.\n\n\n\n\n```{r demo}\nlibrary(confusionMatrix)\n\np = sample(letters[1:2], 250, replace = T, prob = 1:2)\no = sample(letters[1:2], 250, replace = T, prob = 1:2)\n\nresult = confusion_matrix(\n  prediction = p,\n  target = o,\n  return_table = TRUE\n)\n\nresult\n\nresult$Accuracy$`Frequency Table`\n```\n\n```{r demo-longer}\nresult = confusion_matrix(\n  prediction = p,\n  target = o,\n  longer = TRUE\n)\n\nresult\n```\n\n\n### Installation\n\nTo install from GitHub the \u003cspan class=\"pack\"\u003edevtools\u003c/span\u003e package is required.\n\n```{r eval=FALSE}\ndevtools::install_github('m-clark/confusionMatrix')\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fm-clark%2Fconfusionmatrix","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fm-clark%2Fconfusionmatrix","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fm-clark%2Fconfusionmatrix/lists"}