[rkward-cvs] SF.net SVN: rkward:[2735] trunk/rkward/rkward/plugins/plots

tfry at users.sourceforge.net tfry at users.sourceforge.net
Thu Feb 11 09:25:42 UTC 2010


Revision: 2735
          http://rkward.svn.sourceforge.net/rkward/?rev=2735&view=rev
Author:   tfry
Date:     2010-02-11 09:25:42 +0000 (Thu, 11 Feb 2010)

Log Message:
-----------
corrections to box_plot.js

Modified Paths:
--------------
    trunk/rkward/rkward/plugins/plots/box_plot.js
    trunk/rkward/rkward/plugins/plots/box_plot.xml

Modified: trunk/rkward/rkward/plugins/plots/box_plot.js
===================================================================
--- trunk/rkward/rkward/plugins/plots/box_plot.js	2010-02-11 08:55:58 UTC (rev 2734)
+++ trunk/rkward/rkward/plugins/plots/box_plot.js	2010-02-11 09:25:42 UTC (rev 2735)
@@ -1,17 +1,4 @@
-/* ------- This file generated by php2js from PHP code. --------
-Please check this file by hand, and remove this notice, afterwards.
-Messages:
-
----------------------------- */
-
-// globals
-var undefined;
-
-
-
 function preview () {
-	preprocess ();
-	calculate ();
 	doPrintout (false);
 }
 
@@ -29,7 +16,7 @@
 	var pch_sd_low = "";
 	var horizontal = "";
 	var plot_adds = "";
-	xvarsstring = join (", ", split ("\n", getValue ("x")));
+	xvarsstring = getValue ("x").split ("\n").join (", ");
 	names_mode = getValue ("names_mode");
 	mean = getValue ("mean");
 	pch_mean = getValue ("pch_mean");
@@ -48,11 +35,10 @@
 	}
 
 	if (full) {
-
 		echo ('rk.header ("Boxplot", list ("Variable(s)", rk.get.description (' + xvarsstring + ', paste.sep=", ")))\n');
 		echo ('rk.graph.on()\n');
 	}
-	echo ('try (boxplot (data_list, notch = ' + getValue ("notch")) echo (', outline = ' + getValue("outline"))echo (', horizontal = ' + getValue("orientation") + getValue ("plotoptions.code.printout") + ')) #actuall boxplot function\n');
+	echo ('try (boxplot (data_list, notch = ' + getValue ("notch") + ', outline = ' + getValue("outline") + ', horizontal = ' + getValue("orientation") + getValue ("plotoptions.code.printout") + ')) #actuall boxplot function\n');
 	if ((mean == "TRUE") && (horizontal == "TRUE")) {
 		echo ('	try (points(1:length(data_list) ~ apply(data.frame(' + xvarsstring + '),2,mean,na.rm = TRUE),pch=' + pch_mean + ', cex = ' + getValue ("cex_sd_mean") + getValue ("sd_mean_color.code.printout") + ')) #calculates the mean for all data and adds a point at the corresponding position\n');
 	}
@@ -73,7 +59,7 @@
 		echo ('	points(1:length(data_list) ~ sd_high,pch=' + pch_sd_high + ', cex = ' + getValue ("cex_sd_mean") + getValue ("sd_mean_color.code.printout") + ')\n');
 	}
 
-	if (!empty (plot_adds)) {
+	if (plot_adds.length > 0) {
 		echo ('\n');
 		// print the grid() related code
 		printIndented ("\t", plot_adds);

Modified: trunk/rkward/rkward/plugins/plots/box_plot.xml
===================================================================
--- trunk/rkward/rkward/plugins/plots/box_plot.xml	2010-02-11 08:55:58 UTC (rev 2734)
+++ trunk/rkward/rkward/plugins/plots/box_plot.xml	2010-02-11 09:25:42 UTC (rev 2735)
@@ -1,6 +1,6 @@
 <!DOCTYPE rkplugin>
 	<document>
-	<code file="box_plot.php" />
+	<code file="box_plot.js" />
 	<logic>
 		<connect client="plotoptions.xvar" governor="x.available"/>
 		<set id="plotoptions.allow_type" to="true"/>


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the rkward-tracker mailing list