Hi good day,
This is my first time working on differential gene expression analysis using DeSeq2. I am having a problem to construct my model matrix for DeSeq2 since I have a very complex experimental design (3 factors design) with the following information;
ID Ewed Lambd Sex 1768 HIGH CONV M 1774 HIGH CONV F 1778 HIGH CONV F 1788 HIGH CONV F 1796 HIGH CONV M 1766 LOW CONV F 1772 LOW CONV M 1784 LOW CONV M 1810 LOW CONV F 1816 LOW CONV M 1818 LOW CONV F 1822 LOW CONV M 1826 LOW CONV F 1828 LOW CONV F 1764 NORM CONV F 1770 NORM CONV F 1782 NORM CONV M 1792 NORM CONV M 1802 NORM CONV F 1804 NORM CONV F 1755 HIGH HCHF M 1767 HIGH HCHF F 1777 HIGH HCHF F 1787 HIGH HCHF M 1799 HIGH HCHF M 1823 HIGH HCHF F 1759 LOW HCHF M 1775 LOW HCHF F 1783 LOW HCHF M 1785 LOW HCHF M 1807 LOW HCHF F 1821 LOW HCHF M 1827 LOW HCHF F 1761 NORM HCHF F 1763 NORM HCHF F 1769 NORM HCHF M 1789 NORM HCHF M
I would like to construct the model matrix for three way interaction effects (Ewed:Lambd:Sex) but could not do so in which I got this error "the model matrix is not full rank".
Ewed: Maternal diet Lambd: offspring diet
Could anyone suggest me what can or should I do? I read the DeSeq2 vigenette about this kind of problem but could not really understand it.
Your help is much appreciated.
Best, Mila
Hi Micheal,
Thank you for your feedback.
I have tried to consult with someone that have knowledge in this matter but could not find any solution to that (for now)
I have also tried to run this following model matrix but got error
design <- model.matrix(~ -1 + per$Lambbw6 + per$Birthw + per$Lambbw2.5, per)
ddstissue <- DESeqDataSetFromHTSeqCount(sampleTable=per, directory=pathht, design = ~ Ewed + Lambd + Sex ) ddstissue
#
factor levels were dropped which had no samples
That is not an error, it is just a helpful message that there were factor levels which had no samples, and so these levels were dropped for you (otherwise the model would be impossible to fit).