{
  "_id": "6a47b20be06c18f0a651b3c1",
  "Package": "themis",
  "Title": "Extra Recipes Steps for Dealing with Unbalanced Data",
  "Version": "1.0.3.9000",
  "Authors@R": "c(\nperson(\"Emil\", \"Hvitfeldt\", , \"emil.hvitfeldt@posit.co\", role = c(\"aut\", \"cre\"),\ncomment = c(ORCID = \"0000-0002-0679-1945\")),\nperson(\"Posit Software, PBC\", role = c(\"cph\", \"fnd\"),\ncomment = c(ROR = \"03wc8by49\"))\n)",
  "Description": "A dataset with an uneven number of cases in each class is\nsaid to be unbalanced. Many models produce a subpar performance\non unbalanced datasets. A dataset can be balanced by increasing\nthe number of minority cases using SMOTE 2011\n<doi:10.48550/arXiv.1106.1813>, BorderlineSMOTE 2005\n<doi:10.1007/11538059_91> and ADASYN 2008\n<https://ieeexplore.ieee.org/document/4633969>. Or by\ndecreasing the number of majority cases using NearMiss 2003\n<https://www.site.uottawa.ca/~nat/Workshop2003/jzhang.pdf> or\nTomek link removal 1976\n<https://ieeexplore.ieee.org/document/4309452>.",
  "License": "MIT + file LICENSE",
  "URL": "https://github.com/tidymodels/themis,\nhttps://themis.tidymodels.org",
  "BugReports": "https://github.com/tidymodels/themis/issues",
  "Config/Needs/website": "tidyverse/tidytemplate",
  "Config/testthat/edition": "3",
  "Config/usethis/last-upkeep": "2025-04-24",
  "Encoding": "UTF-8",
  "LazyData": "true",
  "Roxygen": "list(markdown = TRUE)",
  "RoxygenNote": "7.3.3",
  "Config/pak/sysreqs": "libicu-dev",
  "Repository": "https://tidymodels.r-universe.dev",
  "Date/Publication": "2026-04-10 00:12:25 UTC",
  "RemoteUrl": "https://github.com/tidymodels/themis",
  "RemoteRef": "HEAD",
  "RemoteSha": "76cf8d0add894b8b1151bcd87c1964656c866fad",
  "NeedsCompilation": "no",
  "Packaged": {
    "Date": "2026-07-03 12:54:55 UTC",
    "User": "root"
  },
  "Author": "Emil Hvitfeldt [aut, cre] (ORCID:\n<https://orcid.org/0000-0002-0679-1945>),\nPosit Software, PBC [cph, fnd] (ROR: <https://ror.org/03wc8by49>)",
  "Maintainer": "Emil Hvitfeldt <emil.hvitfeldt@posit.co>",
  "_user": "tidymodels",
  "_type": "src",
  "_file": "themis_1.0.3.9000.tar.gz",
  "_fileid": "https://r2.ropensci.org/16e0e21362f606371fef61714f3eabe70b6da5d4cdedcc7273e1f9aa70fd5da1",
  "_filesize": 362025,
  "_sha256": "16e0e21362f606371fef61714f3eabe70b6da5d4cdedcc7273e1f9aa70fd5da1",
  "_expires": "2026-10-11T12:58:50.000Z",
  "_created": "2026-07-03T12:54:55.000Z",
  "_published": "2026-07-03T12:58:51.115Z",
  "_jobs": [
    {
      "job": 85004425677,
      "time": 194,
      "config": "linux-devel-x86_64",
      "r": "4.7.0",
      "check": "OK",
      "artifact": "8067103467"
    },
    {
      "job": 85004425686,
      "time": 188,
      "config": "linux-release-x86_64",
      "r": "4.6.1",
      "check": "OK",
      "artifact": "8067101680"
    },
    {
      "job": 85004425710,
      "time": 96,
      "config": "macos-oldrel-arm64",
      "r": "4.5.3",
      "check": "OK",
      "artifact": "8067067833"
    },
    {
      "job": 85004425682,
      "time": 117,
      "config": "macos-release-arm64",
      "r": "4.6.1",
      "check": "OK",
      "artifact": "8067075778"
    },
    {
      "job": 85003833270,
      "time": 207,
      "config": "source",
      "r": "4.6.1",
      "check": "OK",
      "artifact": "8067031303"
    },
    {
      "job": 85004425658,
      "time": 161,
      "config": "wasm-release",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "8067091707"
    },
    {
      "job": 85004425690,
      "time": 136,
      "config": "windows-devel",
      "r": "4.7.0",
      "check": "OK",
      "artifact": "8067082731"
    },
    {
      "job": 85004425706,
      "time": 132,
      "config": "windows-oldrel",
      "r": "4.5.3",
      "check": "OK",
      "artifact": "8067081470"
    },
    {
      "job": 85004425688,
      "time": 170,
      "config": "windows-release",
      "r": "4.6.1",
      "check": "OK",
      "artifact": "8067094765"
    }
  ],
  "_host": "GitHub-Actions",
  "_buildurl": "https://github.com/r-universe/tidymodels/actions/runs/28661737189",
  "_status": "success",
  "_upstream": "https://github.com/tidymodels/themis",
  "_commit": {
    "id": "76cf8d0add894b8b1151bcd87c1964656c866fad",
    "author": "Emil Hvitfeldt <emil.hvitfeldt@posit.co>",
    "committer": "GitHub <noreply@github.com>",
    "message": "More docs (#220)",
    "time": 1775779945
  },
  "_maintainer": {
    "name": "Emil Hvitfeldt",
    "email": "emil.hvitfeldt@posit.co",
    "login": "emilhvitfeldt",
    "bluesky": "@emilhvitfeldt.bsky.social",
    "description": "All things @tidymodels",
    "uuid": 14034784,
    "orcid": "0000-0002-0679-1945"
  },
  "_distro": "resolute",
  "_registered": true,
  "_dependencies": [
    {
      "package": "R",
      "version": ">= 4.1",
      "role": "Depends"
    },
    {
      "package": "recipes",
      "version": ">= 1.1.0",
      "role": "Depends"
    },
    {
      "package": "cli",
      "role": "Imports"
    },
    {
      "package": "dplyr",
      "role": "Imports"
    },
    {
      "package": "generics",
      "version": ">= 0.1.0",
      "role": "Imports"
    },
    {
      "package": "glue",
      "role": "Imports"
    },
    {
      "package": "gower",
      "role": "Imports"
    },
    {
      "package": "hardhat",
      "role": "Imports"
    },
    {
      "package": "lifecycle",
      "version": ">= 1.0.3",
      "role": "Imports"
    },
    {
      "package": "purrr",
      "role": "Imports"
    },
    {
      "package": "RANN",
      "role": "Imports"
    },
    {
      "package": "rlang",
      "version": ">= 1.1.0",
      "role": "Imports"
    },
    {
      "package": "ROSE",
      "role": "Imports"
    },
    {
      "package": "tibble",
      "role": "Imports"
    },
    {
      "package": "vctrs",
      "role": "Imports"
    },
    {
      "package": "withr",
      "role": "Imports"
    },
    {
      "package": "covr",
      "role": "Suggests"
    },
    {
      "package": "dials",
      "version": ">= 1.2.0",
      "role": "Suggests"
    },
    {
      "package": "ggplot2",
      "role": "Suggests"
    },
    {
      "package": "modeldata",
      "role": "Suggests"
    },
    {
      "package": "testthat",
      "version": ">= 3.0.0",
      "role": "Suggests"
    }
  ],
  "_owner": "tidymodels",
  "_selfowned": true,
  "_usedby": 2,
  "_updates": [
    {
      "week": "2026-04",
      "n": 1
    },
    {
      "week": "2026-14",
      "n": 8
    },
    {
      "week": "2026-15",
      "n": 18
    }
  ],
  "_tags": [],
  "_stars": 142,
  "_contributors": [
    {
      "user": "emilhvitfeldt",
      "count": 490,
      "uuid": 14034784
    },
    {
      "user": "robertgregg",
      "count": 12,
      "uuid": 44711193
    },
    {
      "user": "topepo",
      "count": 7,
      "uuid": 5731043
    },
    {
      "user": "juliasilge",
      "count": 4,
      "uuid": 12505835
    },
    {
      "user": "hfrick",
      "count": 4,
      "uuid": 12950918
    },
    {
      "user": "jeroenjanssens",
      "count": 2,
      "uuid": 1368256
    },
    {
      "user": "rpln",
      "count": 2,
      "uuid": 14273214
    },
    {
      "user": "jxu",
      "count": 2,
      "uuid": 7989982
    },
    {
      "user": "bebru",
      "count": 1,
      "uuid": 12512888
    },
    {
      "user": "mine-cetinkaya-rundel",
      "count": 1,
      "uuid": 5965649
    },
    {
      "user": "pursuitofdatascience",
      "count": 1,
      "uuid": 54338793
    }
  ],
  "_userbio": {
    "uuid": 29100987,
    "type": "organization",
    "name": "tidymodels",
    "followers": 555
  },
  "_downloads": {
    "count": 17230,
    "source": "https://cranlogs.r-pkg.org/downloads/total/last-month/themis"
  },
  "_devurl": "https://github.com/tidymodels/themis",
  "_pkgdown": "https://themis.tidymodels.org",
  "_searchresults": 1820,
  "_rbuild": "4.6.1",
  "_assets": [
    "extra/citation.cff",
    "extra/citation.html",
    "extra/citation.json",
    "extra/citation.txt",
    "extra/contents.json",
    "extra/NEWS.html",
    "extra/NEWS.txt",
    "extra/readme.html",
    "extra/readme.md",
    "extra/themis.html",
    "LICENSE",
    "manual.pdf"
  ],
  "_homeurl": "https://github.com/tidymodels/themis",
  "_realowner": "tidymodels",
  "_cranurl": true,
  "_releases": [
    {
      "version": "0.1.0",
      "date": "2020-01-13"
    },
    {
      "version": "0.1.1",
      "date": "2020-05-17"
    },
    {
      "version": "0.1.2",
      "date": "2020-08-14"
    },
    {
      "version": "0.1.3",
      "date": "2020-11-12"
    },
    {
      "version": "0.1.4",
      "date": "2021-06-12"
    },
    {
      "version": "0.2.0",
      "date": "2022-03-30"
    },
    {
      "version": "0.2.1",
      "date": "2022-04-13"
    },
    {
      "version": "0.2.2",
      "date": "2022-05-11"
    },
    {
      "version": "1.0.0",
      "date": "2022-07-02"
    },
    {
      "version": "1.0.1",
      "date": "2023-04-15"
    },
    {
      "version": "1.0.2",
      "date": "2023-08-14"
    },
    {
      "version": "1.0.3",
      "date": "2025-01-23"
    }
  ],
  "_exports": [
    "adasyn",
    "bsmote",
    "nearmiss",
    "required_pkgs",
    "rose",
    "smote",
    "smotenc",
    "step_adasyn",
    "step_bsmote",
    "step_downsample",
    "step_nearmiss",
    "step_rose",
    "step_smote",
    "step_smotenc",
    "step_tomek",
    "step_upsample",
    "tidy",
    "tomek",
    "tunable"
  ],
  "_datasets": [
    {
      "name": "circle_example",
      "title": "Synthetic Dataset With a Circle",
      "object": "circle_example",
      "class": [
        "data.frame"
      ],
      "fields": [
        "x",
        "y",
        "class",
        "id"
      ],
      "rows": 400,
      "table": true,
      "tojson": true
    }
  ],
  "_help": [
    {
      "page": "adasyn",
      "title": "Adaptive Synthetic Algorithm",
      "concept": [
        "Direct Implementations"
      ],
      "topics": [
        "adasyn"
      ]
    },
    {
      "page": "bsmote",
      "title": "borderline-SMOTE Algorithm",
      "concept": [
        "Direct Implementations"
      ],
      "topics": [
        "bsmote"
      ]
    },
    {
      "page": "circle_example",
      "title": "Synthetic Dataset With a Circle",
      "topics": [
        "circle_example"
      ]
    },
    {
      "page": "nearmiss",
      "title": "Remove Points Near Other Classes",
      "concept": [
        "Direct Implementations"
      ],
      "topics": [
        "nearmiss"
      ]
    },
    {
      "page": "rose",
      "title": "ROSE Algorithm",
      "concept": [
        "Direct Implementations"
      ],
      "topics": [
        "rose"
      ]
    },
    {
      "page": "smote",
      "title": "SMOTE Algorithm",
      "concept": [
        "Direct Implementations"
      ],
      "topics": [
        "smote"
      ]
    },
    {
      "page": "smotenc",
      "title": "SMOTENC Algorithm",
      "concept": [
        "Direct Implementations"
      ],
      "topics": [
        "smotenc"
      ]
    },
    {
      "page": "step_adasyn",
      "title": "Apply Adaptive Synthetic Algorithm",
      "concept": [
        "Steps for over-sampling"
      ],
      "topics": [
        "step_adasyn",
        "tidy.step_adasyn"
      ]
    },
    {
      "page": "step_bsmote",
      "title": "Apply borderline-SMOTE Algorithm",
      "concept": [
        "Steps for over-sampling"
      ],
      "topics": [
        "step_bsmote",
        "tidy.step_bsmote"
      ]
    },
    {
      "page": "step_downsample",
      "title": "Down-Sample a Data Set Based on a Factor Variable",
      "concept": [
        "Steps for under-sampling"
      ],
      "topics": [
        "step_downsample",
        "tidy.step_downsample"
      ]
    },
    {
      "page": "step_nearmiss",
      "title": "Remove Points Near Other Classes",
      "concept": [
        "Steps for under-sampling"
      ],
      "topics": [
        "step_nearmiss",
        "tidy.step_nearmiss"
      ]
    },
    {
      "page": "step_rose",
      "title": "Apply ROSE Algorithm",
      "concept": [
        "Steps for over-sampling"
      ],
      "topics": [
        "step_rose",
        "tidy.step_rose"
      ]
    },
    {
      "page": "step_smote",
      "title": "Apply SMOTE Algorithm",
      "concept": [
        "Steps for over-sampling"
      ],
      "topics": [
        "step_smote",
        "tidy.step_smote"
      ]
    },
    {
      "page": "step_smotenc",
      "title": "Apply SMOTENC algorithm",
      "concept": [
        "Steps for over-sampling"
      ],
      "topics": [
        "step_smotenc",
        "tidy.step_smotenc"
      ]
    },
    {
      "page": "step_tomek",
      "title": "Remove Tomek’s Links",
      "concept": [
        "Steps for under-sampling"
      ],
      "topics": [
        "step_tomek",
        "tidy.step_tomek"
      ]
    },
    {
      "page": "step_upsample",
      "title": "Up-Sample a Data Set Based on a Factor Variable",
      "concept": [
        "Steps for over-sampling"
      ],
      "topics": [
        "step_upsample",
        "tidy.step_upsample"
      ]
    },
    {
      "page": "tomek",
      "title": "Remove Tomek's links",
      "concept": [
        "Direct Implementations"
      ],
      "topics": [
        "tomek"
      ]
    }
  ],
  "_pkglogo": "https://github.com/tidymodels/themis/raw/HEAD/man/figures/logo.png",
  "_readme": "https://github.com/tidymodels/themis/raw/HEAD/README.md",
  "_rundeps": [
    "class",
    "cli",
    "clock",
    "codetools",
    "cpp11",
    "data.table",
    "diagram",
    "digest",
    "dplyr",
    "farver",
    "future",
    "future.apply",
    "generics",
    "ggplot2",
    "globals",
    "glue",
    "gower",
    "gtable",
    "hardhat",
    "ipred",
    "isoband",
    "KernSmooth",
    "labeling",
    "lattice",
    "lava",
    "lifecycle",
    "listenv",
    "lubridate",
    "magrittr",
    "MASS",
    "Matrix",
    "nnet",
    "numDeriv",
    "parallelly",
    "pillar",
    "pkgconfig",
    "prodlim",
    "progressr",
    "purrr",
    "R6",
    "RANN",
    "RColorBrewer",
    "Rcpp",
    "recipes",
    "rlang",
    "ROSE",
    "rpart",
    "S7",
    "scales",
    "shape",
    "sparsevctrs",
    "SQUAREM",
    "stringi",
    "stringr",
    "survival",
    "tibble",
    "tidyr",
    "tidyselect",
    "timechange",
    "timeDate",
    "tzdb",
    "utf8",
    "vctrs",
    "viridisLite",
    "withr"
  ],
  "_score": 10.602887519255484,
  "_indexed": true,
  "_nocasepkg": "themis",
  "_universes": [
    "tidymodels",
    "emilhvitfeldt"
  ],
  "_binaries": [
    {
      "r": "4.7.0",
      "os": "linux",
      "version": "1.0.3.9000",
      "date": "2026-07-03T12:57:25.000Z",
      "distro": "resolute",
      "commit": "76cf8d0add894b8b1151bcd87c1964656c866fad",
      "fileid": "https://r2.ropensci.org/349b2bfcde8c084db8f7cdffb2f902a3c4cef4e37799bca3916f27df6ecaa27d",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/tidymodels/actions/runs/28661737189"
    },
    {
      "r": "4.6.1",
      "os": "linux",
      "version": "1.0.3.9000",
      "date": "2026-07-03T12:57:20.000Z",
      "distro": "resolute",
      "commit": "76cf8d0add894b8b1151bcd87c1964656c866fad",
      "fileid": "https://r2.ropensci.org/7e56e5648e6bfa0ac9a5126e77cd3a45071bc9cb99d5e5c73c39829ce07096d0",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/tidymodels/actions/runs/28661737189"
    },
    {
      "r": "4.5.3",
      "os": "mac",
      "version": "1.0.3.9000",
      "date": "2026-07-03T12:56:18.000Z",
      "commit": "76cf8d0add894b8b1151bcd87c1964656c866fad",
      "fileid": "https://r2.ropensci.org/088212f428e01cf0aba49e12a33aaeb4be0fa341ad7b85d1e7604cf932bf99a4",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/tidymodels/actions/runs/28661737189"
    },
    {
      "r": "4.6.1",
      "os": "mac",
      "version": "1.0.3.9000",
      "date": "2026-07-03T12:56:33.000Z",
      "commit": "76cf8d0add894b8b1151bcd87c1964656c866fad",
      "fileid": "https://r2.ropensci.org/8a436526d31fc666cd73cd69ecd9263ba65ea3a72c5ac184bee2f4fc063f0b52",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/tidymodels/actions/runs/28661737189"
    },
    {
      "r": "4.6.0",
      "os": "wasm",
      "version": "1.0.3.9000",
      "date": "2026-07-03T12:57:56.000Z",
      "commit": "76cf8d0add894b8b1151bcd87c1964656c866fad",
      "fileid": "https://r2.ropensci.org/8d2fd537c8002f2adf4083769d496bf6b217381b75b5b7286ca02c981c3967ae",
      "status": "success",
      "buildurl": "https://github.com/r-universe/tidymodels/actions/runs/28661737189"
    },
    {
      "r": "4.7.0",
      "os": "win",
      "version": "1.0.3.9000",
      "date": "2026-07-03T12:56:16.000Z",
      "commit": "76cf8d0add894b8b1151bcd87c1964656c866fad",
      "fileid": "https://r2.ropensci.org/efa64b2dcb848b03c0398e842101b5fc46a6b56406b6c3a669de302da4976d45",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/tidymodels/actions/runs/28661737189"
    },
    {
      "r": "4.5.3",
      "os": "win",
      "version": "1.0.3.9000",
      "date": "2026-07-03T12:56:12.000Z",
      "commit": "76cf8d0add894b8b1151bcd87c1964656c866fad",
      "fileid": "https://r2.ropensci.org/78ac7a7ad5222e5279d913543ec6390dc9b2dfcf3e1dbaf3a469427046bd960f",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/tidymodels/actions/runs/28661737189"
    },
    {
      "r": "4.6.1",
      "os": "win",
      "version": "1.0.3.9000",
      "date": "2026-07-03T12:56:26.000Z",
      "commit": "76cf8d0add894b8b1151bcd87c1964656c866fad",
      "fileid": "https://r2.ropensci.org/ab7bbe4543d4c8fb876d3816a01689cba371d9d0237d03ec738874531ffccd9c",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/tidymodels/actions/runs/28661737189"
    }
  ]
}