{"id":17153083,"url":"https://github.com/itsrainingdata/sparsebn","last_synced_at":"2025-03-22T18:33:38.806Z","repository":{"id":60722844,"uuid":"55558743","full_name":"itsrainingdata/sparsebn","owner":"itsrainingdata","description":"Software for learning sparse Bayesian networks","archived":false,"fork":false,"pushed_at":"2020-09-05T19:14:44.000Z","size":2973,"stargazers_count":43,"open_issues_count":4,"forks_count":8,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-03-01T17:51:25.748Z","etag":null,"topics":["bayesian-networks","covariance-matrices","experimental-data","graphical-models","machine-learning","r","regularization","statistics"],"latest_commit_sha":null,"homepage":null,"language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/itsrainingdata.png","metadata":{"files":{"readme":"README.Rmd","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-04-05T22:39:35.000Z","updated_at":"2024-05-15T06:58:40.000Z","dependencies_parsed_at":"2022-10-03T21:18:39.385Z","dependency_job_id":null,"html_url":"https://github.com/itsrainingdata/sparsebn","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itsrainingdata%2Fsparsebn","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itsrainingdata%2Fsparsebn/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itsrainingdata%2Fsparsebn/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itsrainingdata%2Fsparsebn/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/itsrainingdata","download_url":"https://codeload.github.com/itsrainingdata/sparsebn/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244236092,"owners_count":20420752,"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":["bayesian-networks","covariance-matrices","experimental-data","graphical-models","machine-learning","r","regularization","statistics"],"created_at":"2024-10-14T21:45:10.964Z","updated_at":"2025-03-22T18:33:38.350Z","avatar_url":"https://github.com/itsrainingdata.png","language":"R","readme":"---\noutput:\n  md_document:\n    variant: markdown_github\n---\n\n```{r, echo = FALSE}\nknitr::opts_chunk$set(\n  collapse = TRUE,\n  comment = \"#\u003e\",\n  fig.path = \"README-\"\n)\n```\n\n# sparsebn\n\n[![Project Status: Active  The project has reached a stable, usable state and is being actively developed.](http://www.repostatus.org/badges/latest/active.svg)](http://www.repostatus.org/#active)\n[![Travis-CI Build Status](https://travis-ci.org/itsrainingdata/sparsebn.svg?branch=master)](https://travis-ci.org/itsrainingdata/sparsebn)\n[![](http://www.r-pkg.org/badges/version/sparsebn)](http://www.r-pkg.org/pkg/sparsebn)\n[![CRAN RStudio mirror downloads](http://cranlogs.r-pkg.org/badges/sparsebn)](http://www.r-pkg.org/pkg/sparsebn)\n\nIntroducing `sparsebn`: A new R package for learning sparse Bayesian networks and other graphical models from high-dimensional data via sparse regularization. Designed from the ground up to handle:\n\n- Experimental data with interventions \n- Mixed observational / experimental data\n- High-dimensional data with _p \u003e\u003e n_\n- Datasets with thousands of variables (tested up to _p_=8000)\n- Continuous and discrete data\n\nThe emphasis of this package is scalability and statistical consistency on high-dimensional datasets. Compared to existing algorithms, `sparsebn` scales much better and is under active development. For more details on this package, including worked examples and the methodological background, please see [our new preprint](https://arxiv.org/abs/1703.04025) [[1](#references)].\n\n## Overview\n\nThe main methods for learning graphical models are:\n\n* `estimate.dag` for directed acyclic graphs (Bayesian networks).\n* `estimate.precision` for undirected graphs (Markov random fields).\n* `estimate.covariance` for covariance matrices.\n\nCurrently, estimation of precision and covariances matrices is limited to Gaussian data.\n\nThe workhorse behind [`sparsebn`](http://www.github.com/itsrainingdata/sparsebn/) is the [`sparsebnUtils`](http://www.github.com/itsrainingdata/sparsebnUtils/)\npackage, which provides various S3 classes and methods for representing and manipulating graphs. The basic algorithms are implemented in [`ccdrAlgorithm`](http://www.github.com/itsrainingdata/ccdrAlgorithm/) and [`discretecdAlgorithm`](http://www.github.com/gujyjean/discretecdAlgorithm/).\n\n## Installation\n\nYou can install:\n\n* the latest CRAN version with\n\n    ```R\n    install.packages(\"sparsebn\")\n    ````\n\n* the latest development version from GitHub with\n\n    ```R\n    devtools::install_github(c(\"itsrainingdata/sparsebn/\", \"itsrainingdata/sparsebnUtils/dev\", \"itsrainingdata/ccdrAlgorithm/dev\", \"gujyjean/discretecdAlgorithm\"))\n    ```\n\n## References\n\n[1] Aragam, B., Gu, J., and Zhou, Q. (2017). [Learning large-scale Bayesian networks with the sparsebn package.](https://arxiv.org/abs/1703.04025) arXiv: 1703.04025. \n\n[2] Aragam, B. and Zhou, Q. (2015). [Concave penalized estimation of sparse Gaussian Bayesian networks.](http://jmlr.org/papers/v16/aragam15a.html) _The Journal of Machine Learning Research_. 16(Nov):2273−2328. \n\n[3] Fu, F., Gu, J., and Zhou, Q. (2014). [Adaptive penalized estimation of directed acyclic graphs from categorical data.](http://arxiv.org/abs/1403.2310) arXiv: 1403.2310. \n\n[4] Aragam, B., Amini, A. A., and Zhou, Q. (2015). [Learning directed acyclic graphs with penalized neighbourhood regression.](http://arxiv.org/abs/1511.08963) arXiv: 1511.08963.\n\n[5] Fu, F. and Zhou, Q. (2013). [Learning sparse causal Gaussian networks with experimental intervention: Regularization and coordinate descent.](http://amstat.tandfonline.com/doi/abs/10.1080/01621459.2012.754359) Journal of the American Statistical Association, 108: 288-300.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fitsrainingdata%2Fsparsebn","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fitsrainingdata%2Fsparsebn","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fitsrainingdata%2Fsparsebn/lists"}