Skip to content

Commit

Permalink
betadisper fails if all distances==0: minimal fix to issue #372
Browse files Browse the repository at this point in the history
(cherry picked from commit f03b9d2)
  • Loading branch information
jarioksa committed Nov 11, 2020
1 parent 586ac47 commit 2e4a12e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion R/betadisper.R
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,9 @@
zij <- zij*sqrt(n.group[group]/(n.group[group]-1))
}
## add in correct labels
colnames(vectors) <- names(eig) <- paste("PCoA", seq_along(eig), sep = "")
if (any(want))
colnames(vectors) <- names(eig) <-
paste("PCoA", seq_along(eig), sep = "")
if(is.matrix(centroids))
colnames(centroids) <- names(eig)
else
Expand Down

0 comments on commit 2e4a12e

Please sign in to comment.