Methylation workflow problem
0
0
Entering edit mode
7 months ago
Roy ▴ 10

Hello all,

I have been getting stuck on methylation workflow via R while following this guide:

https://nbis-workshop-epigenomics.readthedocs.io/en/latest/content/tutorials/methylationArray/Array_Tutorial.html

This happens near the end, where I am to create a design matrix and contrast matrix. I am running 8 samples, where they are all in separate groups as I am just trying to compare them individually to each other to look for certain methylated or unmethylated genes in the sample.

Nothing would work for the contMatrix, until I set one of the individuals as the 'reference' as shown below.

contMatrix <- makeContrasts(
  VLDFI48_vs_VLDFI44 = individualVLDFI48 - individualVLDFI44,
  VLDFJ48_vs_VLDFI44 = individualVLDFJ48 - individualVLDFI44,
  VLDFJ52_vs_VLDFI44 = individualVLDFJ52 - individualVLDFI44,
  VLDFJ68_vs_VLDFI44 = individualVLDFJ68 - individualVLDFI44,
  VLDFJ97_vs_VLDFI44 = individualVLDFJ97 - individualVLDFI44,
  VLDFK15_vs_VLDFI44 = individualVLDFK15 - individualVLDFI44,
  VLDMT6455_vs_VLDFI44 = individualVLDMT6455 - individualVLDFI44,
  levels = design)

The following error occurs, rightfully so, as there are no replicates:

Error in .ebayes(fit = fit, proportion = proportion, stdev.coef.lim = stdev.coef.lim,  : 
  No residual degrees of freedom in linear model fits

I am supposed to go on to make a variable called fit2 as below:

# fit the contrasts
fit2 <- contrasts.fit(fit, contMatrix)
# Rank genes
fit2 <- eBayes(fit2)

This is needed for annotation, and I tried just using 'fit' that I made a couple lines (to avoid this error) earlier with the error saying I need to run eBayes or treat first.

My question is: am I doing too much? I just want to assess the copy number plot for certain arms of chromosome 1, as well as assess if MGMT along with other genes are methylated or not. Do I have the required data already based off of the guide link I first sent? Everything has already been normalized.

Thank you to anyone that can assist.

Best,
Roy

rstudio methylation • 242 views
ADD COMMENT

Login before adding your answer.

Traffic: 1777 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6