ae_probs: Adverse event probabilities

Description Usage Arguments Value Examples

View source: R/adverse-events.R

Description

Obtain adverse event probabilities for treatment sequences given existing probabilities by treatment from a network meta-analysis.

Usage

1
ae_probs(n, struct, params_ae = iviNSCLC::params_ae_nma)

Arguments

n

The number of random observations of the parameters to draw.

struct

A model_structure object.

params_ae

Parameter estimates of the probabilities of adverse events in the same format as params_ae_nma.

Value

A list of matrices where each matrix corresponds to a type of adverse event. Rows of each matrix are posterior samples of the parameters and columns are treatment strategies. The list is an object of class "ae_probs" with an attribute "tx_abb" denoting the treatment used to estimate adverse events for each treatment sequence.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
txseq1 <- txseq(first = "erlotinib",
                second = c("osimertinib", "PBDC"),
                second_plus = c("PBDC + bevacizumab", "PBDC + bevacizumab"))
txseq2 <- txseq(first = "gefitinib",
                second = c("osimertinib", "PBDC"),
                second_plus = c("PBDC + bevacizumab", "PBDC + bevacizumab"))
txseqs <- txseq_list(seq1 = txseq1, seq2 = txseq2) 
struct <- model_structure(txseqs)
ae_probs <- ae_probs(n = 3, struct = struct)
print(ae_probs[1:3])
tidy_ae_probs <- tidy(ae_probs)
head(tidy_ae_probs)

InnovationValueInitiative/IVI-NSCLC documentation built on July 25, 2019, 8:03 p.m.