[rkward-cvs] SF.net SVN: rkward-code:[4848] trunk/rkward/rkward/plugins/data

tfry at users.sf.net tfry at users.sf.net
Sun Sep 28 17:40:13 UTC 2014


Revision: 4848
          http://sourceforge.net/p/rkward/code/4848
Author:   tfry
Date:     2014-09-28 17:40:11 +0000 (Sun, 28 Sep 2014)
Log Message:
-----------
Document recode categorical plugin

Modified Paths:
--------------
    trunk/rkward/rkward/plugins/data/recode_categorical.rkh
    trunk/rkward/rkward/plugins/data/recode_categorical.xml

Modified: trunk/rkward/rkward/plugins/data/recode_categorical.rkh
===================================================================
--- trunk/rkward/rkward/plugins/data/recode_categorical.rkh	2014-09-28 17:05:45 UTC (rev 4847)
+++ trunk/rkward/rkward/plugins/data/recode_categorical.rkh	2014-09-28 17:40:11 UTC (rev 4848)
@@ -0,0 +1,57 @@
+<!DOCTYPE rkhelp >
+<document>
+	<title>
+		Recode categorical data
+	</title>
+	<summary>
+		Allows you to recode a vector with categorical data. This plugin also allows to recode vectors that are coded numerically, but this only makes
+		sense for numeric vectors with only a limited number of unique values.
+	</summary>
+	<usage>
+		Select the vector to recode, and where to store the recoded data. Select the storage mode of the resulting data. Then, on the second tab, specify
+		the recodings to make.
+	</usage>
+	<settings>
+		<caption id="tab_in_out"/>
+		<setting id="x">
+			Select the vector to recode
+		</setting>
+		<setting id="saveto_select">
+			Select whether to overwrite/replace the input vector with the recoded data, or save to a different vector.
+		</setting>
+		<setting id="saveto">
+			Pick a name (and optionally a container) for the recoded data.
+		</setting>
+		<setting id="datamode">
+			Storage mode of the recoded data.
+		</setting>
+		<caption id="tab_values"/>
+		<setting id="set">
+			The upper half of this tab allows you to specify recodings for individual input values. To add more recodings, click the "add/+"-button. To
+			remove recodings, click the "remove/x"-button. For each recoding, select the following:
+		</setting>
+		<setting id="old_values">
+			For each recoding to perform, first select the old value(s) to recode. This can be either NA/missing, or select non-NA value(s) on the left hand side,
+			and add them to the values to be recoded by clicking the arrow-button. If several input values are to be replaced with one output value,
+			you can select them all at once.
+		</setting>
+		<setting id="new_value">
+			Enter the new value (or set it to be NA). For factors and character vectors, values will be quoted, automatically.
+		</setting>
+		<setting id="other">
+			Any input values (including NAs) for which no recoding was specified, above, can either be left unchanged ("Copy"), or can be replaced
+			with a specific value or NA.
+		</setting>
+	</settings>
+	<related>
+		<ul>
+			<li>
+				<link href="rkward://rhelp/recode" />
+			</li>
+		</ul>
+	</related>
+	<technical>
+		This plugin utilizes the <link href="rkward://component/rkward/level_select"/> and <link href="rkward://component/rkward/multi_input"/>
+		embeddable plugins.
+	</technical>
+</document>

Modified: trunk/rkward/rkward/plugins/data/recode_categorical.xml
===================================================================
--- trunk/rkward/rkward/plugins/data/recode_categorical.xml	2014-09-28 17:05:45 UTC (rev 4847)
+++ trunk/rkward/rkward/plugins/data/recode_categorical.xml	2014-09-28 17:40:11 UTC (rev 4848)
@@ -22,9 +22,9 @@
 		]]></script>
 	</logic>
 	<dialog label="Recode categorical data"><tabbook>
-		<tab label="Input and output variables">
+		<tab label="Input and output variables" id="tab_in_out">
 			<varselector id="vars"/>
-			<varslot id="x" source="vars" label="Select variable to recode" num_dimensions="1"/>
+			<varslot id="x" source="vars" label="Select variable to recode" num_dimensions="1" required="true"/>
 			<row>
 				<radio id="saveto_select" label="Save to">
 					<option value="same" label="Same object"/>
@@ -40,10 +40,10 @@
 			</dropdown>
 			<stretch/>
 		</tab>
-		<tab label="Values">
+		<tab label="Values" id="tab_values">
 			<row>
 				<column>
-					<optionset id="set" min_rows="1">
+					<optionset id="set" min_rows="1" label="Recodings">
 						<logic>
 							<convert id="old_value_na" mode="equals" sources="old_value_type.string" standard="na"/>
 							<connect client="levels.enabled" governor="old_value_na.not"/>





More information about the rkward-tracker mailing list