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

tfry at users.sourceforge.net tfry at users.sourceforge.net
Fri Mar 16 15:09:45 UTC 2007


Revision: 1609
          http://svn.sourceforge.net/rkward/?rev=1609&view=rev
Author:   tfry
Date:     2007-03-16 08:09:44 -0700 (Fri, 16 Mar 2007)

Log Message:
-----------
Prettifications and help page for histogram plugin

Modified Paths:
--------------
    trunk/rkward/rkward/plugins/Makefile.am
    trunk/rkward/rkward/plugins/plots/color_chooser.xml
    trunk/rkward/rkward/plugins/plots/histogram.xml

Added Paths:
-----------
    trunk/rkward/rkward/plugins/plots/histogram.rkh

Modified: trunk/rkward/rkward/plugins/Makefile.am
===================================================================
--- trunk/rkward/rkward/plugins/Makefile.am	2007-03-16 14:37:01 UTC (rev 1608)
+++ trunk/rkward/rkward/plugins/Makefile.am	2007-03-16 15:09:44 UTC (rev 1609)
@@ -48,7 +48,8 @@
 	plots/stem.php \
 	plots/plot_stepfun_options.rkh \
 	plots/plot_stepfun_options.xml \
-	plots/plot_stepfun_options.php
+	plots/plot_stepfun_options.php \
+	plots/histogram.rkh
 
 pluginsXdistributionsdir = $(kde_datadir)/rkward/distributions
 dist_pluginsXdistributions_DATA = \

Modified: trunk/rkward/rkward/plugins/plots/color_chooser.xml
===================================================================
--- trunk/rkward/rkward/plugins/plots/color_chooser.xml	2007-03-16 14:37:01 UTC (rev 1608)
+++ trunk/rkward/rkward/plugins/plots/color_chooser.xml	2007-03-16 15:09:44 UTC (rev 1609)
@@ -5,6 +5,9 @@
 	<logic>
 		<external id="argument" default=", col=" />
 		<external id="default_color" default="" />
+
+		<!-- This is just a dirty workaround. Actually, this should be solved at the C++ level, somehow -->
+		<connect client="color.enabled" governor="enabled"/>
 	</logic>
 	<dialog label="Choose color" >
 		<dropdown id="color" label="Color">

Added: trunk/rkward/rkward/plugins/plots/histogram.rkh
===================================================================
--- trunk/rkward/rkward/plugins/plots/histogram.rkh	                        (rev 0)
+++ trunk/rkward/rkward/plugins/plots/histogram.rkh	2007-03-16 15:09:44 UTC (rev 1609)
@@ -0,0 +1,29 @@
+<!DOCTYPE rkplugin>
+<document>
+	<summary>
+		Plot a histogram.
+	</summary>
+	<usage>
+		Select a variable to plot a histogram for. For available options, see below.
+	</usage>
+	<settings>
+		<caption id="tab_variables"/>
+		<setting id="x">The variable to plot the histogram for</setting>
+		<caption id="tab_histoptions"/>
+		<setting id="histogram_opt">Options concerning the calculation and look of the histogram. Refer to <link href="rkward://component/histogram_options"/> for details.</setting>
+		<caption id="tab_densityoptions"/>
+		<setting id="density">Should a density curve be plotted over the histogram? This option is only available, if the histogram is density scaled.</setting>
+		<setting id="col_density">Which color should the density line be drawn in?</setting>
+		<setting id="bw">The smoothing bandwidth used to calculate the density estimate. See <link href="rkward://rhelp/density"/> for details.</setting>
+		<setting id="adjust">Factor to adjust the bandwith by.</setting>
+		<setting id="narm">Remove missing values? If not checked, missing values will cause an error.</setting>
+		<setting id="n">Number of equally spaced points to estimate the density at.</setting>
+	</settings>
+	<related>
+		<ul>
+			<li><link href="rkward://component/histogram_options"/></li>
+			<li><link href="rkward://rhelp/hist"/></li>
+			<li><link href="rkward://rhelp/density"/></li>
+		</ul>
+	</related>
+</document>

Modified: trunk/rkward/rkward/plugins/plots/histogram.xml
===================================================================
--- trunk/rkward/rkward/plugins/plots/histogram.xml	2007-03-16 14:37:01 UTC (rev 1608)
+++ trunk/rkward/rkward/plugins/plots/histogram.xml	2007-03-16 15:09:44 UTC (rev 1609)
@@ -1,6 +1,7 @@
 <!DOCTYPE rkplugin>
 <document>
 	<code file="histogram.php" />
+	<help file="histogram.rkh" />
 	<logic>
 		<connect client="plotoptions.xvar" governor="x.available"/>
 		<set id="plotoptions.allow_log" to="false"/>
@@ -12,11 +13,18 @@
 		<set id="histogram_opt.allow_addtoplot" to="false" />
 		
 		<convert id="densityscaled" mode="equals" sources="histogram_opt.freq.state" standard="0" />
-		<connect client="densityoptions.enabled" governor="densityscaled" />
+		<connect client="tab_densityoptions.enabled" governor="densityscaled" />
+		
+		<convert id="dodensity" mode="and" sources="densityscaled;density.state"/>
+		<connect client="col_density.enabled" governor="dodensity"/>
+		<connect client="bw.enabled" governor="dodensity"/>
+		<connect client="adjust.enabled" governor="dodensity"/>
+		<connect client="narm.enabled" governor="dodensity"/>
+		<connect client="n.enabled" governor="dodensity"/>
 	</logic>
 	<dialog label="Histogram" >
 		<tabbook>
-			<tab label="Variable(s)" >
+			<tab label="Variable(s)" id="tab_variables">
 				<row>
 					<varselector id="vars" />
 					<column>
@@ -27,14 +35,18 @@
 					</column>
 				</row>
 			</tab>
-			<tab label="Histogram Options" >
-				<embed id="histogram_opt" component="rkward::histogram_options" as_button="false" />
+			<tab label="Histogram Options" id="tab_histoptions">
+				<embed id="histogram_opt" component="rkward::histogram_options" as_button="false" label="Histogram Options"/>
 			</tab>
-			<tab label="Density" id="densityoptions">
+			<tab label="Density" id="tab_densityoptions">
+				<checkbox value_unchecked="0" value="1" checked="false" id="density" label="Plot Density curve" />
 				<row>
-					<column>
-						<checkbox value_unchecked="0" value="1" checked="false" id="density" label="Plot Density curve" />
+					<frame label="General options">
+						<checkbox id="narm" label="Remove Missing Values" value="na.rm=TRUE" value_unchecked="na.rm=FALSE" checked="true" />
 						<embed id="col_density" component="rkward::color_chooser" label="Color" />
+						<spinbox id="n" initial="512" label="resolution" />
+					</frame>
+					<frame label="Bandwidth options">		
 						<dropdown id="bw" label="Bandwidth">
 							<option value="nrd0" label="nrd0"/>
 							<option value="nrd" label="nrd"/>
@@ -44,15 +56,7 @@
 							<option value="SJ-dpi" label="SJ-dpi"/>
 						</dropdown>
 						<spinbox type="real" id="adjust" label="Adjust Bandwidth" initial="1"/>
-					</column>
-					<column>
-						<radio id="narm" label="Remove Missing Values">
-							<option value="na.rm = TRUE" label="TRUE"/>
-							<option value="na.rm = FALSE" label="FALSE"/>
-						</radio>
-						<spinbox id="n" initial="512" label="number of equally spaced points at which the density is to be estimated" />
-						<stretch/>
-					</column>
+					</frame>
 				</row>
 				<stretch/>
 			</tab>


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