Closed dokato closed 3 years ago
idea for a quick win:
if (summary(x)$branchpoints == 0)
return(list(points=rep(1, summary(x)$nodes),
segments=rep(1, length(x$SegList))))
at the beginning of strahler_order
function.
summary(x)$branchpoints
is actually sort of slow because it does some other stuff.
branchpoints=length(object$BranchPoints)
is the relevant bit, so you could use that. I forget how it handles neurons with multiple trees though.
Closed by #465
For a neuron with a single branch (e.g. attached) I'd expect Strahler's order to return 1 per each node. Instead it errors out:
single_branch_neuron.rds.zip