Skip to content

Comparing conditions were altered when including adjustCovariate for some covariates #69

@MinhTTNguyen

Description

@MinhTTNguyen

Hello,

I'm reaching out for help with my EM-Seq data analysis using dmrseq to identify DMRs between two puberty epoch groups (Late vs. Early) within the same sex (M: male). I have three samples per group. Since my dataset is large (human genome), I created a bsseq object for each of the 24 human chromosomes and ran dmrseq on each unsmoothed bsseq object using the following command:

regions <- dmrseq(bs=dat, 
                               cutoff=0.05, 
                               maxPerms=10,
                               testCovariate="group",
                               adjustCovariate=c("pH","Bisulfite_conversion"))

However, I noticed an issue in the output displayed in RStudio:

Assuming the test covariate group is a factor.
Condition: 3_LateM1_EarlyM vs. 1_EarlyM3_LateM

The expected condition should be "3_LateM vs. 1_EarlyM", but when I include the adjustCovariate argument, dmrseq() alters the condition formatting unexpectedly.

Interestingly, when I exclude adjustCovariate=c("pH", "Bisulfite_conversion"), the function runs correctly. Moreover, when adjusting for some other covariates, dmrseq() behaves as expected, but for certain covariates, the "condition" variable gets altered.

I assigned "group" as factor in the pData().

Since I don't see any issues with the input data or metadata, I'm uncertain why dmrseq() modifies the "condition" variable when adjusting for certain covariates. Could you please help me with some explanation about this issue?

Thank you very much in advance!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions