Skip to content

Commit

Permalink
readme
Browse files Browse the repository at this point in the history
  • Loading branch information
laura-dangelo committed Sep 29, 2023
1 parent c7331d2 commit 967e4e4
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,13 @@ knitr::opts_chunk$set(
[![R-CMD-check](https://github.com/laura-dangelo/SANple/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/laura-dangelo/SANple/actions/workflows/R-CMD-check.yaml)
<!-- badges: end -->

The goal of SANple is to ...
The goal of SANple is to estimate Bayesian nested mixture models via MCMC methods. Specifically, the package implements the common atoms model (Denti et al., 2023), its finite version (D'Angelo et al., 2023), and a hybrid finite-infinite model (D'Angelo and Denti, 2023+). All models use Gaussian mixtures with a normal-inverse-gamma prior distribution on the parameters. Additional functions are provided to help analyzing the results of the fitting procedure.

D’Angelo, L., Canale, A., Yu, Z., Guindani, M. (2023). Bayesian nonparametric analysis for the detection of spikes in noisy calcium imaging data. *Biometrics* 79(2), 1370--1382. doi:10.1111/biom.13626.

D’Angelo, L., and Denti, F. (2023+). A finite-infinite shared atoms nested model for the Bayesian analysis of large grouped data sets. *Working paper* 0--23.

Denti, F., Camerlenghi, F., Guindani, M., Mira, A., 2023. A Common Atoms Model for the Bayesian Nonparametric Analysis of Nested Data. *Journal of the American Statistical Association*. 118(541), 405--416. doi:10.1080/01621459.2021.1933499.

## Installation

Expand All @@ -36,7 +42,15 @@ This is a basic example which shows you how to solve a common problem:

```{r example}
library(SANple)
## basic example code
set.seed(123)
y <- c(rnorm(170),rnorm(70,5))
g <- c(rep(1,100), rep(2, 140))
plot(density(y[g==1]), xlim = c(-5,10))
lines(density(y[g==2]), col = 2)
out <- sample_fiSAN(nrep = 3000, y = y, group = g, beta = 1)
out
```

...

0 comments on commit 967e4e4

Please sign in to comment.