dendrosplit icon indicating copy to clipboard operation
dendrosplit copied to clipboard

error in splitting step

Open sinclaircooper opened this issue 6 years ago • 2 comments

Hi I am using dendrosplit and am running into an error when trying to perform the split step:

the error seems to revolve around the following lines # Numerical error edge case handling epsilon = 1e-8
num_err_fix = np.abs(np.mean(X1,0)-np.mean(X0,0)) < epsilon X1[:,num_err_fix] = 0
X0[:,num_err_fix] = 0

and the error is: line 105, in select_genes_using_Welchs X1[:,num_err_fix] = 0 IndexError: too many indices for array

Commenting out these lines results in the code running as expected, what exactly is the purpose of those lines in the welchs test? How essential is that bit of pre-processing?

Cheers!

sinclaircooper avatar Oct 18 '18 13:10 sinclaircooper

I think this section of code is an artifact left over from when the method was being developed, although I'm surprised it would error here. If you can recreate the error using a small dataset, feel free to email the dataset to me and I'll take a closer look.

jessemzhang avatar Oct 18 '18 22:10 jessemzhang

Thanks for the reply Jesse, I'll test with my data and see how much of a difference it makes. For your information, I've ported your code to python3 so that its compatible with my existing pre-processing code. It could be something to do with that.

sinclaircooper avatar Oct 19 '18 09:10 sinclaircooper