Description Usage Arguments Value Author(s) References Examples

Estimate direct and indirect effects of treatment on binary outcomes transmitted through compositional mediators

1 2 3 |

`Y` |
a vector of binary outcomes |

`M` |
a matrix of compositional data |

`tr` |
a vector of continuous or binary treatments |

`X` |
a matrix of covariates |

`n.cores` |
a number of CPU cores for parallel processing |

`n.boot` |
a number of bootstrap samples |

`ci.method` |
options for bootstrap confidence interval. It can be either "empirical" (default) or "percentile". |

`p.value` |
a logical value for calculating the p value. It is inactive when |

`ForSA` |
a logical value for sensitivity analysis |

`max.rho` |
a maximum correlation allowed between mediators and an outcome |

`sig.level` |
a significance level to estimate bootstrap confidence intervals for direct and indirect effects of treatment |

`FWER` |
a logical value for family-wise error rate for direct and total indirect effects. If |

`w` |
a vector of weights on samples. If measurements in a sample is more reliable than others, this argument can be used to take that information into the model. |

`prec` |
an error tolerance or a stopping criterion for the debiasd procedure |

`max.iter` |
a maximum number of iteration in the debias procedure |

Note: the range of rho is not from -1 to 1 when the number of components is more than two because the correlation between them is not zero, and the range gets smaller as the number of components increases.

If *ForSA=FALSE*,

`total` |
contains estimated direct and total indirect effects with their confidence limits |

`cwprod` |
contains component-wise products of path coefficients with their confidence limits |

If *ForSA=TRUE*,

`total` |
contains estimated direct and total indirect effects with their confidence limits |

`cwprod` |
contains component-wise products of path coefficients with their confidence limits |

`cide.rho` |
contains estimated indirect effects and corresponding pointwise 95% confidence intervals, given correlations between mediators and an outcome |

Michael B. Sohn

Maintainer: Michael B. Sohn <michael_sohn@urmc.rochester.edu>

Sohn, M.B., Lu, J. and Li, H. (2021). *A Compositional Mediation Model for Binary Outcome: Application to Microbiome Studies* (Submitted)

1 2 3 4 5 6 7 8 9 10 11 | ```
## Not run:
# Load a simulated dataset
data(cmmb_demo_data)
# Run CMM for binary outcomes
rslt <- cmmb(Y=cmmb_demo_data$Y, M=cmmb_demo_data$M,
tr=cmmb_demo_data$tr, X=cmmb_demo_data$X)
rslt
# Plot products of component-wise path coefficients
plot_cw_ide(rslt)
## End(Not run)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.