# Set up start
data.table::setDTthreads(1)
# Filter drugs appearing in at least 10% of reports
screen_drug(
.data = drug_,
mp_data = mp_,
freq_threshold = 0.10
)
# Get the top 5 most reported drugs
screen_drug(
.data = drug_,
mp_data = mp_,
top_n = 5
)
# nb: in the example datasets, not all drugs are recorded in mp_,
# leading to NAs in screen_drug output.
# Set up end
data.table::setDTthreads(0)
Run the code above in your browser using DataLab