{"id":50306866,"url":"https://github.com/cissagatto/multilabelfriedmannemenyi","last_synced_at":"2026-05-28T17:01:52.942Z","repository":{"id":255417319,"uuid":"849397387","full_name":"cissagatto/MultiLabelFriedmanNemenyi","owner":"cissagatto","description":"This repository provides a practical implementation of the Friedman and Nemenyi statistical tests specifically tailored for multi-label classification problems. These techniques are essential for evaluating and comparing the performance of multiple algorithms in experiments where each instance may belong to several classes simultaneously.","archived":false,"fork":false,"pushed_at":"2026-01-26T22:17:29.000Z","size":338,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-01-27T01:08:31.743Z","etag":null,"topics":["friedman","model-comparison","multi-label-classification","nemenyi","statistical-tests"],"latest_commit_sha":null,"homepage":"","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cissagatto.png","metadata":{"files":{"readme":"README.md","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,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-08-29T14:20:06.000Z","updated_at":"2026-01-26T22:17:33.000Z","dependencies_parsed_at":"2024-08-29T22:11:19.685Z","dependency_job_id":"70dcacc9-eb07-4a37-8645-6de233444efe","html_url":"https://github.com/cissagatto/MultiLabelFriedmanNemenyi","commit_stats":null,"previous_names":["cissagatto/multilabelfriedmannemenyi","cissagatto/multi-label-friedman-nemenyi"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/cissagatto/MultiLabelFriedmanNemenyi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cissagatto%2FMultiLabelFriedmanNemenyi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cissagatto%2FMultiLabelFriedmanNemenyi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cissagatto%2FMultiLabelFriedmanNemenyi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cissagatto%2FMultiLabelFriedmanNemenyi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cissagatto","download_url":"https://codeload.github.com/cissagatto/MultiLabelFriedmanNemenyi/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cissagatto%2FMultiLabelFriedmanNemenyi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33617718,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-05-28T02:00:06.440Z","response_time":99,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["friedman","model-comparison","multi-label-classification","nemenyi","statistical-tests"],"created_at":"2026-05-28T17:01:51.867Z","updated_at":"2026-05-28T17:01:52.936Z","avatar_url":"https://github.com/cissagatto.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Multi-Label Friedman-Nemenyi Analysis Toolkit\n\nWelcome to the **Multi-Label Friedman-Nemenyi Analysis Toolkit**! This powerful suite is designed to streamline the process of ranking and analyzing multi-label datasets using the Friedman-Nemenyi test, a key statistical method for comparing multiple algorithms or classifiers.\n\n## 🚀 **Features**\n\n- **Batch Processing:** Seamlessly handle multiple CSV files in a single run.\n- **Versatile Ranking Methods:** Compute rankings with various tie-breaking strategies including first, last, average, random, minimum, and maximum.\n- **Comprehensive Statistical Analysis:** Utilize the Friedman-Nemenyi test to rigorously evaluate and compare multiple methods or classifiers.\n- **Customizable Outputs:** Save results to organized folders with intuitive naming conventions for easy reference and further analysis.\n\n## How to Cite\n\n```plaintext\n@misc{MLFN2024,\n  author = {Elaine Cecília Gatto},\n  title = {MultiLabelFriedmanNemenyi: A package for multi-label Friedman-Nemenyi analysis},  \n  year = {2024},\n  note = {R package version 0.1.0 Licensed under CC BY-NC-SA 4.0},\n  doi = {10.13140/RG.2.2.17865.35687/1},\n  url = {https://github.com/cissagatto/MultiLabelFriedmanNemenyi}\n}\n```\n\n## 📥 **Getting Started**\n\n\n### Prerequisites\n\n- R (version 4.0 or higher)\n- Necessary R packages: `dplyr`, `tools`, `ggplot2`, `stringr`, `scmamp`, `openxlsx`, `writexl`.\n\n\n\n### Installation\n\n    \n```r\n# install.packages(\"devtools\")\nlibrary(\"devtools\")\ndevtools::install_github(\"https://github.com/cissagatto/MultiLabelFriedmanNemenyi\")\nlibrary(MultiLabelFriedmanNemenyi)\n```\n\n### Examples\n\nHere are some examples of how to use the toolkit:\n\n**For Measures with the best value equal to 0**\n\n```r\n\nsetwd(FolderRoot)\nclp = data.frame(read.csv(\"~/MultiLabelFriedmanNemenyi/Data/clp.csv\"))\nclp = clp[,-1]\n\ndf_res.mes \u003c- fn.measures()\nfiltered_res.mes \u003c- filter(df_res.mes, names == \"clp\")\n\nsave = paste(FolderResults, \"/clp\", sep=\"\")\nif(dir.exists(save)==FALSE){dir.create(save)}\n\nranking = generate.ranking(data = clp)\nres.data = data.frame(ranking$rank.average.1) \n\n# old version\nres.fn = friedman.nemenyi(data = res.data , \n                          save = save,\n                          measure.name = \"clp\",\n                          width = 60, \n                          height = 30,\n                          cex=5.5)\n# new version\nfriedman.nemenyi.new(\n  data = res.data,\n  save = save,\n  measure.name = \"clp\",\n  width = 14,\n  height = 7,\n  cex = 2,\n  device = \"png\",\n  dpi = 150\n)\n\n                          \n```\n\n**For Measures with the best value equal to 1**\n\n```r\n\nsetwd(FolderRoot)\naccuracy = data.frame(read.csv(\"~/MultiLabelFriedmanNemenyi/Data/accuracy.csv\"))\naccuracy = accuracy [,-1]\n\ndf_res.mes \u003c- fn.measures()\nfiltered_res.mes \u003c- filter(df_res.mes, names == \"accuracy\")\n\nsave = paste(FolderResults, \"/accuracy\", sep=\"\")\nif(dir.exists(save)==FALSE){dir.create(save)}\n\nres = friedman.nemenyi(data = accuracy, \n                       save = save,\n                       measure.name = \"accuracy\",\n                       width = 60, \n                       height = 30,\n                       cex=5.5)\n\n```\n\n**Processing Multiple CSV Files:**\n\n```r\n\n# Set the working directory to the data folder\nsetwd(FolderData)\ncurrent.dir \u003c- getwd()\n\n# List all CSV files with full paths\nfiles \u003c- list.files(pattern = \"\\\\.csv$\", full.names = TRUE)\nfull.paths \u003c- sapply(files, function(file) normalizePath(file))\n\n# Initialize a data frame to store the concatenated results\nall.results \u003c- data.frame()\n\n# Process each CSV file\nfor (file.path in full.paths) {\n  \n  \n  #file.path = \"C:/Users/Cissa/Documents/MultiLabelFriedmanNemenyi/Data/accuracy.csv\"\n  # Extract the file name\n  data.name \u003c- basename(file.path)\n  \n  # Read the CSV file into a data frame\n  data \u003c- data.frame(read.csv(file.path))\n  \n  # Remove the first column\n  data \u003c- data[, -1]\n  \n  # Generate rankings\n  ranking \u003c- generate.ranking(data = data)\n  \n  # Extract the measure name from the file name\n  measure.name \u003c- tools::file_path_sans_ext(data.name)\n  \n  # Load and filter measures data\n  df.res.mes \u003c- fn.measures()\n  filtered.res.mes \u003c- filter(df.res.mes, names == measure.name)\n  \n  # Define the path to save the results\n  save.path \u003c- file.path(FolderResults, measure.name)\n  if (!dir.exists(save.path)) {\n    dir.create(save.path)\n  }\n  \n  # Save the rankings to an Excel file\n  file.name \u003c- file.path(save.path, paste0(measure.name, \"-ranking.xlsx\"))\n  save.dataframes.to.excel(data.list = ranking, file.name = file.name)\n  \n  # Run Friedman-Nemenyi test and store the results\n  if (filtered.res.mes$type == 1) {\n    # If the measure is type 1, the best value is one\n    res \u003c- friedman.nemenyi(data = data, \n                            save = save.path,\n                            measure.name = measure.name,\n                            width = 60, \n                            height = 30,\n                            cex = 5.5)\n    \n    # data, save.dir, measure.name, width = 7, height = 5, cex = 1.2\n    \n  } else {\n    # If the measure is type 0, the best value is zero\n    res.data \u003c- data.frame(ranking$rank.average.1)\n    res \u003c- friedman.nemenyi(data = res.data, \n                            save = save.path,\n                            measure.name = measure.name,\n                            width = 60, \n                            height = 30,\n                            cex = 5.5)\n  }\n  \n  # Concatenate the result to the all.results data frame\n  all.results \u003c- rbind(all.results, res)\n  \n  # plotting boxplots\n  methods.names \u003c- colnames(data)  \n  generate.boxplots(data = data,\n                    methods = methods.names, \n                    save.dir = save.path,\n                    measure.name = measure.name,\n                    width = 20,\n                    height = 10)\n  \n  # Log the processed file\n  cat(\"\\nProcessed file:\", data.name, \"\\n\")\n}\n\n\nmeasures \u003c- tools::file_path_sans_ext(basename(files))\nnome.arquivo = paste(FolderResults, \"/FN-results.xlsx\", sep=\"\")\nres = data.frame(measures, all.results)\nwrite_xlsx(res, nome.arquivo)\n```\n\n### Documentation\n\nFor more detailed documentation on each function, check out the `~/MultiLabelFriedmanNemenyi/docs` folder.\nA complete example is available in `~/MultiLabelFriedmanNemenyi/example` folder.\n\n\n### Folder Structure\n\nEnsure the following folder structure is set up:\n\n- `FolderRoot`: Root directory of the project.\n- `FolderData`: Directory where CSV data files are stored.\n- `FolderResults`: Directory where results and plots are saved.\n\n\n## 📚 **Contributing**\n\nWe welcome contributions from the community! If you have suggestions, improvements, or bug fixes, please submit a pull request or open an issue in the GitHub repository.\n\n## 📧 **Contact**\n\nFor any questions or support, please contact:\n- **Prof. Elaine Cecilia Gatto** (elainececiliagatto@gmail.com)\n  \nThank you for using the Multi-Label Friedman-Nemenyi Analysis Toolkit. We hope this tool helps you in your multi-label classification tasks!\n\n\n\n## Acknowledgment\n- This study was financed in part by the Coordenação de Aperfeiçoamento de Pessoal de Nível Superior - Brasil (CAPES) - Finance Code 001.\n- This study was financed in part by the Conselho Nacional de Desenvolvimento Científico e Tecnológico - Brasil (CNPQ) - Process number 200371/2022-3.\n- The authors also thank the Brazilian research agencies FAPESP financial support.\n\n\n# Links\n\n| [Site](https://sites.google.com/view/professor-cissa-gatto) | [Post-Graduate Program in Computer Science](http://ppgcc.dc.ufscar.br/pt-br) | [Computer Department](https://site.dc.ufscar.br/) |  [Biomal](http://www.biomal.ufscar.br/) | [CNPQ](https://www.gov.br/cnpq/pt-br) | [Ku Leuven](https://kulak.kuleuven.be/) | [Embarcados](https://www.embarcados.com.br/author/cissa/) | [Read Prensa](https://prensa.li/@cissa.gatto/) | [Linkedin Company](https://www.linkedin.com/company/27241216) | [Linkedin Profile](https://www.linkedin.com/in/elainececiliagatto/) | [Instagram](https://www.instagram.com/cissagatto) | [Facebook](https://www.facebook.com/cissagatto) | [Twitter](https://twitter.com/cissagatto) | [Twitch](https://www.twitch.tv/cissagatto) | [Youtube](https://www.youtube.com/CissaGatto) |\n\n\n---\n\nStart making good decisions with the Multi-label Friedman Nemenyi Tool today! 🚀 🎉\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcissagatto%2Fmultilabelfriedmannemenyi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcissagatto%2Fmultilabelfriedmannemenyi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcissagatto%2Fmultilabelfriedmannemenyi/lists"}