Gene Density computation in pca.hic
Entering edit mode
cath ▴ 30
Last seen 3.6 years ago

I'm using package HiTC (HiTC_1.22.1) to find A/B compartments in my data.

I tried to use parameter to directly link eigenvector sign with A/B annotation. However, I got very different results from the ones obtained when trying to compute gene density myself.

Looking at pca.hic function, it seems that gene density is actually gene number per sign, whatever the number of bins is.

Is there a bug in pca.hic function (like function sum is used instead of mean - lines 47 and 48 at or am I missing something?

Thank you.

HiTC • 621 views
Entering edit mode

Hi Cath,

Indeed, the gene density is calculated as  the number of genes falling in A (resp. B) compartments. Therefore as a sum. Would you have any reference explaining why using a mean might be better ?



Entering edit mode

Thank you very much for you reply.

I just understood "density" as a concentration of genes so, to me, it needed to be referenced to the length of the genome "portion" it was computed on. E.g. if there is twice as many bins with score < 0 but same number of genes in bins with score < 0 than in bins with score > 0, then gene density will be higher in the bins with score >0 (but sum of genes would still be same)

Concerning a reference, this article explains computation of local gene densities, so not exactly the same, but it seems close to what I have in mind.

I hope it makes sense.

Best regards,



Login before adding your answer.

Traffic: 345 users visited in the last hour
Help About
Access RSS

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6