Description Usage Arguments Value

Each bacteria's absolute abundance is simulated from a lognormal distribution. Then, convert each sample to relative abundance, and simulate sequencing counts using a multinomial distribution, based on the desired number of reads and the simulated relative abundances. This also simulates an environmental variable that is produced by some of the bacteria.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 |

`df` |
A dataframe of OTU counts that is a model for data simulation. Samples are rows and bacteria are columns. |

`n_contributors` |
the number of bacteria that are to contribute to your environmental variable. |

`coeff_contributor` |
the average of the distribution used to simulate the contribution coefficient. |

`min_ab_contributor` |
The minimum log relative abundance, averaged across samples, to include a bacteria |

`sd_Y` |
the standard deviation of the simulated environmental variable |

`n_reads` |
the number of reads to be simulated per sample |

`var_contributor` |
If you use a uniform distribution, this is the range of the distribution, with a normal distribution it is the variance used to simulate the contribution coefficient. |

`use_uniform` |
use a uniform distribution to simulate the contribution coefficient. Alternative is the normal distribution. |

`n_samples_use` |
number of microbiome samples to simulate. If NULL, uses the same number of samples as in your dataframe |

`corr_value` |
the bug-bug correlation value you want to include in the simulation |

`return_absolute` |
returns the abosulte abundance values instead of the simulated microbiome counts |

`seed` |
random seed for reproducibility |

a list containing 1) the simulated count data 2) the simulated environmental variable and 3) the simulated contribution coefficients

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.