i try to implement LIMMA for paired samples in order to compare gene expression before/after treatment. But...i'm not confident in my results since every single gene expression seems to be significantly associeted with the treatment!

Here is my methodology:


where df is a dataframe with: -1000 columns for different gene expression -+ 1 column 'id' (10 different id, repeated 2 times) -+ 1 column 'ttt' (0=before, 1=after treatment) -20 rows of observations (10 patients observed twice)

So once I get my matrix:

subject_id<-df$id A vector with 10 different id repeated 2 times

ttt<-as.factor(df$ttt) A vector with the treatment status (before/after)

Here is my design matrix:

design<-model.matrix(~ 0+ttt)

colnames(design) <- levels(ttt)

As asked in limma() description i specify the correlations:

corfit <- duplicateCorrelation(mat,design,block=subject_id)

Fiting of the model:

fit<-lmFit(mat,design,block =subject_id,correlation = corfit$consensus)


Getting adjusted pvalues for every gene comparison before/after treatment:

topTable(fit2, adjust.method='BH',number=1000)

But every single gene expression seems to be relevant, so i'm very doubtful about my methodology Any idea? Many thanks!

  • $\begingroup$ what do you actually have, RNAseq or microarray data? I suspect you have RNAseq data and you need to normalize it $\endgroup$
    – StupidWolf
    Dec 4 '20 at 22:56
  • $\begingroup$ Hello, thank you for your response. I have transcriptomic responses, with logarithmic transformation (one value per gene expression). $\endgroup$
    – Gwénolé
    Dec 5 '20 at 18:28
  • $\begingroup$ What u have above should be ok. Just note that for the last step u are testing all coefficients to be zero. Not sure if that is what u want $\endgroup$
    – StupidWolf
    Dec 6 '20 at 2:13
  • $\begingroup$ But if you specify treatment and groups correctly. It should be ok. Without more info, hard to tell $\endgroup$
    – StupidWolf
    Dec 6 '20 at 2:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.