MarioniLab / miloR

R package implementation of Milo for testing for differential abundance in KNN graphs
https://bioconductor.org/packages/release/bioc/html/miloR.html
GNU General Public License v3.0
316 stars 20 forks source link

Inconsistent Default Values Between Functions #319

Closed DarioS closed 2 months ago

DarioS commented 2 months ago

buildGraph: d = 50, makeNhoods: d = 30, calcNhoodDistance; d is missing. User should get consistent behaviour if left blank.

> MILOdata <- calcNhoodDistance(MILOdata) # Other two functions have default value and don't error if missing.
Error in FUN(X[[i]], ...) : argument "d" is missing, with no default
MikeDMorgan commented 2 months ago

calcNhoodDistance has been superseded - the function is not deprecated for backwards compatibility. Users should use refinement_scheme="graph" in makeNhoods and fdr.weighting="graph-only" in testNhoods.

DarioS commented 1 month ago

The vignette for version 2 still illustrates calcNhoodDistance. Can you please update the best practices to match the software? Also, did you intend to write graph-overlap rather than graph-only? It does not appear to be a valid parameter value.

Error in graphSpatialFDR(x.nhoods = nhoods(x), graph = graph(x), weighting = fdr.weighting,  : 
  Weighting option not recognised - must be either k-distance, neighbour-distance, max or graph-overlap