-
Notifications
You must be signed in to change notification settings - Fork 0
/
cs.Rmd
49 lines (35 loc) · 913 Bytes
/
cs.Rmd
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
---
title: "``brms::cs``"
output: html_document
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
library(brms)
```
## ``cs``
Category Specific Predictors in brms Models
#### Description
Category Specific Predictors in brms Models
#### Usage
<pre><code>
cs(expr)
<code></pre>
#### Arguments
* ``expr``: Expression containing predictors, for which category specific effects should be estimated. For evaluation, R formula syntax is applied.
#### Examples
```{r}
fit <- brm(rating ~ period + carry + cs(treat),
data = inhaler, family = sratio("cloglog"),
prior = set_prior("normal(0,5)"), chains = 2)
```
```{r}
summary(fit)
```
```{r}
plot(fit, ask = FALSE)
```
#### Details
For detailed documentation see help(brmsformula) as well as vignette("brms_overview").
This function is almost solely useful when called in formulas passed to the brms package.
#### See Also
brmsformula