[rkward-cvs] SF.net SVN: rkward:[3168] trunk/rkward
m-eik at users.sourceforge.net
m-eik at users.sourceforge.net
Sun Oct 31 21:49:24 UTC 2010
Revision: 3168
http://rkward.svn.sourceforge.net/rkward/?rev=3168&view=rev
Author: m-eik
Date: 2010-10-31 21:49:24 +0000 (Sun, 31 Oct 2010)
Log Message:
-----------
rkwardtests: several fixes (including test suites)
Modified Paths:
--------------
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/NAMESPACE
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.makeplugintests.R
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.replaceRunAgainLink.R
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.runRKTestSuite.R
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.setSuiteStandards.R
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rkwardtests-internal.R
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.makeplugintests.Rd
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.replaceRunAgainLink.Rd
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.runRKTestSuite.Rd
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.setSuiteStandards.Rd
trunk/rkward/tests/all_tests.R
trunk/rkward/tests/analysis_plugins.R
trunk/rkward/tests/distributions.R
trunk/rkward/tests/import_export_plugins/RKTestStandard.package_skeleton.rkcommands.R
trunk/rkward/tests/import_export_plugins.R
trunk/rkward/tests/item_response_theory.R
trunk/rkward/tests/plots.R
trunk/rkward/tests/rkward_application_tests.R
Added Paths:
-----------
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.getTempDir.R
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.getTempDir.Rd
Removed Paths:
-------------
trunk/rkward/tests/test_framework.R
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/NAMESPACE
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/NAMESPACE 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/NAMESPACE 2010-10-31 21:49:24 UTC (rev 3168)
@@ -1,9 +1,11 @@
import(methods)
exportClasses(RKTest)
+export(rktest.getTempDir)
export(rktest.makeplugintests)
export(rktest.replaceRunAgainLink)
exportClasses(RKTestResult)
export(rktest.runRKTestSuite)
export(rktest.setSuiteStandards)
exportClasses(RKTestSuite)
+export(.rktest.tmp.storage)
exportMethods(show)
Added: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.getTempDir.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.getTempDir.R (rev 0)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.getTempDir.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -0,0 +1,30 @@
+#' Get the path to the recent temporary directory, if one exists.
+#'
+#' This function will return either the local path to the temporary directory where
+#' all test results have been saved to, or FALSE if none exitsts.
+#'
+#' @title Get path to the temporary directory
+#' @usage rktest.getTempDir()
+#' @aliases rktest.getTempDir
+#' @return Either a character string, or FALSE.
+#' @author Meik Michalke \email{meik.michalke@@uni-duesseldorf.de}
+#' @keywords utilities
+#' @seealso \code{\link[rkwardtests:rktest.makeplugintests]{rktest.makeplugintests}}
+#' @export
+#' @examples
+#' rktest.getTempDir()
+
+rktest.getTempDir <- function(){
+ if(exists(".rktest.temp.dir", where=.rktest.tmp.storage)){
+ temp.dir <- get(".rktest.temp.dir", pos=.rktest.tmp.storage)
+ if(file_test("-d", temp.dir)) {
+ return(temp.dir)
+ }
+ else {
+ return(FALSE)
+ }
+ }
+ else {
+ return(FALSE)
+ }
+}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.makeplugintests.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.makeplugintests.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.makeplugintests.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -12,7 +12,6 @@
#' @param append If TRUE, append output to an existing file.
#' @param test.id Optional character string or vector naming one or more tests of a suite to be run (if NULL, all tests are run).
#' @return Results are printed to stdout and saved to the defined output file.
-#' @docType function
#' @author Thomas Friedrichsmeier \email{thomas.friedrichsmeier@@ruhr-uni-bochum.de}, Meik Michalke \email{meik.michalke@@uni-duesseldorf.de}
#' @keywords utilities
#' @seealso \code{\link[rkwardtests:RKTestSuite]{RKTestSuite-class}}, \code{\link[rkwardtests:RKTestResult]{RKTestResult-class}}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.replaceRunAgainLink.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.replaceRunAgainLink.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.replaceRunAgainLink.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -11,7 +11,6 @@
#' @aliases .rk.rerun.plugin.link.replacement
#' @param restore Logical: If TRUE, restore the original behaviour.
#' @return Replaces the "Run again" link in RKWard with the code that would have been called, or vice versa.
-#' @docType function
#' @author Thomas Friedrichsmeier \email{thomas.friedrichsmeier@@ruhr-uni-bochum.de}, Meik Michalke \email{meik.michalke@@uni-duesseldorf.de}
#' @keywords utilities
#' @seealso \code{\link[rkwardtests:RKTestSuite]{RKTestSuite-class}}, \code{\link[rkwardtests:rktest.makeplugintests]{rktest.makeplugintests}}
@@ -19,7 +18,6 @@
#' @rdname rktest.replaceRunAgainLink
#' @examples
#' rktest.replaceRunAgainLink()
-#' }
rktest.replaceRunAgainLink <- function(restore=FALSE){
if(!restore){
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.runRKTestSuite.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.runRKTestSuite.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.runRKTestSuite.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -9,7 +9,6 @@
#' @param basedir Defaults to the working directory.
#' @param test.id An optional character string or vector naming one or more tests of a suite to be run (if NULL, all tests are run).
#' @return An object of class \code{\link[rkwardtests:RKTestResult]{RKTestResult-class}}.
-#' @docType function
#' @author Thomas Friedrichsmeier \email{thomas.friedrichsmeier@@ruhr-uni-bochum.de}, Meik Michalke \email{meik.michalke@@uni-duesseldorf.de}
#' @keywords utilities
#' @seealso \code{\link[rkwardtests:RKTestSuite]{RKTestSuite-class}}, \code{\link[rkwardtests:rktest.makeplugintests]{rktest.makeplugintests}}
@@ -22,7 +21,7 @@
rktest.runRKTestSuite <- function (suite, basedir=getwd (), test.id=NULL) {
# check wheter test environment is already set,
# otherwise initialize
- if(!exists(".rktest.tmp.storage", where=globalenv())){
+ if(!exists("initialized", where=rkwardtests::.rktest.tmp.storage) || !get("initialized", pos=rkwardtests::.rktest.tmp.storage)){
rktest.initializeEnvironment()
on.exit(rktest.resetEnvironment())
}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.setSuiteStandards.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.setSuiteStandards.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.setSuiteStandards.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -10,7 +10,6 @@
#' @param basedir Should point to the testroot, defaults to the working directory.
#' @return The function simply changes the names of the previously created files,
#' specifically adding the prefix "RKTestStandard.".
-#' @docType function
#' @author Thomas Friedrichsmeier \email{thomas.friedrichsmeier@@ruhr-uni-bochum.de}
#' @keywords utilities
#' @seealso \code{\link[rkwardtests:RKTestSuite]{RKTestSuite-class}}, \code{\link[rkwardtests:rktest.makeplugintests]{rktest.makeplugintests}}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rkwardtests-internal.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rkwardtests-internal.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rkwardtests-internal.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -1,5 +1,9 @@
# these functions are all used internally
+# create an internal environment for temporary information storage
+#' @export .rktest.tmp.storage
+.rktest.tmp.storage <- new.env()
+
.rk.rerun.plugin.link.replacement <- function (plugin, settings, label) {
.rk.cat.output ("<h3>Rerun code:</h3>")
.rk.cat.output ("<pre>")
@@ -157,9 +161,6 @@
## Convenience functions for replacing / restoring functions for the test runs
rktest.replace <- function (name, replacement, envir=as.environment ("package:rkward"), backup.name=name) {
- if(!exists(".rktest.tmp.storage", where=globalenv())){
- assign(".rktest.tmp.storage", new.env(), pos=globalenv())
- } else{}
if (exists (backup.name, envir=.rktest.tmp.storage, inherits=FALSE)) {
message ("It looks like ", name, " has already been replaced. Not replacing it again.")
} else {
@@ -175,9 +176,6 @@
message ("No backup available for ", name, ". Already restored?")
}
rm (list=backup.name, envir=.rktest.tmp.storage)
- if(length(.rktest.tmp.storage) == 0){
- rm(".rktest.tmp.storage", pos=globalenv())
- } else{}
}
## Initialize test environment
@@ -211,6 +209,7 @@
stopifnot(is.character(x))
assign(".rk.output.html.file", x, as.environment("package:rkward"))
})
+ assign("initialized", TRUE, envir=.rktest.tmp.storage)
}
# counterpart to rktest.initializeEnvironment. Restores the most important settings
@@ -221,25 +220,10 @@
rktest.restore ("rk.get.tempfile.name")
rktest.restore ("rk.set.output.html.file")
rm (date, envir=globalenv())
+ assign("initialized", FALSE, envir=.rktest.tmp.storage)
}
## handling of temporary directories
-# get the path to the recent temporary directory, if exists
-rktest.getTempDir <- function(){
- if(exists(".rktest.tmp.storage", where=globalenv()) && exists(".rktest.temp.dir", where=.rktest.tmp.storage)){
- temp.dir <- get(".rktest.temp.dir", pos=.rktest.tmp.storage)
- if(file_test("-d", temp.dir)) {
- return(temp.dir)
- }
- else {
- return(FALSE)
- }
- }
- else {
- return(FALSE)
- }
-}
-
# create a temporary directory for the test results
# the path to it will be stored in an object in globalenv() and returned
rktest.createTempDir <- function(){
@@ -254,9 +238,6 @@
stop(simpleError("Couldn't create temporary directory!"))
}
else {
- if(!exists(".rktest.tmp.storage", where=globalenv())){
- assign(".rktest.tmp.storage", new.env(), pos=globalenv())
- } else{}
assign(".rktest.temp.dir", new.temp.dir, envir=.rktest.tmp.storage)
return(new.temp.dir)
}
@@ -269,9 +250,6 @@
unlink(temp.dir, recursive=TRUE)
# should the function stop here if unlink() failed?
rm(".rktest.temp.dir", envir=.rktest.tmp.storage)
- if(length(.rktest.tmp.storage) == 0){
- rm(".rktest.tmp.storage", pos=globalenv())
- } else{}
return(TRUE)
}
else {
Added: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.getTempDir.Rd
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.getTempDir.Rd (rev 0)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.getTempDir.Rd 2010-10-31 21:49:24 UTC (rev 3168)
@@ -0,0 +1,14 @@
+\name{rktest.getTempDir}
+\alias{rktest.getTempDir}
+\title{Get path to the temporary directory}
+\usage{rktest.getTempDir()}
+\description{Get the path to the recent temporary directory, if one exists.}
+\details{This function will return either the local path to the temporary directory where
+all test results have been saved to, or FALSE if none exitsts.}
+\alias{rktest.getTempDir}
+\value{Either a character string, or FALSE.}
+\author{Meik Michalke \email{meik.michalke at uni-duesseldorf.de}}
+\keyword{utilities}
+\seealso{\code{\link[rkwardtests:rktest.makeplugintests]{rktest.makeplugintests}}}
+\examples{rktest.getTempDir()}
+
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.makeplugintests.Rd
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.makeplugintests.Rd 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.makeplugintests.Rd 2010-10-31 21:49:24 UTC (rev 3168)
@@ -7,7 +7,6 @@
\details{The function \code{rktest.makeplugintests} will run a whole test suite that was prepared to check one or several RKWard plugins.}
\alias{rktest.makeplugintests}
\value{Results are printed to stdout and saved to the defined output file.}
-\docType{function}
\author{Thomas Friedrichsmeier \email{thomas.friedrichsmeier at ruhr-uni-bochum.de}, Meik Michalke \email{meik.michalke at uni-duesseldorf.de}}
\keyword{utilities}
\seealso{\code{\link[rkwardtests:RKTestSuite]{RKTestSuite-class}}, \code{\link[rkwardtests:RKTestResult]{RKTestResult-class}}}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.replaceRunAgainLink.Rd
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.replaceRunAgainLink.Rd 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.replaceRunAgainLink.Rd 2010-10-31 21:49:24 UTC (rev 3168)
@@ -10,12 +10,10 @@
This code can be used in a plugin test suite.}
\alias{.rk.rerun.plugin.link.replacement}
\value{Replaces the "Run again" link in RKWard with the code that would have been called, or vice versa.}
-\docType{function}
\author{Thomas Friedrichsmeier \email{thomas.friedrichsmeier at ruhr-uni-bochum.de}, Meik Michalke \email{meik.michalke at uni-duesseldorf.de}}
\keyword{utilities}
\seealso{\code{\link[rkwardtests:RKTestSuite]{RKTestSuite-class}}, \code{\link[rkwardtests:rktest.makeplugintests]{rktest.makeplugintests}}}
\arguments{\item{restore}{Logical: If TRUE, restore the original behaviour.}
}
-\examples{rktest.replaceRunAgainLink()
-}}
+\examples{rktest.replaceRunAgainLink()}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.runRKTestSuite.Rd
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.runRKTestSuite.Rd 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.runRKTestSuite.Rd 2010-10-31 21:49:24 UTC (rev 3168)
@@ -6,7 +6,6 @@
\details{This function can be called to run a single plugin test suite.}
\alias{rktest.runRKTestSuite}
\value{An object of class \code{\link[rkwardtests:RKTestResult]{RKTestResult-class}}.}
-\docType{function}
\author{Thomas Friedrichsmeier \email{thomas.friedrichsmeier at ruhr-uni-bochum.de}, Meik Michalke \email{meik.michalke at uni-duesseldorf.de}}
\keyword{utilities}
\seealso{\code{\link[rkwardtests:RKTestSuite]{RKTestSuite-class}}, \code{\link[rkwardtests:rktest.makeplugintests]{rktest.makeplugintests}}}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.setSuiteStandards.Rd
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.setSuiteStandards.Rd 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.setSuiteStandards.Rd 2010-10-31 21:49:24 UTC (rev 3168)
@@ -8,7 +8,6 @@
\alias{rktest.setSuiteStandards}
\value{The function simply changes the names of the previously created files,
specifically adding the prefix "RKTestStandard.".}
-\docType{function}
\author{Thomas Friedrichsmeier \email{thomas.friedrichsmeier at ruhr-uni-bochum.de}}
\keyword{utilities}
\seealso{\code{\link[rkwardtests:RKTestSuite]{RKTestSuite-class}}, \code{\link[rkwardtests:rktest.makeplugintests]{rktest.makeplugintests}}}
Modified: trunk/rkward/tests/all_tests.R
===================================================================
--- trunk/rkward/tests/all_tests.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/tests/all_tests.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -1,4 +1,4 @@
-library (rkwardtests)
+require (rkwardtests)
## add your test suite files, to this vector:
testsuites <- c (
@@ -9,4 +9,4 @@
"distributions.R",
"plots.R")
-rktest.makeplugintests (testsuites, getwd (), outfile="make_plugintests.txt")
+rktest.makeplugintests (testsuites=testsuites, outfile="make_plugintests.txt")
Modified: trunk/rkward/tests/analysis_plugins.R
===================================================================
--- trunk/rkward/tests/analysis_plugins.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/tests/analysis_plugins.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -35,6 +35,11 @@
rk.call.plugin ("rkward::corr_matrix", do_p.state="", method.string="pearson", use.string="pairwise", x.available="women[[\"weight\"]]\nwomen[[\"height\"]]", submit.mode="submit")
}),
new ("RKTest", id="correlation_matrix_plot", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "analysis_plugins"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::cor_graph", digits.real="3.00", method.string="pearson", scale.state="TRUE", use.string="pairwise.complete.obs", x.available="rock", submit.mode="submit")
}),
new ("RKTest", id="descriptive_stats", call=function () {
@@ -119,6 +124,11 @@
rk.call.plugin ("rkward::PP_test", length.state="1", lshort.string="FALSE", narm.state="0", x.available="rock[[\"shape\"]]\nrock[[\"perm\"]]\nrock[[\"peri\"]]\nrock[[\"area\"]]", submit.mode="submit")
}),
new ("RKTest", id="crosstab_n_to_1", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "analysis_plugins"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::crosstab", barplot.state="TRUE", barplot_embed.colors.string="default", barplot_embed.labels.state="0", barplot_embed.legend.state="0", barplot_embed.plotoptions.add_grid.state="0", barplot_embed.plotoptions.asp.real="0.00", barplot_embed.plotoptions.main.text="", barplot_embed.plotoptions.pointcolor.color.string="", barplot_embed.plotoptions.pointtype.string="", barplot_embed.plotoptions.sub.text="", barplot_embed.plotoptions.xaxt.state="", barplot_embed.plotoptions.xlab.text="", barplot_embed.plotoptions.xlog.state="", barplot_embed.plotoptions.xmaxvalue.text="", barplot_embed.plotoptions.xminvalue.text="", barplot_embed.plotoptions.yaxt.state="", barplot_embed.plotoptions.ylab.text="", barplot_embed.plotoptions.ylog.state="", barplot_embed.plotoptions.ymaxvalue.text="", barplot_embed.plotoptions.yminvalue.text="", barplot_embed.type.string="juxtaposed", chisq.state="TRUE", simpv.string="FALSE", x.available="warpbreaks[[\"tension\"]]", y.available="warpbreaks[[\"wool\"]]\nwarpbreaks[[\"tension\"]]", submit.mode="submit")
}),
new ("RKTest", id="crosstab_multi", call=function () {
@@ -133,6 +143,10 @@
new ("RKTest", id="hp_filter", call=function () {
.GlobalEnv$co2 <- datasets::co2 # another, incompatible co2 dataset exists in package locfit
rk.sync.global()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "analysis_plugins"))
+ on.exit(setwd(oldwd))
rk.call.plugin ("rkward::hp_filter", cycle_name.active="1", trend_name.active="1", custom.state="0", cycle_col.color.string="green4", cycle_lty.string="", cycle_lwd.real="1.00", cycle_name.objectname="hpcycle", downlab.text="", lambda.string="1600", plot_cycle.state="1", series_col.color.string="blue", series_lty.string="", series_lwd.real="1.00", trend_col.color.string="red", trend_lty.string="", trend_lwd.real="1.00", trend_name.objectname="hptrend", uplab.text="", x.available="co2", submit.mode="submit")
Modified: trunk/rkward/tests/distributions.R
===================================================================
--- trunk/rkward/tests/distributions.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/tests/distributions.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -43,9 +43,19 @@
rk.call.plugin ("rkward::beta_quantiles", logp.string="log.p = TRUE", ncp.real="0.08", p.text="-1", shape1.real="1.04", shape2.real="1.03", tail.string="lower.tail=FALSE", submit.mode="submit")
}),
new ("RKTest", id="beta_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_beta_clt", a.real="2.00", b.real="2.00", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="1", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="Sturges", histogram_opt.histfillcol.color.string="azure", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="1", nAvg.real="10.00", nDist.real="1000.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scalenorm.state="0", submit.mode="submit")
}),
new ("RKTest", id="plot_beta_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_beta_distribution", a.real="2.00", b.real="2.00", function.string="p", log.state="1", lower.state="1", max.real="1.00", min.real="0.00", n.real="100.00", ncp.real="0.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", submit.mode="submit")
}),
new ("RKTest", id="cauchy_probabilities", call=function () {
@@ -59,6 +69,11 @@
rk.call.plugin ("rkward::cauchy_quantiles", location.real="0.02", logp.string="log.p = TRUE", p.text="-1 -2", scale.real="0.98", tail.string="lower.tail=FALSE", submit.mode="submit")
}),
new ("RKTest", id="plot_cauchy_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_cauchy_distribution", function.string="d", loc.real="0.00", log.state="0", max.real="3.29", min.real="-3.29", n.real="100.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scale.real="1.00", submit.mode="submit")
}),
new ("RKTest", id="chi_squared_probabilities", call=function () {
@@ -72,9 +87,19 @@
rk.call.plugin ("rkward::chi_squared_quantiles", df.real="1.02", logp.string="log.p = TRUE", ncp.real="3.00", p.text="-1 -2", tail.string="lower.tail=FALSE", submit.mode="submit")
}),
new ("RKTest", id="chi_squared_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_chi_squared_clt", df.real="4.00", dist_stepfun.addtoplot.state="", dist_stepfun.col_hor.color.string="", dist_stepfun.col_vert.color.string="", dist_stepfun.col_y0.color.string="", dist_stepfun.col_y1.color.string="", dist_stepfun.do_points.state="", dist_stepfun.linetype.string="", dist_stepfun.verticals.state="1", drawnorm.state="1", function.string="dist", nAvg.real="12.00", nDist.real="1000.00", ncp.real="0.60", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scalenorm.state="1", submit.mode="submit")
}),
new ("RKTest", id="plot_chi_squared_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_chi_squared_distribution", df.real="4.00", function.string="d", log.state="0", max.real="24.10", min.real="0.30", n.real="100.00", ncp.real="0.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", submit.mode="submit")
}),
new ("RKTest", id="exponential_probabilities", call=function () {
@@ -84,9 +109,19 @@
rk.call.plugin ("rkward::exponential_quantiles", logp.string="log.p = TRUE", p.text="-1.1", rate.real="1.05", tail.string="lower.tail=FALSE", submit.mode="submit")
}),
new ("RKTest", id="exponential_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_exponential_clt", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="Sturges", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", nAvg.real="10.00", nDist.real="1000.00", normlinecol.color.string="grey4", normpointtype.string="h", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", rate.real="1.00", scalenorm.state="1", submit.mode="submit")
}),
new ("RKTest", id="plot_exponential_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_exponential_distribution", function.string="p", log.state="0", lower.state="0", max.real="10.00", min.real="0.00", n.real="100.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", rate.real="1.00", submit.mode="submit")
}),
new ("RKTest", id="f_probabilities", call=function () {
@@ -96,9 +131,19 @@
rk.call.plugin ("rkward::f_quantiles", df1.real="1.00", df2.real="1.00", logp.string="log.p = FALSE", ncp.real="0.00", p.text="0.95", tail.string="lower.tail=FALSE", submit.mode="submit")
}),
new ("RKTest", id="f_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_f_clt", df1.real="5.00", df2.real="5.00", drawnorm.state="0", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="Sturges", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", nAvg.real="10.00", nDist.real="1000.00", ncp.real="0.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scalenorm.state="0", submit.mode="submit")
}),
new ("RKTest", id="plot_f_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_f_distribution", df1.real="5.00", df2.real="5.00", function.string="d", log.state="1", max.real="25.00", min.real="0.00100000", n.real="100.00", ncp.real="0.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", submit.mode="submit")
}),
new ("RKTest", id="gamma_probabilities", call=function () {
@@ -108,9 +153,19 @@
rk.call.plugin ("rkward::gamma_quantiles", logp.string="log.p = TRUE", p.text="-5", rate.real="1.00", shape.real="1.00", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="gamma_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_gamma_clt", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="Sturges", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", nAvg.real="10.00", nDist.real="1000.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", rate.real="0.30", scalenorm.state="0", shape.real="5.90", submit.mode="submit")
}),
new ("RKTest", id="plot_gamma_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_gamma_distribution", function.string="d", log.state="0", max.real="4.60", min.real="0.01", n.real="100.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", rate.real="0.87", shape.real="1.61", submit.mode="submit")
}),
new ("RKTest", id="gumbel_probabilities", call=function () {
@@ -126,9 +181,19 @@
rk.call.plugin ("rkward::logistic_quantiles", location.real="1.00", logp.string="log.p = FALSE", p.text="0.95", scale.real="1.00", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="logistic_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_logistic_clt", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="1", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="int", histogram_opt.histlinetype.string="solid", histogram_opt.include_lowest.state="1", histogram_opt.rightclosed.state="", histogram_opt.usefillcol.state="", loc.real="0.00", nAvg.real="10.00", nDist.real="1000.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scale.real="3.00", scalenorm.state="0", submit.mode="submit")
}),
new ("RKTest", id="plot_logistic_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_logistic_distribution", function.string="d", loc.real="0.00", log.state="0", max.real="3.29", min.real="-3.29", n.real="100.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scale.real="1.00", submit.mode="submit")
}),
new ("RKTest", id="log_normal_probabilities", call=function () {
@@ -138,9 +203,19 @@
rk.call.plugin ("rkward::log_normal_quantiles", logp.string="log.p = FALSE", meanlog.real="0.00", p.text="0.95", sdlog.real="1.00", tail.string="lower.tail=FALSE", submit.mode="submit")
}),
new ("RKTest", id="log_normal_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_log_normal_clt", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.angle.real="45.00", histogram_opt.barlabels.state="", histogram_opt.density.real="7.00", histogram_opt.doborder.state="", histogram_opt.freq.state="0", histogram_opt.histbreaksFunction.string="Scott", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", mean.real="0.00", nAvg.real="10.00", nDist.real="1000.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scalenorm.state="0", sd.real="1.00", submit.mode="submit")
}),
new ("RKTest", id="plot_log_normal_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_lognormal_distribution", function.string="p", log.state="0", lower.state="1", max.real="3.29", mean.real="4.00", min.real="0.01", n.real="100.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", sd.real="1.00", submit.mode="submit")
}),
new ("RKTest", id="normal_probabilities", call=function () {
@@ -150,9 +225,19 @@
rk.call.plugin ("rkward::normal_quantiles", logp.string="log.p = FALSE", mean.real="0.00", p.text="0.95", sd.real="1.00", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="normal_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_normal_clt", dist_stepfun.addtoplot.state="", dist_stepfun.col_hor.color.string="blue", dist_stepfun.col_vert.color.string="blue", dist_stepfun.col_y0.color.string="gold", dist_stepfun.col_y1.color.string="cyan", dist_stepfun.do_points.state="", dist_stepfun.linetype.string="", dist_stepfun.verticals.state="1", drawnorm.state="1", function.string="dist", mean.real="0.00", nAvg.real="10.00", nDist.real="1000.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scalenorm.state="0", sd.real="1.00", submit.mode="submit")
}),
new ("RKTest", id="plot_normal_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_normal_distribution", function.string="d", log.state="0", max.real="3.29", mean.real="0.00", min.real="-3.29", n.real="100.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", sd.real="1.00", submit.mode="submit")
}),
new ("RKTest", id="t_probabilities", call=function () {
@@ -162,9 +247,19 @@
rk.call.plugin ("rkward::t_quantiles", df.real="1.00", logp.string="log.p = FALSE", ncp.real="0.00", p.text="0.95", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="t_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_t_clt", df.real="3.00", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="Sturges", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", nAvg.real="10.00", nDist.real="1000.00", ncp.real="0.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scalenorm.state="0", submit.mode="submit")
}),
new ("RKTest", id="plot_t_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_t_distribution", df.real="1.00", function.string="p", log.state="0", lower.state="1", max.real="12.92400000", min.real="-12.92400000", n.real="100.00", ncp.real="0.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", submit.mode="submit")
}),
new ("RKTest", id="tukey_probabilities", call=function () {
@@ -174,6 +269,11 @@
rk.call.plugin ("rkward::tukey_quantiles", df.text="2:11", logp.string="log.p = FALSE", nmeans.real="2.00", nranges.real="1.00", p.text="0.95", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="plot_tukey_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_tukey_distribution", df.real="5.00", log.state="0", lower.state="1", max.real="8.00", min.real="-1.00", n.real="101.00", nmeans.real="6.00", nranges.real="1.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", submit.mode="submit")
}),
new ("RKTest", id="uniform_probabilities", call=function () {
@@ -183,9 +283,19 @@
rk.call.plugin ("rkward::uniform_quantiles", logp.string="log.p = FALSE", max.real="1.00", min.real="0.00", p.text="0.95", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="uniform_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_uniform_clt", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="Sturges", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", llim.real="0.00", nAvg.real="10.00", nDist.real="1000.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scalenorm.state="0", ulim.real="1.00", submit.mode="submit")
}),
new ("RKTest", id="plot_uniform_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_uniform_distribution", function.string="d", llim.real="0.00", log.state="0", max.real="2.00", min.real="-1.00", n.real="100.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", ulim.real="1.00", submit.mode="submit")
}),
new ("RKTest", id="weibull_probabilities", call=function () {
@@ -195,9 +305,19 @@
rk.call.plugin ("rkward::weibull_quantiles", logp.string="log.p = FALSE", p.text="0.95", scale.real="1.00", shape.real="1.00", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="weibull_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_weibull_clt", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="Sturges", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", nAvg.real="10.00", nDist.real="1000.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scale.real="1.00", scalenorm.state="0", shape.real="2.00", submit.mode="submit")
}),
new ("RKTest", id="plot_weibull_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_weibull_distribution", function.string="d", log.state="0", max.real="5.00", min.real="0.00", n.real="100.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scale.real="1.00", shape.real="2.00", submit.mode="submit")
}),
new ("RKTest", id="binomial_probabilities", call=function () {
@@ -207,9 +327,19 @@
rk.call.plugin ("rkward::binomial_quantiles", logp.string="log.p = FALSE", p.text="0.95 .5", prob.real="0.50", size.real="3.00", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="binomial_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_binomial_clt", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="int", histogram_opt.histlinetype.string="solid", histogram_opt.include_lowest.state="1", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", nAvg.real="1.00", nDist.real="1000.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", prob.real="0.50", scalenorm.state="0", size.real="11.00", submit.mode="submit")
}),
new ("RKTest", id="plot_binomial_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_binomial_distribution", function.string="d", log.state="0", max.real="12.00", min.real="0.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="p", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", prob.real="0.50", size.real="12.00", submit.mode="submit")
}),
new ("RKTest", id="geom_probabilities", call=function () {
@@ -219,9 +349,19 @@
rk.call.plugin ("rkward::geom_quantiles", logp.string="log.p = FALSE", p.text="0.95", prob.real="0.50", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="geometric_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_geometric_clt", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="Sturges", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", nAvg.real="10.00", nDist.real="1000.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", prob.real="0.50", scalenorm.state="0", submit.mode="submit")
}),
new ("RKTest", id="plot_geometric_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_geometric_distribution", function.string="d", log.state="0", max.real="12.00", min.real="0.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="p", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", prob.real="0.50", submit.mode="submit")
}),
new ("RKTest", id="hypergeometric_probabilities", call=function () {
@@ -231,9 +371,19 @@
rk.call.plugin ("rkward::hypergeometric_quantiles", k.real="1.00", logp.string="log.p = FALSE", m.real="1.00", n.real="1.00", p.text="0.95", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="hypergeometric_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_hypergeometric_clt", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="Sturges", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", k.real="15.00", m.real="12.00", n.real="12.00", nAvg.real="10.00", nDist.real="1000.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scalenorm.state="0", submit.mode="submit")
}),
new ("RKTest", id="plot_hypergeometric_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_hypergeometric_distribution", function.string="p", k.real="15.00", log.state="0", lower.state="1", m.real="12.00", max.real="12.00", min.real="0.00", n_val.real="12.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="p", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", submit.mode="submit")
}),
new ("RKTest", id="negative_binomial_probabilities", call=function () {
@@ -243,9 +393,19 @@
rk.call.plugin ("rkward::negative_binomial_quantiles", logp.string="log.p = FALSE", p.text="0.95", prob.real="0.50", size.real="4.00", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="negbinomial_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_negbinomial_clt", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="Sturges", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", nAvg.real="10.00", nDist.real="1000.00", normlinecol.color.string="red", normpointtype.string="l", param.string="pprob", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", prob.real="0.28", scalenorm.state="0", size_disp.real="12.00", size_trial.real="12.00", submit.mode="submit")
}),
new ("RKTest", id="plot_negbinomial_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_negbinomial_distribution", function.string="d", log.state="0", max.real="24.00", min.real="0.00", param.string="pprob", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="p", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", prob.real="0.75", size_disp.real="12.00", size_trial.real="12.00", submit.mode="submit")
}),
new ("RKTest", id="poisson_probabilities", call=function () {
@@ -255,9 +415,19 @@
rk.call.plugin ("rkward::poisson_quantiles", lambda.real="1.00", logp.string="log.p = FALSE", p.text="0.95", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="poisson_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_poisson_clt", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="Sturges", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", mean.real="5.00", nAvg.real="10.00", nDist.real="1000.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scalenorm.state="0", submit.mode="submit")
}),
new ("RKTest", id="plot_poisson_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_poisson_distribution", function.string="d", log.state="0", max.real="12.00", mean.real="5.00", min.real="0.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="p", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", submit.mode="submit")
}),
new ("RKTest", id="wilcoxon_probabilities", call=function () {
@@ -267,14 +437,24 @@
rk.call.plugin ("rkward::wilcoxon_quantiles", logp.string="log.p = FALSE", m.real="1.00", n.real="2.00", p.text="0.95", tail.string="lower.tail=TRUE", submit.mode="submit")
}),
new ("RKTest", id="wilcoxon_clt", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_wilcoxon_clt", drawnorm.state="1", function.string="hist", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="", histogram_opt.density.real="-1.00", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="Sturges", histogram_opt.histlinetype.string="solid", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", nAvg.real="10.00", nDist.real="1000.00", nm.real="4.00", nn.real="6.00", normlinecol.color.string="red", normpointtype.string="l", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", scalenorm.state="0", submit.mode="submit")
}),
new ("RKTest", id="plot_wilcoxon_distribution", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "distributions"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_wilcoxon_distribution", function.string="d", log.state="0", max.real="24.00", min.real="0.00", nm.real="4.00", nn.real="6.00", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="p", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", submit.mode="submit")
})
), postCalls = list ( # like initCalls: run after all tests to clean up.
function () {
- suppressWarnings (rm (list=c (), envir=globalenv()))
+ suppressWarnings (rm (list=c ("rock"), envir=globalenv()))
}
)
)
Modified: trunk/rkward/tests/import_export_plugins/RKTestStandard.package_skeleton.rkcommands.R
===================================================================
--- trunk/rkward/tests/import_export_plugins/RKTestStandard.package_skeleton.rkcommands.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/tests/import_export_plugins/RKTestStandard.package_skeleton.rkcommands.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -1,10 +1,10 @@
local({
## Prepare
## Compute
-package.skeleton(name="anRpackage", list=c('rktest.setSuiteStandards','rktest.runRKTestSuite'), path=".", force= TRUE)
+package.skeleton(name="anRpackage", list=c('skel.func1','skel.func2'), path=".", force= TRUE)
## Print result
rk.header("Create package skeleton", parameters=list("Name", "anRpackage",
"Directory", "."))
})
-.rk.rerun.plugin.link(plugin="rkward::save_skeleton", settings="data.available=rktest.setSuiteStandards\\nrktest.runRKTestSuite\nforce.state=TRUE\nname.text=anRpackage\npath.selection=.", label="Run again")
+.rk.rerun.plugin.link(plugin="rkward::save_skeleton", settings="data.available=skel.func1\\nskel.func2\nforce.state=TRUE\nname.text=anRpackage\npath.selection=.", label="Run again")
.rk.make.hr()
Modified: trunk/rkward/tests/import_export_plugins.R
===================================================================
--- trunk/rkward/tests/import_export_plugins.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/tests/import_export_plugins.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -7,21 +7,30 @@
function () {
# prepare some different files for loading
library ("datasets")
- women <- datasets::women
-
- save (women, file="women.RData")
- write.csv (women, file="women.csv")
-
- suppressWarnings (rm ("women"))
+ assign("women.data", datasets::women, pos=globalenv())
}
## the tests
), tests = list (
new ("RKTest", id="load_r_object", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "import_export_plugins"))
+ on.exit(setwd(oldwd))
+
+ save (women.data, file="women.RData")
+
rk.call.plugin ("rkward::load_r_object", file.selection="women.RData", envir.active="0", submit.mode="submit")
- stopifnot (all.equal (.GlobalEnv$women, datasets::women))
+ stopifnot (all.equal (.GlobalEnv$women.data, datasets::women))
}),
new ("RKTest", id="import_csv", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "import_export_plugins"))
+ on.exit(setwd(oldwd))
+
+ write.csv (women.data, file="women.csv")
+
rk.call.plugin ("rkward::import_csv", allow_escapes.state="", blanklinesskip.state="TRUE", checkname.state="TRUE", colclass.string="", colname.string="", dec.string="'.'", doedit.state="0", file.selection="women.csv", flush.state="", isrow.state="true", na.text="NA", name.objectname="women", nrows.text="-1", quick.string="csv", quote.string="'\\\"'", sep.string="','", skip.text="0", strings_as_factors.string="", stripwhite.state="FALSE", rowname.string="rowcol", nomrow.text="1", submit.mode="submit")
stopifnot (all.equal (.GlobalEnv$women, datasets::women))
@@ -29,6 +38,10 @@
new ("RKTest", id="import_csv_overwrite", call=function () {
assign ("women", datasets::women, envir=globalenv ())
rk.sync.global ()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "import_export_plugins"))
+ on.exit(setwd(oldwd))
# this one is expected to fail, as it would overwrite the existing "women" in globalenv()
rk.call.plugin ("rkward::import_csv", file.selection="women.csv", name.objectname="women", submit.mode="submit")
@@ -62,6 +75,11 @@
for (var in my.stata.data) rk.print (rk.get.description(var))
}, libraries=c("foreign")),
new ("RKTest", id="load_source", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "import_export_plugins"))
+ on.exit(setwd(oldwd))
+
stopifnot (!exists ("testx", globalenv ()))
cat ("testx <- c (20:30)\nprint (\"ok\")\n", file="source.R")
@@ -79,6 +97,10 @@
assign ("testx", datasets::warpbreaks, envir=globalenv())
assign ("testy", datasets::volcano, envir=globalenv())
rk.sync.global()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "import_export_plugins"))
+ on.exit(setwd(oldwd))
rk.call.plugin ("rkward::save_r", ascii.state="TRUE", compress.state="TRUE", data.available="testx", file.selection="x.RData", submit.mode="submit")
rk.call.plugin ("rkward::save_r", ascii.state="TRUE", compress.state="TRUE", data.available="testy", file.selection="y.RData", submit.mode="submit")
@@ -92,6 +114,10 @@
new ("RKTest", id="write_vector_matrix", call=function () {
assign ("testx", c (1:10), globalenv())
rk.sync.global()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "import_export_plugins"))
+ on.exit(setwd(oldwd))
rk.call.plugin ("rkward::save_variables", append.state="FALSE", data.available="testx", file.selection="data", ncolumns.real="2.", sep.string=",", submit.mode="submit")
@@ -101,6 +127,10 @@
new ("RKTest", id="write_table", call=function () {
assign ("women", datasets::women, globalenv())
rk.sync.global()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "import_export_plugins"))
+ on.exit(setwd(oldwd))
rk.call.plugin ("rkward::save_table", append.state="FALSE", columns.string="TRUE", data.available="women", dec.string="'.'", eol.text="\\n", file.selection="data", na.text="NA", qmethod.string="'escape'", quote.state="TRUE", rows.string="FALSE", sep.string="'\\t'", submit.mode="submit")
@@ -108,7 +138,19 @@
for (line in x) rk.print (line)
}),
new ("RKTest", id="package_skeleton", call=function () {
- rk.call.plugin ("rkward::save_skeleton", data.available="rktest.setSuiteStandards\nrktest.runRKTestSuite", force.state="TRUE", name.text="anRpackage", path.selection=".", submit.mode="submit")
+ # create two functions to use
+ assign ("skel.func1", rkwardtests::rktest.getTempDir, envir=globalenv())
+ assign ("skel.func2", rkwardtests::rktest.getTempDir, envir=globalenv())
+ rk.sync.global()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "import_export_plugins"))
+ on.exit(setwd(oldwd))
+
+ rk.call.plugin ("rkward::save_skeleton", data.available="skel.func1\nskel.func2", force.state="TRUE", name.text="anRpackage", path.selection=".", submit.mode="submit")
+ rm (skel.func1, skel.func2, envir=globalenv())
})
- ), postCalls = list () # like initCalls: run after all tests to clean up. Empty in this case.
+ ), postCalls = list (
+ function(){rm("women.data", pos=globalenv())}
+ ) # like initCalls: run after all tests to clean up. Empty in this case.
)
Modified: trunk/rkward/tests/item_response_theory.R
===================================================================
--- trunk/rkward/tests/item_response_theory.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/tests/item_response_theory.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -107,6 +107,11 @@
new ("RKTest", id="Andersen_LR_plot", call=function () {
estimates.pcm <<- estimates$pcm
rk.sync.global ()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "item_response_theory"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::eRm_plotLR", annotation.string="items", chk_confint.state="conf", chk_ctrline.state="ctrline", chk_se.state="se", inp_items.text="", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", rad_splitcr.string="median", spin_abilfrom.real="-3.00", spin_abilto.real="3.00", spin_confint.real="0.95", spin_ctrline.real="0.95", x.available="estimates.pcm", submit.mode="submit")
}),
@@ -114,33 +119,63 @@
new ("RKTest", id="plot_Rasch", call=function () {
estimates.rasch <<- estimates$rasch
rk.sync.global ()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "item_response_theory"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_rasch", annotation.string="legend", inp_items.text="", plot_type.string="items", plot_type_item.string="ICC", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", spin_from.real="-3.80", spin_to.real="3.80", x.available="estimates.rasch", submit.mode="submit")
}),
new ("RKTest", id="plot_2PL", call=function () {
estimates.2pl <<- estimates$"2pl"
rk.sync.global ()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "item_response_theory"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_ltm", annotation.string="annot", inp_items.text="1", plot_type.string="items", plot_type_item.string="ICC", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", spin_from.real="-3.80", spin_to.real="3.80", x.available="estimates.2pl", submit.mode="submit")
}),
new ("RKTest", id="plot_3PL", call=function () {
estimates.3pl <<- estimates$"3pl"
rk.sync.global ()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "item_response_theory"))
+ on.exit(setwd(oldwd))
+
# this time, plot the test information curve
rk.call.plugin ("rkward::plot_tpm", annotation.string="annot", plot_type.string="TIC", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", spin_from.real="-3.80", spin_to.real="3.80", x.available="estimates.3pl", submit.mode="submit")
}),
new ("RKTest", id="plot_GRM", call=function () {
estimates.grm <<- estimates$grm
rk.sync.global ()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "item_response_theory"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot_grm", annotation.string="annot", inp_items.text="6", plot_type.string="items", plot_type_item.string="ICC", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", spin_categ.real="0.00", spin_from.real="-3.80", spin_to.real="3.80", x.available="estimates.grm", submit.mode="submit")
}),
new ("RKTest", id="plot_RSM", call=function () {
estimates.rsm <<- estimates$rsm
rk.sync.global ()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "item_response_theory"))
+ on.exit(setwd(oldwd))
+
# plot the first three items in one image
rk.call.plugin ("rkward::plot_rsm", annotation.string="legend", chk_ask.state="", chk_mplot.state="mplot", inp_items.text="1:3", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", spin_abilfrom.real="-4.00", spin_abilto.real="4.00", spin_probfrom.real="0.00", spin_probto.real="1.00", x.available="estimates.rsm", submit.mode="submit")
}),
new ("RKTest", id="plot_PCM", call=function () {
estimates.pcm <<- estimates$pcm
rk.sync.global ()
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "item_response_theory"))
+ on.exit(setwd(oldwd))
+
# here we plot items 3 to 6
rk.call.plugin ("rkward::plot_pcm", annotation.string="legend", chk_ask.state="", chk_mplot.state="mplot", inp_items.text="3:6", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", spin_abilfrom.real="-4.00", spin_abilto.real="4.00", spin_probfrom.real="0.00", spin_probto.real="1.00", x.available="estimates.pcm", submit.mode="submit")
})
Modified: trunk/rkward/tests/plots.R
===================================================================
--- trunk/rkward/tests/plots.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/tests/plots.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -18,46 +18,111 @@
## the tests
), tests = list (
new ("RKTest", id="barplot", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::barplot", barplot_embed.colors.string="rainbow", barplot_embed.labels.state="1", barplot_embed.legend.state="0", barplot_embed.place.string="3", barplot_embed.plotoptions.add_grid.state="0", barplot_embed.plotoptions.asp.real="0.00", barplot_embed.plotoptions.main.text="", barplot_embed.plotoptions.pointcolor.color.string="", barplot_embed.plotoptions.pointtype.string="", barplot_embed.plotoptions.sub.text="", barplot_embed.plotoptions.xaxt.state="", barplot_embed.plotoptions.xlab.text="", barplot_embed.plotoptions.xlog.state="", barplot_embed.plotoptions.xmaxvalue.text="", barplot_embed.plotoptions.xminvalue.text="", barplot_embed.plotoptions.yaxt.state="", barplot_embed.plotoptions.ylab.text="", barplot_embed.plotoptions.ylog.state="", barplot_embed.plotoptions.ymaxvalue.text="", barplot_embed.plotoptions.yminvalue.text="", barplot_embed.type.string="juxtaposed", names_exp.text="rownames (swiss)", names_mode.string="rexp", tabulate.state="0", x.available="swiss[[\"Catholic\"]]", submit.mode="submit")
rk.call.plugin ("rkward::barplot", barplot_embed.colors.string="default", barplot_embed.legend.state="1", barplot_embed.plotoptions.add_grid.state="0", barplot_embed.plotoptions.asp.real="0.00", barplot_embed.plotoptions.main.text="", barplot_embed.plotoptions.pointcolor.color.string="", barplot_embed.plotoptions.pointtype.string="", barplot_embed.plotoptions.sub.text="", barplot_embed.plotoptions.xaxt.state="", barplot_embed.plotoptions.xlab.text="", barplot_embed.plotoptions.xlog.state="", barplot_embed.plotoptions.xmaxvalue.text="", barplot_embed.plotoptions.xminvalue.text="", barplot_embed.plotoptions.yaxt.state="", barplot_embed.plotoptions.ylab.text="", barplot_embed.plotoptions.ylog.state="", barplot_embed.plotoptions.ymaxvalue.text="", barplot_embed.plotoptions.yminvalue.text="", barplot_embed.type.string="stacked", names_exp.text="names (x)", names_mode.string="default", tabulate.state="0", x.available="test_table", submit.mode="submit")
}),
new ("RKTest", id="boxplot", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::box_plot", cex_sd_mean.real="1.00", mean.state="TRUE", names_exp.text="names (x)", names_mode.string="default", notch.state="FALSE", orientation.string="FALSE", outline.state="TRUE", pch_mean.real="15.", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", sd.state="", sd_mean_color.color.string="blue", x.available="women[[\"weight\"]]\nwomen[[\"height\"]]", submit.mode="submit")
}),
new ("RKTest", id="density_plot", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::density_plot", adjust.real="1.00", bw.string="nrd0", kern.string="gaussian", n.real="512.00", narm.state="na.rm=TRUE", plot_type.string="hdr_plot", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", rug.state="0", x.available="women[[\"height\"]]", submit.mode="submit")
}, libraries = c ("hdrcde")),
new ("RKTest", id="dotchart", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::dotchart", names_exp.text="women$weight", names_mode.string="rexp", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="This is a test", plotoptions.mainisquote.state="1", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="This is a subtitle", plotoptions.subisquote.state="1", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", tabulate.state="0", x.available="women[[\"height\"]]", submit.mode="submit")
- rk.call.plugin ("rkward::dotchart", names_exp.text="names (x)", names_mode.string="default", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", tabulate.state="1", x.available="warpbreaks[[\"tension\"]]", submit.mode="submit")
+ rk.call.plugin ("rkward::dotchart", names_exp.text="names (x)", names_mode.string="default", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.mainisquote.state="1", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.subisquote.state="1", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", tabulate.state="1", x.available="warpbreaks[[\"tension\"]]", submit.mode="submit")
}),
new ("RKTest", id="ecdf_plot", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::ecdf_plot", adjust_th_pnorm.state="1", col_rug.color.string="", col_thnorm.color.string="blue", lwd.real="0.50", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", rug.state="1", side.string="side = 3", stepfun_options.addtoplot.state="", stepfun_options.col_hor.color.string="", stepfun_options.col_points.color.string="", stepfun_options.col_y0.color.string="", stepfun_options.col_y1.color.string="", stepfun_options.do_points.state="1", stepfun_options.linetype.string="", stepfun_options.verticals.state="", th_pnorm.state="1", ticksize.real="0.03", x.available="swiss[[\"Catholic\"]]", submit.mode="submit")
}),
new ("RKTest", id="generic_plot", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::plot", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", xvarslot.available="swiss", yvarslot.available="", submit.mode="submit")
}),
new ("RKTest", id="histogram", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::histogram", adjust.real="4.00", bw.string="nrd", col_density.color.string="blue", density.state="1", histogram_opt.addtoplot.state="", histogram_opt.barlabels.state="1", histogram_opt.density.real="-1.", histogram_opt.doborder.state="1", histogram_opt.freq.state="0", histogram_opt.histbordercol.color.string="", histogram_opt.histbreaksFunction.string="vec", histogram_opt.histbreaks_veclength.real="6.", histogram_opt.histlinetype.string="solid", histogram_opt.include_lowest.state="1", histogram_opt.rightclosed.state="1", histogram_opt.usefillcol.state="", n.real="512.00", narm.state="na.rm=TRUE", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", x.available="swiss[[\"Education\"]]", submit.mode="submit")
}),
new ("RKTest", id="pareto_chart", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::pareto", descriptives.state="TRUE", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", tabulate.state="FALSE", x.available="swiss[[\"Catholic\"]]", submit.mode="submit")
}, libraries=c("qcc", "xtable")),
new ("RKTest", id="piechart", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::piechart", angle.real="45.00", angle_inc.real="6.00", clockwise.state="1", colors.string="grayscale", density.real="3.00", density_inc.real="1.00", names_exp.text="names (x)", names_mode.string="default", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", radius.real="0.80", tabulate.state="0", x.available="test_table[[\"A\"]]", submit.mode="submit")
}),
new ("RKTest", id="scatterplot", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::scatterplot", cex.text="1", col.text="c ('black', 'red')", color.string="each", isCex.string="all", isPch.string="all", pch.text="1", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", pointtype.string="p", type_mode.string="all", x.available="women[[\"weight\"]]\nswiss[[\"Education\"]]", y.available="women[[\"height\"]]\nswiss[[\"Catholic\"]]", submit.mode="submit")
}),
new ("RKTest", id="scatterplot_matrix", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::scatterplot_matrix", diag.string="histogram", ellipse.state="FALSE", plot_points.state="TRUE", smooth.state="FALSE", x.available="swiss", submit.mode="submit")
}, libraries=c ("car")),
new ("RKTest", id="stem_leaf_plot", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::stem", atom.real="0.01", scale.real="1.50", width.real="80.00", x.available="swiss[[\"Fertility\"]]", submit.mode="submit")
}),
new ("RKTest", id="stripchart", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "plots"))
+ on.exit(setwd(oldwd))
+
rk.call.plugin ("rkward::stripchart", g.available="warpbreaks[[\"tension\"]]", method.string="stack", offset.real="0.50", orientation.string="Horizontal", plotoptions.add_grid.state="0", plotoptions.asp.real="0.00", plotoptions.main.text="", plotoptions.pointcolor.color.string="", plotoptions.pointtype.string="", plotoptions.sub.text="", plotoptions.xaxt.state="", plotoptions.xlab.text="", plotoptions.xlog.state="", plotoptions.xmaxvalue.text="", plotoptions.xminvalue.text="", plotoptions.yaxt.state="", plotoptions.ylab.text="", plotoptions.ylog.state="", plotoptions.ymaxvalue.text="", plotoptions.yminvalue.text="", x.available="warpbreaks[[\"breaks\"]]", submit.mode="submit")
})
), postCalls = list ( # like initCalls: run after all tests to clean up.
Modified: trunk/rkward/tests/rkward_application_tests.R
===================================================================
--- trunk/rkward/tests/rkward_application_tests.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/tests/rkward_application_tests.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -40,11 +40,23 @@
stopifnot (.GlobalEnv$promise.symbol == 123)
}),
new ("RKTest", id="output_graphics_formats", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "rkward_application_tests"))
+ on.exit(setwd(oldwd))
+
rk.graph.on(); plot (1, 1); rk.graph.off() # should produce PNG, 480*480
-
- options (rk.graphics.type="JPG", rk.graphics.width=500, rk.graphics.height=500, rk.graphics.jpg.quality=34)
+ old.options <- options()
+ options (rk.graphics.type="JPG",
+ rk.graphics.width=500,
+ rk.graphics.height=500,
+ rk.graphics.jpg.quality=34)
rk.graph.on(); plot (1, 1); rk.graph.off()
- rktest.initializeEnvironment () # restore options
+ # restore options
+ options (rk.graphics.type=old.options$rk.graphics.type,
+ rk.graphics.width=old.options$rk.graphics.width,
+ rk.graphics.height=old.options$rk.graphics.height,
+ rk.graphics.jpg.quality=old.options$rk.graphics.jpg.quality)
rk.graph.on (device.type="SVG", width=300); plot (1, 1); rk.graph.off ()
}),
@@ -59,6 +71,11 @@
rk.sync (x)
}, libraries=c ("XML")),
new ("RKTest", id="dev_off_bug", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "rkward_application_tests"))
+ on.exit(setwd(oldwd))
+
graphics.off()
stopifnot (is.null (dev.list ()))
@@ -71,6 +88,11 @@
stopifnot (is.null (dev.list ()))
}),
new ("RKTest", id="plot_history_basics", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "rkward_application_tests"))
+ on.exit(setwd(oldwd))
+
le <- "package:lattice" %in% search ()
compareCurrentPlotWith <- function (x) {
if (inherits (x, "trellis")) {
@@ -235,6 +257,11 @@
message ("mark 10")
}, libraries=c ("lattice")),
new ("RKTest", id="device_capturing_stress_test", call=function () {
+ # change dir to not mess around too much
+ oldwd <- getwd()
+ setwd(file.path(rktest.getTempDir(), "rkward_application_tests"))
+ on.exit(setwd(oldwd))
+
# This test checks for the "figure margins too large" error, that used to occur when plotting on a fresh device, sometimes.
# Since the error only appeared occasionally, we try 100 times to produce it. Unfortunately, that does make the test run annoyingly long...
graphics.off()
Deleted: trunk/rkward/tests/test_framework.R
===================================================================
--- trunk/rkward/tests/test_framework.R 2010-10-31 12:23:55 UTC (rev 3167)
+++ trunk/rkward/tests/test_framework.R 2010-10-31 21:49:24 UTC (rev 3168)
@@ -1,310 +0,0 @@
-setClass ("RKTestSuite",
- representation (id="character", libraries="character", initCalls="list", tests="list", postCalls="list"),
- prototype(character(0), id=NULL, libraries=character(0), initCalls=list(), tests=list(), postCalls=list ()),
- validity=function (object) {
- if (length (object at id) != 1) return (FALSE)
- if (length (object at tests) < 1) return (FALSE)
- return (TRUE)
- }
- )
-
-setClass ("RKTest",
- representation (id="character", call="function", fuzzy_output="logical", expect_error="logical", libraries="character"),
- prototype(character(0), id=NULL, call=function () { stop () }, fuzzy_output=FALSE, expect_error=FALSE, libraries=character(0)),
- validity=function (object) {
- if (is.null (object at id)) return (FALSE)
- return (TRUE)
- }
- )
-
-setClass ("RKTestResult",
- representation (id = "character", code_match = "character", output_match = "character", message_match = "character", error="character", passed="logical"),
- prototype(character(0), id = character (0), code_match = character (0), output_match = character (0), message_match = character (0), error = character (0), passed=FALSE),
- validity=function (object) {
- return (all.equal (length (object at id), length (object at code_match), length (object at output_match), length (object at message_match), length (object at error), length (object at passed)))
- }
- )
-
-setMethod ("show", "RKTestResult", function (object) {
- stopifnot (inherits (object, "RKTestResult"))
-
- cat (format ("ID", width=30))
- cat (format ("code match", width=15))
- cat (format ("output match", width=15))
- cat (format ("message match", width=15))
- cat (format ("error", width=15))
- cat (format ("result", width=15))
- cat ("\n", rep ("-", 96), "\n", sep="")
-
- for (i in 1:length (object at id)) {
- cat (format (object at id[i], width=30))
- cat (format (object at code_match[i], width=15))
- cat (format (object at output_match[i], width=15))
- cat (format (object at message_match[i], width=15))
- cat (format (object at error[i], width=15))
- cat (format (if (is.na (object at passed[i])) "--skipped--" else if (object at passed[i]) "pass" else "FAIL", width=15))
- cat ("\n")
- }
-
- cat (rep ("-", 96), "\n", sep="")
- cat (as.character (sum (object at passed, na.rm=TRUE)), " / ", as.character (sum (!is.na (object at passed))), " tests passed\n")
- if (sum (is.na (object at passed)) > 0) cat ("(", as.character (sum (is.na (object at passed))), " / ", as.character (length (object at passed)), " tests skipped due to missing libraries)", sep="");
-})
-
-rktest.appendTestResults <- function (objecta, objectb) {
- stopifnot (inherits (objecta, "RKTestResult") && validObject (objecta))
- stopifnot (inherits (objectb, "RKTestResult") && validObject (objectb))
-
- index <- length (objecta at id)
- for (i in 1:length (objectb at id)) {
- objecta at id[index+i] = objectb at id[i]
- objecta at code_match[index+i] = objectb at code_match[i]
- objecta at output_match[index+i] = objectb at output_match[i]
- objecta at message_match[index+i] = objectb at message_match[i]
- objecta at error[index+i] = objectb at error[i]
- objecta at passed[index+i] = objectb at passed[i]
- }
-
- objecta
-}
-
-rktest.file <- function (id, extension) {
- file.path(getwd(), paste (id, extension, sep=""))
-}
-
-# returns true, if file corresponds to standard.
-rktest.compare.against.standard <- function (file, fuzzy=FALSE) {
- standard_file <- gsub ("^(.*\\/)([^\\/]*)$", "\\1RKTestStandard\\.\\2", file)
- if (file.exists (file)) {
- # purge empty files
- info <- file.info (file)
- if (info$size[1] == 0) file.remove (file)
- }
- if (!file.exists (file)) {
- # if neither exists, that means both files are empty
- if (!file.exists (standard_file)) return ("match (empty)")
- }
-
- output.diff <- suppressWarnings (system(paste("diff", shQuote(file), shQuote(standard_file), "--strip-trailing-cr", "--new-file"), intern=TRUE))
- if (!length (output.diff)) return ("match")
- if ((length (output.diff) == 1) && (!nzchar (output.diff))) return ("match")
-
- # below: there are *some* differences
- if (fuzzy) {
- size <- if (file.exists (file)) file.info (file)$size[1] else 0
- s_size <- if (file.exists (standard_file)) file.info (standard_file)$size[1] else 0
-
- # crude test: files should at least have a similar size
- if ((size < (s_size + 20)) && (size > (s_size - 20))) return ("fuzzy match")
- }
-
- print (paste ("Differences between", file, "and", standard_file, ":"))
- print (output.diff)
-
@@ Diff output truncated at 100000 characters. @@
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