Problem with the design matrix in limma
0
0
Entering edit mode
2.3 years ago
ap-91 • 0

Hello,

I'm Andrea and i'm a student. Currently, I'm work on phosphoproteomic data collected in an excel file. In particular, i have in each row the expression levels of gene for mutant and wild-type condition, 3 replicas for each condition (six columns: M1 M2 M3 WT1 WT2 WT3 - exe: gene1: M1 M2 M3 WT1 WT2 WT3). I have a question on the design matrix because i'm not sure i did well. This is my design matrix:

## Design Matrix
samples = factor(c(rep("M", each = 3), rep("WT", each = 3)))
design = model.matrix(~ 0+samples)
colnames(design) = levels(samples)
rownames(design) = colnames(Data)
design

> design
M WT
M1   1  0
M2   1  0
M3   1  0
WT1 0  1
WT2 0  1
WT3 0  1
attr(,"assign")
[1] 1 1
attr(,"contrasts")
attr(,"contrasts")\$samples
[1] "contr.treatment"


Is it correct? Please, someone could help me? Thanks, Andrea.

R • 695 views
0
Entering edit mode

Please use the formatting bar and especially the code option (10101) to highlight code and data examples. I've done the changes this time.