get_meanMeth_islands {MethEvolSIM} | R Documentation |
Compute the Mean Methylation of CpG Islands
Description
This function calculates the mean methylation level for CpG islands across all tree tips.
Usage
get_meanMeth_islands(index_islands, data)
Arguments
index_islands |
A numeric vector specifying the indices of genomic structures corresponding to islands. |
data |
A list containing methylation states at tree tips for each genomic structure
(e.g., island/non-island). The data should be structured as |
Value
A list where each element corresponds to a tree tip and contains a numeric vector representing the mean methylation levels for the indexed CpG islands.
Examples
# Example data setup
data <- list(
# Tip 1
list(rep(1,10), rep(0,5), rep(1,8)),
# Tip 2
list(rep(1,10), rep(0.5,5), rep(0,8))
)
index_islands <- c(1,3)
get_meanMeth_islands(index_islands, data)
[Package MethEvolSIM version 0.2.1 Index]