[rkward-cvs] SF.net SVN: rkward: [1734] trunk/rkward/rkward/plugins/analysis/TESTS

tfry at users.sourceforge.net tfry at users.sourceforge.net
Mon Mar 26 17:57:02 UTC 2007


Revision: 1734
          http://svn.sourceforge.net/rkward/?rev=1734&view=rev
Author:   tfry
Date:     2007-03-26 10:57:02 -0700 (Mon, 26 Mar 2007)

Log Message:
-----------
Adjustments to mood.test
* local() adjustments
* remove unused tabbook
* show alternative only in rk.header, names only in rk.results
* reworded help a bit

Modified Paths:
--------------
    trunk/rkward/rkward/plugins/analysis/TESTS/mood_test.php
    trunk/rkward/rkward/plugins/analysis/TESTS/mood_test.rkh
    trunk/rkward/rkward/plugins/analysis/TESTS/mood_test.xml

Modified: trunk/rkward/rkward/plugins/analysis/TESTS/mood_test.php
===================================================================
--- trunk/rkward/rkward/plugins/analysis/TESTS/mood_test.php	2007-03-26 17:51:33 UTC (rev 1733)
+++ trunk/rkward/rkward/plugins/analysis/TESTS/mood_test.php	2007-03-26 17:57:02 UTC (rev 1734)
@@ -3,32 +3,22 @@
 }
 
 function calculate () {
-
 ?>
-rk.temp.x <- substitute (<? getRK ("x"); ?>)
-rk.temp.y <- substitute (<? getRK ("y"); ?>)
-rk.temp <- mood.test (eval (rk.temp.x), eval (rk.temp.y), alternative = "<? getRK ("alternative"); ?>")
-
+result <- mood.test (<? getRK ("x"); ?>, <? getRK ("y"); ?>, alternative = "<? getRK ("alternative"); ?>")
 <?
 }
 
 function printout () {
 ?>
-rk.header ("Mood Two-Sample Test of Scale",
-	parameters=list ("Comparing", paste (rk.get.description (rk.temp.x, is.substitute=TRUE), "and", rk.get.description (rk.temp.y, is.substitute=TRUE)), "Alternative Hypothesis", "<? getRK ("alternative"); ?>"))
+names <- rk.get.description (<? getRK ("x"); ?>, <? getRK ("y"); ?>)
 
+rk.header (result$method,
+	parameters=list ("Alternative Hypothesis", rk.describe.alternative (result)))
+
 rk.results (list (
-	'Variables'=rk.get.description (rk.temp.x, rk.temp.y, is.substitute=TRUE),
-	'Z'=rk.temp$statistic,
-	'p-value'=rk.temp$p.value,
-	'Alternative Hypothesis'=rk.describe.alternative(rk.temp)
-	))
+	'Variables'=names,
+	'Z'=result$statistic,
+	'p-value'=result$p.value))
 <?
 }
-
-function cleanup () {
 ?>
-rm (list=grep ("^rk.temp", ls (), value=TRUE))
-<?
-}
-?>

Modified: trunk/rkward/rkward/plugins/analysis/TESTS/mood_test.rkh
===================================================================
--- trunk/rkward/rkward/plugins/analysis/TESTS/mood_test.rkh	2007-03-26 17:51:33 UTC (rev 1733)
+++ trunk/rkward/rkward/plugins/analysis/TESTS/mood_test.rkh	2007-03-26 17:57:02 UTC (rev 1734)
@@ -9,15 +9,13 @@
 	</usage>
 
 	<settings>
-		<caption id="tab_variables"/>
-		<setting id="x">Select the data to be computed. The vectors need to be numeric.</setting>
-		<setting id="y">Select the data to be computed. The vectors need to be numeric.</setting>
-		<setting id="alternative">Here you can specify the alternative hypothesis. It must be one of "two sided", "greater" or "less".</setting>
+		<setting id="x">First sample. The vectors need to be numeric.</setting>
+		<setting id="y">Second sample. The vectors need to be numeric.</setting>
+		<setting id="alternative">Alternative hypothesis to use for the test.</setting>
 	</settings>
 	<related>
 		<ul>
 			<li><link href="rkward://rhelp/mood.test"/></li>
 		</ul>
-
 	</related>
 </document>

Modified: trunk/rkward/rkward/plugins/analysis/TESTS/mood_test.xml
===================================================================
--- trunk/rkward/rkward/plugins/analysis/TESTS/mood_test.xml	2007-03-26 17:51:33 UTC (rev 1733)
+++ trunk/rkward/rkward/plugins/analysis/TESTS/mood_test.xml	2007-03-26 17:57:02 UTC (rev 1734)
@@ -5,22 +5,18 @@
 	<help file="mood_test.rkh"/>
 	
 	<dialog label="Mood Two-Sample Test of Scale">
-		<tabbook>
-			<tab label="Basic settings" id="tab_variables">
-				<row>
-					<varselector id="vars"/>
-					<column>
-						<varslot type="numeric" id="x" source="vars" required="true" label="compare"/>
-						<varslot type="numeric" id="y" source="vars" required="true" label="against"/>
-						<radio id="alternative" label="using test hypothesis">
-							<option value="two.sided" label="Two-sided"/>
-							<option value="greater" label="First is greater"/>
-							<option value="less" label="Second is greater"/>
-						</radio>
-					</column>
-				</row>
-			</tab>
-		</tabbook>
+		<row>
+			<varselector id="vars"/>
+			<column>
+				<varslot type="numeric" id="x" source="vars" required="true" label="compare"/>
+				<varslot type="numeric" id="y" source="vars" required="true" label="against"/>
+				<radio id="alternative" label="using test hypothesis">
+					<option value="two.sided" label="Two-sided"/>
+					<option value="greater" label="greater"/>
+					<option value="less" label="less"/>
+				</radio>
+			</column>
+		</row>
 	</dialog>
 	
 </document>


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