# Print a summary of the estimated multilevel mediation model

### Description

Prints the estimated parameters (numerical summaries of the marginal posterior distributions).

### Usage

1 2 |

### Arguments

`mod` |
A |

`level` |
"Confidence" level; Defines the limits of the credible intervals. Defaults to .95 (i.e. displays 95% CIs.) |

`pars` |
Parameters to summarize. Defaults to main average-level parameters. See Details for more information. |

`digits` |
How many decimal points to display in the output. Defaults to 2. |

### Details

After estimating a model (drawing samples from the joint posterior
probability distribution) with `mlm()`

, show the estimated results
by using `mlm_summary(fit)`

, where "fit" is an object containing
the fitted model.

The function shows, for each parameter specified with `pars`

,
the posterior mean, and limits of the Credible Interval as specified
by `level`

. For example, `level = .91`

shows a
91% Credible Interval, which summarizes the central 91% mass of
the marginal posterior distribution.

#### Parameters

By default, `mlm()`

estimates and returns a large number of parameters,
including the varying effects, and their associated standard deviations.
However, `mlm_summay()`

by default only displays a subset of the
estimated parameters:

- a
Regression slope of the X -> M relationship.

- b
Regression slope of the M -> Y relationship.

- cp
Regression slope of the X -> Y relationship. (The direct effect.)

- ab
Mediated effect (

`a * b`

).- c
Total effect of X on Y. (

*cp + ab + σ_ab*)- pme
Percent mediated effect.

- covab
Estimated covariance of the participant-level a_j and b_j parameters.

- corrab
Estimated correlation of the participant-level a_j and b_j parameters.

The user may specify `pars = NULL`

to display all estimated parameters.
Other options include e.g. `pars = "tau"`

to display the varying
effects' standard deviations.

To learn more about the additional parameters, refer to the Stan code
(`cat(get_stancode(fit))`

).

### Value

A `data.frame`

summarizing the estimated multilevel
mediation model:

- Parameter
Name of parameter

- Mean
Mean of parameter's posterior distribution.

- Median
Median of parameter's posterior distribution.

- SD
Standard deviation of parameter's posterior distribution.

- ci_lwr
The lower limit of Credible Intervals.

- ci_upr
The upper limit of Credible Intervals.

- n_eff
Number of efficient samples.

- Rhat
Should be 1.00.

### Author(s)

Matti Vuorre mv2521@columbia.edu