Skip to contents

Filter taxa recorded at less than x percent of visits

Usage

filter_prop(df, context = "cell", min_sites = 15, keep = NULL, default_per = 1)

Arguments

df

Dataframe with taxa and context

context

Character. Column names that define context, usually a 'visit' to a 'cell'.

min_sites

Absolute minimum sites at which a taxa should be recorded.

keep

Character. taxa that should not be dropped. Used to set x percent of sites.

default_per

If keeptaxa is NULL, what is the minimum percent of sites at which a taxa should be recorded.

Value

df filtered to exclude taxa recorded at less than x percent of visits.