Entering edit mode
21 months ago
Nai
▴
50
I had normalized count matrix with few negative values or I should say log transformed normalized matrix. I performed the following analysis in limma (the code is below). I got the results , I am getting all logfC value in negative or 0.56789 like that. I want to add two columns with expression values for Condition1 and Condition2.
data1 <- as.matrix(data_normal, rownames=TRUE)
meta_data <- read.csv("new_pheno_sorted_comma.csv", sep = ';', row.names = 1, header=TRUE)
phenoData <- new("AnnotatedDataFrame", data = meta_data)
expression_data <- ExpressionSet(assayData = data_normal, phenoData = phenoData)
design <- model.matrix(~condition, data = pData(expression_data))
table(pData(expression_data)[,"condition"])
fit <- lmFit(expression_data, design)
fit <- eBayes(fit)
df <- topTable(fit, coef=2, n=2000)
"normalized count matrix with few negative values" How can you have negative values in a count matrix? What's being counted? What is the source of the data? Microarrays of a given type?
I'm not sure what you think the problem is: negative logFCs are perfectly valid, they simply mean that the expression is lower in the test condition compared to the reference condition (which be the alphabetically first condition if you've not specified). If you mean that the mean difference is less than zero (and this holds across all genes, not just the significant ones), then that probably your normalisation is no good.