Closed MaximilianNuber closed 1 month ago
@MaximilianNuber I'm sorry, I completely missed this issue - I will do some tests and update shortly - but yeah, your suggestion seems to be a good fit
@MaximilianNuber fixed and thanks for bringing it to my attention (and sorry for replying so late, this notification completely slipped through me)
Dear all, Thank you for the great package. I want use miloDE with a milo-object previously constructed with miloR (to use BPPARAM, BSPARAM, etc.). The source code in https://github.com/MarioniLab/miloDE/blob/main/R/assign_neighbourhoods.R at line 68 uses
if (is(x , "SingleCellExperiment"))
, where x is the input SingleCellExperiment and/or Milo-object.I believe the problem is, that a milo-object is still a SingleCellExperiment (
is(milo.obj, "SingleCellExperiment") == TRUE
) therefore the function continues to construct a new neighborhood graph even though the input is a milo-object with existent graph. In some trial and error i foundis(milo.obj, "SingleCellExperiment") && !is(milo.obj, "Milo")
to be the best check here. Would it be alright to test this and possibly update?Thank you and best regards, Max