{"id":15051456,"url":"https://github.com/airoldilab/sgd","last_synced_at":"2025-07-12T15:38:40.505Z","repository":{"id":24222058,"uuid":"27614252","full_name":"airoldilab/sgd","owner":"airoldilab","description":"An R package for large scale estimation with stochastic gradient descent","archived":false,"fork":false,"pushed_at":"2024-02-06T04:21:50.000Z","size":2128,"stargazers_count":59,"open_issues_count":41,"forks_count":18,"subscribers_count":12,"default_branch":"master","last_synced_at":"2024-03-27T12:18:03.857Z","etag":null,"topics":["big-data","data-analysis","gradient-descent","r","statistics"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"rasbt/python-machine-learning-book","license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/airoldilab.png","metadata":{"files":{"readme":"README.md","changelog":"NEWS.md","contributing":null,"funding":null,"license":null,"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}},"created_at":"2014-12-05T23:10:59.000Z","updated_at":"2024-02-11T14:18:53.000Z","dependencies_parsed_at":"2024-09-24T21:35:32.500Z","dependency_job_id":null,"html_url":"https://github.com/airoldilab/sgd","commit_stats":{"total_commits":332,"total_committers":8,"mean_commits":41.5,"dds":0.3644578313253012,"last_synced_commit":"0e5270f5d300d8d206e6d6fd83d0a214ee630c7d"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/airoldilab%2Fsgd","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/airoldilab%2Fsgd/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/airoldilab%2Fsgd/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/airoldilab%2Fsgd/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/airoldilab","download_url":"https://codeload.github.com/airoldilab/sgd/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248143484,"owners_count":21054790,"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":["big-data","data-analysis","gradient-descent","r","statistics"],"created_at":"2024-09-24T21:35:31.068Z","updated_at":"2025-04-10T02:24:13.562Z","avatar_url":"https://github.com/airoldilab.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# sgd\n\nsgd is an R package for large\nscale estimation. It features many stochastic gradient methods, built-in models,\nvisualization tools, automated hyperparameter tuning, model checking, interval\nestimation, and convergence diagnostics.\n\n## Features\nAt the core of the package is the function\n```{R}\nsgd(formula, data, model, model.control, sgd.control)\n```\nIt estimates parameters for a given data set and model using stochastic gradient\ndescent. The optional arguments `model.control` and `sgd.control` specify\nattributes about the model and stochastic gradient method. Taking advantage of\nthe bigmemory package, sgd also operates on data sets which are too large to fit\nin RAM as well as streaming data.\n\nExample of large-scale linear regression:\n```{R}\nlibrary(sgd)\n\n# Dimensions\nN \u003c- 1e5  # number of data points\nd \u003c- 1e2  # number of features\n\n# Generate data.\nX \u003c- matrix(rnorm(N*d), ncol=d)\ntheta \u003c- rep(5, d+1)\neps \u003c- rnorm(N)\ny \u003c- cbind(1, X) %*% theta + eps\ndat \u003c- data.frame(y=y, x=X)\n\nsgd.theta \u003c- sgd(y ~ ., data=dat, model=\"lm\")\n```\n\nAny loss function may be specified. For convenience the following are\nbuilt-in:\n* Linear models\n* Generalized linear models\n* Method of moments\n* Generalized method of moments\n* Cox proportional hazards model\n* M-estimation\n\nThe following stochastic gradient methods exist:\n* (Standard) stochastic gradient descent\n* Implicit stochastic gradient descent\n* Averaged stochastic gradient descent\n* Averaged implicit stochastic gradient descent\n* Classical momentum\n* Nesterov's accelerated gradient\n\nCheck out the vignette in [`vignettes/`](vignettes/) or examples in [`demo/`](demo/).\nIn R, the equivalent commands are `vignette(package=\"sgd\")` and\n`demo(package=\"sgd\")`.\n\n## Installation\nTo install the latest version from CRAN:\n```{R}\ninstall.packages(\"sgd\")\n```\n\nTo install the latest development version from Github:\n```{R}\n# install.packages(\"devtools\")\ndevtools::install_github(\"airoldilab/sgd\")\n```\n\n## Authors\nsgd is written by [Dustin Tran](http://dustintran.com), [Junhyung Lyle Kim](https://jlylekim.github.io/) and\n[Panos Toulis](https://www.ptoulis.com/). Please feel free to contribute by\nsubmitting any issues or requests—or by solving any current issues!\n\nWe thank all other members of the Airoldi Lab (led by Prof. Edo Airoldi) for their feedback and contributions.\n\n## Citation\n\n```\n@article{tran2015stochastic,\n  author = {Tran, Dustin and Toulis, Panos and Airoldi, Edoardo M},\n  title = {Stochastic gradient descent methods for estimation with large data sets},\n  journal = {arXiv preprint arXiv:1509.06459},\n  year = {2015}\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fairoldilab%2Fsgd","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fairoldilab%2Fsgd","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fairoldilab%2Fsgd/lists"}