Entering edit mode
sara domingos
▴
10
@sara-domingos-5068
Last seen 9.7 years ago
Dear Prof. Smyth and experts,
I'm having problems in Compute Contrasts from Linear Model Fit.
These are the data, and the main question to answer is which are the
genes di
erentially expressed in the laz T36 vs laz T0 :
> targets
SlideNumber Name FileName Cy3 Cy5 Moment
1 1 chip1 chipZ10.gpr pet0 laz0 T0
2 2 chip2 chipZ20.gpr pet0 laz0 T0
3 3 chip3 chipZ30.gpr pet0 laz0 T0
4 4 chip4 chipZ136.gpr pet36 laz36 T36
5 5 chip5 chipZ236.gpr pet36 laz36 T36
6 6 chip6 chipZ336.gpr pet36 laz36 T36
>design <- modelMatrix(targets, ref = "pet0")
Found unique target names:
laz0 laz36 pet0 pet36
> design
laz0 laz36 pet36
[1,] 1 0 0
[2,] 1 0 0
[3,] 1 0 0
[4,] 0 1 -1
[5,] 0 1 -1
[6,] 0 1 -1
> fit <- lmFit(MA, design)
Coefficients not estimable: pet36
Warning message:
Partial NA coefficients for 13051 probe(s)
>cont.matrix <- makeContrasts("laz36vslaz0"=(laz36-pet36)-laz0,
levels=design)
>cont.matrix
Contrasts
Levels laz36vslaz0
laz0 -1
laz36 1
pet36 -1
> fit2 = contrasts.fit(fit, contrasts = cont.matrix)
Error in contrasts.fit(fit, contrasts = cont.matrix) :
trying to take contrast of non-estimable coefficient
Can you please help me with this?
Best Regards
Sara Domingos
(Instituto Superior de Agronomia, Lisboa, Portugal)
[[alternative HTML version deleted]]