Plots an NMDS of uscores output from the uscores
or uscoresi
functions.
uMDS(uscor, group = NULL, title = NULL, legend.pos = "bottomleft")
A data frame of uscores or ranks of uscores produced by either the uscores(...)
or uscoresi(...)
functions
Optional grouping variable. Sites will be represented by different colored symbols for each group.
Optional title for the NMDS graph.
For when group is specified, the location of the legend on the graph showing the colors representing each group’s data. Default is “bottomleft”. Alternatives are “topright” and “centerleft”, etc.
Prints an NMDS plot of censored data groupings based on U-scores #' @references Helsel, D.R., 2011. Statistics for Censored Environmental Data using Minitab and R, 2nd ed. John Wiley & Sons, USA, N.J.
data(PbHeron)
PbHeron.u <- uscores(PbHeron[,4:15])
uMDS(PbHeron.u)
#> Run 0 stress 0.07773434
#> Run 1 stress 0.07851582
#> Run 2 stress 0.07844726
#> Run 3 stress 0.07762542
#> ... New best solution
#> ... Procrustes: rmse 0.009282758 max resid 0.03814667
#> Run 4 stress 0.07788834
#> ... Procrustes: rmse 0.008004743 max resid 0.03035308
#> Run 5 stress 0.0866076
#> Run 6 stress 0.07851582
#> Run 7 stress 0.07851582
#> Run 8 stress 0.07762542
#> ... New best solution
#> ... Procrustes: rmse 2.104328e-06 max resid 6.969749e-06
#> ... Similar to previous best
#> Run 9 stress 0.1323278
#> Run 10 stress 0.08660761
#> Run 11 stress 0.07773434
#> ... Procrustes: rmse 0.009283605 max resid 0.03812724
#> Run 12 stress 0.1408586
#> Run 13 stress 0.08660761
#> Run 14 stress 0.1271666
#> Run 15 stress 0.08639937
#> Run 16 stress 0.08639937
#> Run 17 stress 0.07851582
#> Run 18 stress 0.07844726
#> Run 19 stress 0.07851582
#> Run 20 stress 0.1399472
#> *** Best solution repeated 1 times
#> species scores not available
# With group specific
uMDS(PbHeron.u,group=PbHeron$DosageGroup)
#> Run 0 stress 0.07773434
#> Run 1 stress 0.0866076
#> Run 2 stress 0.07762542
#> ... New best solution
#> ... Procrustes: rmse 0.009283386 max resid 0.03814368
#> Run 3 stress 0.08639937
#> Run 4 stress 0.07762542
#> ... New best solution
#> ... Procrustes: rmse 2.547714e-06 max resid 9.289536e-06
#> ... Similar to previous best
#> Run 5 stress 0.07851582
#> Run 6 stress 0.07844726
#> Run 7 stress 0.07788834
#> ... Procrustes: rmse 0.008005042 max resid 0.03034233
#> Run 8 stress 0.07851582
#> Run 9 stress 0.07851582
#> Run 10 stress 0.08639937
#> Run 11 stress 0.08639937
#> Run 12 stress 0.07844726
#> Run 13 stress 0.07762542
#> ... New best solution
#> ... Procrustes: rmse 3.608319e-06 max resid 1.41164e-05
#> ... Similar to previous best
#> Run 14 stress 0.07851582
#> Run 15 stress 0.07844726
#> Run 16 stress 0.08660765
#> Run 17 stress 0.1271669
#> Run 18 stress 0.07844726
#> Run 19 stress 0.1396654
#> Run 20 stress 0.07762542
#> ... Procrustes: rmse 2.801298e-06 max resid 8.68652e-06
#> ... Similar to previous best
#> *** Best solution repeated 2 times