pneuvial / c3co

Inferring cancer cell clonality from copy-number data
5 stars 1 forks source link

Inconsistency in get.W: when M = 2, ncol(Z) = 2 x J (and not J) #64

Closed jchiquet closed 5 years ago

jchiquet commented 5 years ago

From the optimization point of view, solving in W when the signal dimension M is equal to 2 can be achieved by binding column-wisely and row-wisely.

However, in this case, neither nrow(Z) nor ncol(Y) is equal to J but to 2 x J. Hence, the documentation of the function is inconsistent and then we cannot test reliably for K <= J within the function.

HenrikBengtsson commented 5 years ago

Double checking: could it be that we incorrectly use, say, J <- ncol(Y) somewhere in the code as the true J?

pneuvial commented 5 years ago

From the maths side, I'd say that what we did is correct, ie:

checking that 2J (= ncol(Y)) is larger than K (= number of subclones)

is really what we want to check for, because the matrix Z is K x 2J. So I'd argue it makes sense to keep that sanity check.

From the copy-number side, my intuition is that if we have J < K <= 2J then it may be that

ie again the sanity check K <= 2J makes sense.