Of the methylation analysis tools reviewed in Shafi et al. (2017), only MACAU (Lea, Tung, and Zhou (2015)) is specifically noted to be designed to account for population structure, in addition to biological and sampling variability (though, as this review was published almost 10 years ago, there may be more recently-developed tools with similar functionality). I want to familiarize myself more with the tool so I can try applying it to the ceasmallr data. I’ll be relying mostly on the MACAU user manual.
Like
DSS,MACAUmodels DNA methylation one site at a time, using a binomial mixed model- (Note that
MACAUcan also be applied to RNAseq data for differential expression analysis, and in these cases uses a poisson mixed model)
- (Note that
Unlike
DSS, theMACAUmanual explicitly states that “No missing data is allowed in the count table”. I think this means that, like with themethylKitwork, analysis will be restricted to a pretty small # of cytosine positions, due to several samples with low coverage. It also means that exclusion of the very low-coverage samples may again be prudent.- It will be interesting to see how this affects analysis — is there a possible outcome where
DSS’s ability to retain sites with missingness is more valuable, and I need to find a different post-DSS approach to accounting for pseudo-replication?
- It will be interesting to see how this affects analysis — is there a possible outcome where
The tool requires a pre-computed relatedness matrix to incorporate genetic/population structure information. This is something I’ll need to figure out how to get from just our WGBS data (they recommend
GEMMAto compute a relatedness matrix from SNP genotypes, and I know there are several tools to call SNPs from WGBS data by accounting for the bisulfite-induced C->T transitions, e.g.,Revelio)- There should also be more stright-forward ways to generate a relatedness matrix directly from the pedigree information (the parent IDs of each specimen). Googling returns a few options, including the R packages
pedigreeandnadiv. Only possible caveat is that this will ignore possible relatedness that is not captured by the parent IDs (e.g., what if individuals from the same family were used in both control and treatment groups? This would lead to higher relatedness between some offspring in the two groups as well, but it isn’t documented in the pedigree). This theoretically shouldn’t be too much of a problem, though, since all of the original adult oysters were collected from the wild, rather than being sourced from a hatchery/specific families (McNally et al. (2022))
- There should also be more stright-forward ways to generate a relatedness matrix directly from the pedigree information (the parent IDs of each specimen). Googling returns a few options, including the R packages
Looks like
MACAUis implemented from terminal commands, rather than through an R package.
The basic usages for association analysis are:
./macau -g [filename] -t [filename] -p [filename] -k [filename] -bmm -o [prefix]where the “-g [prefix]” specifies the methylated reads count file name; “-t [filename]” specifies the total reads count file name; “-p [filename]” specifies the predictor variable file name; “-k [filename]” specifies relatedness matrix file name; “-o [prefix]” specifies output file prefix.
(there are, of course, options for adjusting analysis parameters)
I actually just found that there is now a MACAU2, or MACAU 2.0, which is an R package for implementing the MACAU tool! This is great, because I would have needed Sam’s help installing the command-line tool for use on Klone/Raven. With an R package I can just work from a conda environment, sidestepping admin issues.