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

tfry at users.sf.net tfry at users.sf.net
Mon Mar 18 09:46:56 UTC 2013


Revision: 4606
          http://sourceforge.net/p/rkward/code/4606
Author:   tfry
Date:     2013-03-18 09:46:56 +0000 (Mon, 18 Mar 2013)
Log Message:
-----------
Add help page

Modified Paths:
--------------
    trunk/rkward/rkward/plugins/rkwarddev_scripts/subset_dataframe.R

Added Paths:
-----------
    trunk/rkward/rkward/plugins/data/subset_dataframe.rkh

Added: trunk/rkward/rkward/plugins/data/subset_dataframe.rkh
===================================================================
--- trunk/rkward/rkward/plugins/data/subset_dataframe.rkh	                        (rev 0)
+++ trunk/rkward/rkward/plugins/data/subset_dataframe.rkh	2013-03-18 09:46:56 UTC (rev 4606)
@@ -0,0 +1,64 @@
+<!DOCTYPE rkhelp >
+<document>
+	<!-- this code was generated using the rkwarddev package.
+			perhaps don't make changes here, but in the rkwarddev script instead! -->
+	<title>
+		subset_dataframe
+	</title>
+	<summary>
+		Select a subset of rows and / or columns of a data.frame
+	</summary>
+	<usage>
+		Select the data.frame to subset. Then specify rules to filter by rows / cases, and / or columns. A data.frame containing only the specified subset is saved to your workspace.
+	</usage>
+	<!-- <section id="sct_EDITORDE" title="EDIT OR DELETE ME">
+				EDIT OR DELETE ME
+			</section> -->
+	<settings>
+		<setting id="var_data">
+			Select the data.frame to subset.
+		</setting>
+		<caption id="frm_Fltrrwsb" />
+		<setting id="vrsl_Fltrbyvr">
+			Select a column of the data.frame specifying the condition to filter cases on. Leave empty, if you do not want to filter on a column.
+		</setting>
+		<setting id="drp_fltr_all">
+			Select the type of condition. Note that depending on the type of the filter variable, different options are available
+		</setting>
+		<setting id="inp_Vlpstdss">
+			The value to compare against (for condition types equal / not equal, and one of / not one of). Note that this will be pasted as R code, verbatim. This means, you can specify any valid R expression, including the name of another column of the data.frame. However, if you want to compare to fixed strings, you will have to make sure to quote these. E.g. 'c ("City A", "City B")'.
+		</setting>
+		<setting id="inp_Mnmmrmpt">
+			For comparing against ranges (condition types in between / not in between), minimum and / or maximum values can be specified. If either is omitted, only the other is checked (i.e. greater / smaller than). Note that this will be pasted as R code, verbatim. This means, you can specify any valid R expression, including the name of another column of the data.frame.
+		</setting>
+		<setting id="mininc">
+			Whether the minimum value is contained in the range to check against (i.e. compare 'larger or equal (>=)').
+		</setting>
+		<setting id="inp_Mxmmrmpt">
+			See above. Maximum value.
+		</setting>
+		<setting id="maxinc">
+			Whether the maximum value is contained in the range to check against (i.e. compare 'smaller or equal (<=)').
+		</setting>
+		<caption id="frame_filter_exp" />
+		<setting id="inp_Exprssnr">
+			You can also filter rows / cases by a custom R expression. If using this in combination with filtering by a column (see above), both conditions are combined by logical 'and' (&). Leave empty, if you do not want to filter on a custom expression.
+		</setting>
+		<caption id="frm_Onlyssbs" />
+		<setting id="frm_Onlyssbs">
+			Check this, if you want to remove some columns from the resulting data.frame. Otherwise, all columns will be included.
+		</setting>
+		<setting id="vrsl_Slctdvrb">
+			Variables to include in the resulting data.frame
+		</setting>
+	</settings>
+	<related>
+		<ul>
+			<li>
+				<link href="rkward://rhelp/subset" />
+			</li>
+		</ul>
+	</related>
+	<technical>
+	</technical>
+</document>

Modified: trunk/rkward/rkward/plugins/rkwarddev_scripts/subset_dataframe.R
===================================================================
--- trunk/rkward/rkward/plugins/rkwarddev_scripts/subset_dataframe.R	2013-03-17 14:17:35 UTC (rev 4605)
+++ trunk/rkward/rkward/plugins/rkwarddev_scripts/subset_dataframe.R	2013-03-18 09:46:56 UTC (rev 4606)
@@ -239,7 +239,6 @@
 	echo ('\\n\\t)\\n\\n');
 ", js=FALSE)
 
-
 #############
 ## if you run the following function call, files will be written to tempdir!
 #############
@@ -255,9 +254,30 @@
 		),
 	js=list(results.header=FALSE,
 		calculate=sset.js.calc),
+	rkh=list(
+		summary = rk.rkh.summary ("Select a subset of rows and / or columns of a data.frame"),
+		usage = rk.rkh.usage ("Select the data.frame to subset. Then specify rules to filter by rows / cases, and / or columns. A data.frame containing only the specified subset is saved to your workspace."),
+		settings = rk.rkh.settings (list (
+			rk.rkh.setting (var.data, "Select the data.frame to subset."),
+			rk.rkh.caption (frame.filter.var),
+			rk.rkh.setting (filter.var, "Select a column of the data.frame specifying the condition to filter cases on. Leave empty, if you do not want to filter on a column."),
+			rk.rkh.setting (sset.filter.drop, "Select the type of condition. Note that depending on the type of the filter variable, different options are available"),
+			rk.rkh.setting (sset.input.filter, "The value to compare against (for condition types equal / not equal, and one of / not one of). Note that this will be pasted as R code, verbatim. This means, you can specify any valid R expression, including the name of another column of the data.frame. However, if you want to compare to fixed strings, you will have to make sure to quote these. E.g. 'c (\"City A\", \"City B\")'."),
+			rk.rkh.setting (sset.filter.min, "For comparing against ranges (condition types in between / not in between), minimum and / or maximum values can be specified. If either is omitted, only the other is checked (i.e. greater / smaller than). Note that this will be pasted as R code, verbatim. This means, you can specify any valid R expression, including the name of another column of the data.frame."),
+			rk.rkh.setting (sset.filter.min.inc, "Whether the minimum value is contained in the range to check against (i.e. compare 'larger or equal (>=)')."),
+			rk.rkh.setting (sset.filter.max, "See above. Maximum value."),
+			rk.rkh.setting (sset.filter.max.inc, "Whether the maximum value is contained in the range to check against (i.e. compare 'smaller or equal (<=)')."),
+			rk.rkh.caption (frame.filter.expression),
+			rk.rkh.setting (sset.filter.expression, "You can also filter rows / cases by a custom R expression. If using this in combination with filtering by a column (see above), both conditions are combined by logical 'and' (&). Leave empty, if you do not want to filter on a custom expression."),
+			rk.rkh.caption (frame.selected.vars),
+			rk.rkh.setting (frame.selected.vars, "Check this, if you want to remove some columns from the resulting data.frame. Otherwise, all columns will be included."),
+			rk.rkh.setting (selected.vars, "Variables to include in the resulting data.frame")
+		)),
+		related = rk.rkh.related (rk.rkh.link ("subset"))
+	),
 	pluginmap=list(name="subset_dataframe", hierarchy=list("data")),
 	dependencies=rk.XML.dependencies (),
-	create=c("pmap", "xml", "js"),
+	create=c("pmap", "xml", "js", "rkh"),
 	scan=c("saveobj", "settings"),
 	overwrite=overwrite,
 	tests=FALSE,





More information about the rkward-tracker mailing list