gevaertlab / AMARETTO

Regulatory network inference and driver gene evaluation using integrative multi-omics analysis and penalized regression
Apache License 2.0
16 stars 12 forks source link

Methylation aberrations and CNV alterations #13

Closed galadrielbriere closed 5 years ago

galadrielbriere commented 5 years ago

Hello, I'm trying to run AMARETTO, and I found something that seems odd to me reading the code (amaretto_initialize.R).

MET_aberrations <- matrix(0,ncol=3,nrow=nrow(MET_matrix))
colnames(MET_aberrations) <- c("Hypo-methylated","No_change","Hyper-methylated")
rownames(MET_aberrations) <- rownames(MET_matrix)
MET_aberrations[,1] <- rowSums(MET_matrix>0)/ncol(MET_matrix)
MET_aberrations[,2] <- rowSums(MET_matrix<0)/ncol(MET_matrix)
MET_aberrations[,3] <- rowSums(MET_matrix==0)/ncol(MET_matrix)

CNV_alterations <- matrix(0,ncol=3,nrow=nrow(CNV_matrix2))
colnames(CNV_alterations) <- c("Amplification","No_change","Deletion")
rownames(CNV_alterations) <- rownames(CNV_matrix2)
CNV_alterations[,1] <- rowSums(CNV_matrix2>0)/ncol(CNV_matrix2)
CNV_alterations[,2] <- rowSums(CNV_matrix2<0)/ncol(CNV_matrix2)
CNV_alterations[,3] <- rowSums(CNV_matrix2==0)/ncol(CNV_matrix2)

I'm not used to manipulate methylation and copy number data, but I thought it would be :

MET_aberrations[,1] <- rowSums(MET_matrix<0)/ncol(MET_matrix)
MET_aberrations[,2] <- rowSums(MET_matrix==0)/ncol(MET_matrix)
MET_aberrations[,3] <- rowSums(MET_matrix>0)/ncol(MET_matrix)

and

CNV_alterations[,1] <- rowSums(CNV_matrix2>0)/ncol(CNV_matrix2)
CNV_alterations[,2] <- rowSums(CNV_matrix2==0)/ncol(CNV_matrix2)
CNV_alterations[,3] <- rowSums(CNV_matrix2<0)/ncol(CNV_matrix2)

Am I misunderstanding the data ?

Thank you in advance !

vjcitn commented 5 years ago

Thanks for raising this issue. I did not write the code you reference but I will comment to the author that the use of bare numerical indexing such as MET_aberrations[,1] is prone to questioning -- it is much better to use the colnames. Then we see immediately that

MET_aberrations[,"Hypo-methylated"] <- rowSums(MET_matrix>0)/ncol(MET_matrix)

and conclude that the event MET_matrix>0 must associate with hypomethylation ... is that right?

galadrielbriere commented 5 years ago

Yes, but shouldn't hypomethylation be associated with MET_matrix<0 ?

vjcitn commented 5 years ago

That is for the authors to answer and I hope they will do so soon :)

nathaliepochet commented 5 years ago

Hi @galadrielbriere and @vjcitn, thanks so much for your suggestions! We just updated the code accordingly in the master branch - both directionality and labeling the MET/CNV states instead of numerical indexing. Thanks much & let us know if you have any further suggestions!

galadrielbriere commented 5 years ago

I will, thank you for your answer !

monabiyan commented 5 years ago

We, therefore, close the issue! Thanks :)