Plots an NMDS of uscores output from the uscores or uscoresi functions.

uMDS(uscor, group = NULL, title = NULL, legend.pos = "bottomleft")

Arguments

uscor

A data frame of uscores or ranks of uscores produced by either the uscores(...) or uscoresi(...) functions

group

Optional grouping variable. Sites will be represented by different colored symbols for each group.

title

Optional title for the NMDS graph.

legend.pos

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.

Value

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.

Examples

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.07788834 
#> ... Procrustes: rmse 0.01183675  max resid 0.0375004 
#> Run 3 stress 0.07762542 
#> ... New best solution
#> ... Procrustes: rmse 0.009283173  max resid 0.03814571 
#> Run 4 stress 0.07788834 
#> ... Procrustes: rmse 0.008009005  max resid 0.03037396 
#> Run 5 stress 0.07851582 
#> Run 6 stress 0.07851582 
#> Run 7 stress 0.07851582 
#> Run 8 stress 0.07788834 
#> ... Procrustes: rmse 0.00801355  max resid 0.03040875 
#> Run 9 stress 0.07762542 
#> ... Procrustes: rmse 3.286839e-06  max resid 1.27818e-05 
#> ... Similar to previous best
#> Run 10 stress 0.08660761 
#> Run 11 stress 0.07788834 
#> ... Procrustes: rmse 0.008004957  max resid 0.03034339 
#> Run 12 stress 0.07844726 
#> Run 13 stress 0.07793355 
#> ... Procrustes: rmse 0.01226045  max resid 0.0383258 
#> Run 14 stress 0.07762542 
#> ... Procrustes: rmse 2.714527e-06  max resid 9.617289e-06 
#> ... Similar to previous best
#> Run 15 stress 0.08639937 
#> Run 16 stress 0.07788834 
#> ... Procrustes: rmse 0.008007308  max resid 0.03035284 
#> Run 17 stress 0.1271666 
#> Run 18 stress 0.07851582 
#> Run 19 stress 0.07762542 
#> ... Procrustes: rmse 3.850551e-06  max resid 1.344128e-05 
#> ... Similar to previous best
#> Run 20 stress 0.07844726 
#> *** Best solution repeated 3 times
#> species scores not available


# With group specific
uMDS(PbHeron.u,group=PbHeron$DosageGroup)
#> Run 0 stress 0.07773434 
#> Run 1 stress 0.07762542 
#> ... New best solution
#> ... Procrustes: rmse 0.009283202  max resid 0.03814628 
#> Run 2 stress 0.07762542 
#> ... Procrustes: rmse 6.432944e-06  max resid 2.846602e-05 
#> ... Similar to previous best
#> Run 3 stress 0.07773434 
#> ... Procrustes: rmse 0.009282962  max resid 0.03812369 
#> Run 4 stress 0.07788834 
#> ... Procrustes: rmse 0.008007566  max resid 0.03036202 
#> Run 5 stress 0.07788834 
#> ... Procrustes: rmse 0.008002881  max resid 0.03032272 
#> Run 6 stress 0.07851582 
#> Run 7 stress 0.08660762 
#> Run 8 stress 0.07844726 
#> Run 9 stress 0.1356213 
#> Run 10 stress 0.08660763 
#> Run 11 stress 0.07793355 
#> ... Procrustes: rmse 0.01226  max resid 0.03832577 
#> Run 12 stress 0.1323278 
#> Run 13 stress 0.07851582 
#> Run 14 stress 0.0866076 
#> Run 15 stress 0.07844726 
#> Run 16 stress 0.07788834 
#> ... Procrustes: rmse 0.008009614  max resid 0.03037974 
#> Run 17 stress 0.07844726 
#> Run 18 stress 0.07844726 
#> Run 19 stress 0.08660762 
#> Run 20 stress 0.1323278 
#> *** Best solution repeated 1 times