Description Usage Arguments Details Value See Also Examples
Functions to create, populate, summarise and utilise MangroveTree objects.
1 2 3 4 5 6 7 8 9 10 11 12 |
tree |
An object of class |
x |
An object of class |
object |
An object of class |
ped |
An object of class \codeMangrovePed |
ORs |
An object of class |
K |
The prevalence of the disease (between 0 and 1, or NULL if not known) |
overwrite |
Logical. If set to FALSE, and sampling has already been performed, then existing samples will be used. If TRUE, sampling is performed again. |
iter |
Number of samples to draw from the posterior distribution of number of affecteds. |
... |
Arguments to be passed on to other methods. |
The MangroveTree class is used for holding family trees, and for performing risk prediction on them. The initialiseTree
function creates an empty tree, and the tree$addPed
populates it from genetic data. You can then sample from the posterior distribution of number of affecteds using the tree$getPrevs
function.
The print
method writes a text version of the tree to screen, and the summary
method writes some basic information about what the tree contains, along with what calculations have and have not been performed on it. The plot
method is not implemented, and throws an error message.
To see an example of the use of this class, use vignette("Mangrove")
.
For initialiseTree
, an empty object of class MangroveTree
. For the tree$getPrevs
class function, an object of class MangroveSample
.
For all other functions, nothing is returned.
MangrovePed
, MangroveORs
, MangroveSample
1 2 3 4 5 6 7 8 9 10 11 | data(famped)
data(exampleORs)
tree <- initialiseTree()
tree$addPed(famped,exampleORs)
print(tree)
summary(tree)
sam <- tree$getPrevs(exampleORs,K=0.02)
summary(sam)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.