[Vegan-commits] r1016 - in pkg/vegan: R inst

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Mon Sep 21 16:15:53 CEST 2009


Author: jarioksa
Date: 2009-09-21 16:15:53 +0200 (Mon, 21 Sep 2009)
New Revision: 1016

Modified:
   pkg/vegan/R/densityplot.oecosimu.R
   pkg/vegan/inst/ChangeLog
Log:
densityplot.oecosimu did not keep the original order of the statistics in the panels

Modified: pkg/vegan/R/densityplot.oecosimu.R
===================================================================
--- pkg/vegan/R/densityplot.oecosimu.R	2009-09-20 14:54:50 UTC (rev 1015)
+++ pkg/vegan/R/densityplot.oecosimu.R	2009-09-21 14:15:53 UTC (rev 1016)
@@ -5,11 +5,10 @@
     sim <- t(x$oecosimu$simulated)
     obs <- x$oecosimu$statistic
     nm <- names(obs)[col(sim)]
-    densityplot( ~ as.vector(sim) | nm, xlab = xlab,
+    densityplot( ~ as.vector(sim) | factor(nm, levels = nm), xlab = xlab,
                 panel = function(x, ...) {
                     panel.densityplot(x, ...)
                     panel.abline(v = obs[panel.number()], ...)
                 },
                 ...)
 }
-

Modified: pkg/vegan/inst/ChangeLog
===================================================================
--- pkg/vegan/inst/ChangeLog	2009-09-20 14:54:50 UTC (rev 1015)
+++ pkg/vegan/inst/ChangeLog	2009-09-21 14:15:53 UTC (rev 1016)
@@ -4,6 +4,11 @@
 
 Version 1.16-30 (opened September 18, 2009) 
 
+	* densitplot.oecosimu: panels keep the order of statistics. The
+	panels were ordered alphabetically, but the vertical line for the
+	observed statistic was in the original order (and thus often in
+	the wrong panel).
+
 	* calibrate: is now a a generic function and has a new method for
 	the 'ordisurf' object in addition to the old 'cca' method.
 



More information about the Vegan-commits mailing list