-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathREADME.Rmd
More file actions
50 lines (34 loc) · 2.69 KB
/
README.Rmd
File metadata and controls
50 lines (34 loc) · 2.69 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
---
output: github_document
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
```{r setup, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/",
out.width = "100%"
)
```
# distrom
<!-- badges: start -->
[](https://cran.r-project.org/package=distrom)
[](https://cran.r-project.org/package=distrom)
<!-- badges: end -->
The R package *distrom* contains functions for computing a distributed multinomial regression. The main function is `dmr()` which takes a matrix of `covars` and a matrix of multinomial `counts` as input. Independent Poisson log regressions of the form `counts ~ covars` are then fit for each multinomial count. These independent Poisson log regressions are estimated in parallel using the `parallel` and `gamlr` packages which allows for easy in-memory parallelization and distribution across multiple machines. This parallelization is essential for use cases such as text analysis where the `counts` matrix consists of many tokenized documents and can grow to billions of observations. In the text analysis use case token counts are modeled as arising from a multinomial distribution that is dependent upon the article attributes contained in the `covars` matrix.
To cite this package, use "Taddy (2015), Distributed Multinomial Regression, Annals of Applied Statistics".
## Links
For a description of the functions in the *distrom* package please read the reference manual: [distrom manual](https://cran.r-project.org/web/packages/distrom/distrom.pdf)
For a detailed explanation of distributed multinomial regression and example use cases see: [*Taddy (2015), Distributed Multinomial Regression, Annals of Applied Statistics*](https://arxiv.org/abs/1311.6139)
For information on the related *gamlr* package please read the [gamlr manual](https://cran.r-project.org/web/packages/gamlr/gamlr.pdf) or visit the [gamlr repository](https://github.com/TaddyLab/gamlr).
For information on the related *textir* package please read the [textir manual](https://cran.r-project.org/web/packages/textir/textir.pdf) or visit the [textir repository](https://github.com/TaddyLab/textir).
## Installation
To install the **stable** version from [CRAN](https://cran.r-project.org/package=distrom):
```{r cran-installation, eval = FALSE}
install.packages("distrom")
```
To install the **development** version from [GitHub](https://github.com/TaddyLab/distrom):
```{r github-installation, eval = FALSE}
# install.packages("remotes")
remotes::install_github("TaddyLab/distrom")
```