[rkward-cvs] SF.net SVN: rkward:[3169] trunk/rkward
m-eik at users.sourceforge.net
m-eik at users.sourceforge.net
Mon Nov 1 16:34:29 UTC 2010
Revision: 3169
http://rkward.svn.sourceforge.net/rkward/?rev=3169&view=rev
Author: m-eik
Date: 2010-11-01 16:34:29 +0000 (Mon, 01 Nov 2010)
Log Message:
-----------
rkwardtests: re-worked yesterday's fixes
Modified Paths:
--------------
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/RKTest-class.R
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.makeplugintests.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-class.Rd
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.runRKTestSuite.Rd
trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.setSuiteStandards.Rd
trunk/rkward/tests/analysis_plugins.R
trunk/rkward/tests/distributions.R
trunk/rkward/tests/import_export_plugins/RKTestStandard.import_spss.rkcommands.R
trunk/rkward/tests/import_export_plugins/RKTestStandard.import_stata.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
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/RKTest-class.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/RKTest-class.R 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/RKTest-class.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -6,6 +6,7 @@
#' @slot fuzzy_output Allow fuzzy results
#' @slot expect_error Expect errors
#' @slot libraries A charcter vector naming needed libraries
+#' @slot files A character vector naming needed files, path relative to the test standards directory
#' @name RKTest
#' @import methods
#' @keywords classes
@@ -14,8 +15,8 @@
#' @rdname RKTest-class
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)),
+ representation (id="character", call="function", fuzzy_output="logical", expect_error="logical", libraries="character", files="character"),
+ prototype(character(0), id=NULL, call=function () { stop () }, fuzzy_output=FALSE, expect_error=FALSE, libraries=character(0), files=character(0)),
validity=function (object) {
if (is.null (object at id)) return (FALSE)
return (TRUE)
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.makeplugintests.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.makeplugintests.R 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.makeplugintests.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -44,8 +44,8 @@
allresults <- new ("RKTestResult")
for (testsuite in testsuites) {
- source (testsuite)
- results <- rktest.runRKTestSuite (suite=suite, basedir=getwd(), test.id=test.id)
+ tryCatch(source(testsuite, local=TRUE), error=function(e) e)
+ results <- rktest.runRKTestSuite (suite=suite, testroot=testroot, test.id=test.id)
allresults <- rktest.appendTestResults (allresults, results)
}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.runRKTestSuite.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.runRKTestSuite.R 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.runRKTestSuite.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -3,10 +3,10 @@
#' This function can be called to run a single plugin test suite.
#'
#' @title Run RKWard plugin test suite
-#' @usage rktest.runRKTestSuite(suite, basedir=getwd(), test.id=NULL)
+#' @usage rktest.runRKTestSuite(suite, testroot=getwd(), test.id=NULL)
#' @aliases rktest.runRKTestSuite
#' @param suite Character string naming the test suite to run.
-#' @param basedir Defaults to the working directory.
+#' @param testroot 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}}.
#' @author Thomas Friedrichsmeier \email{thomas.friedrichsmeier@@ruhr-uni-bochum.de}, Meik Michalke \email{meik.michalke@@uni-duesseldorf.de}
@@ -18,7 +18,7 @@
#' result <- rktest.runRKTestSuite()
#' }
-rktest.runRKTestSuite <- function (suite, basedir=getwd (), test.id=NULL) {
+rktest.runRKTestSuite <- function (suite, testroot=getwd (), test.id=NULL) {
# check wheter test environment is already set,
# otherwise initialize
if(!exists("initialized", where=rkwardtests::.rktest.tmp.storage) || !get("initialized", pos=rkwardtests::.rktest.tmp.storage)){
@@ -32,11 +32,12 @@
if (!validObject (suite)) return (result)
# clean any old results
- rktest.cleanRKTestSuite (suite, basedir)
+ rktest.cleanRKTestSuite (suite)
oldwd = getwd ()
on.exit (setwd (oldwd), add=TRUE)
- setwd (file.path(basedir, suite at id))
+# setwd (file.path(testroot, suite at id))
+ setwd (rktest.createTempSuiteDir(suite at id))
if (length (suite at initCalls) > 0) {
for (i in 1:length (suite at initCalls)) try (suite at initCalls[[i]]())
@@ -49,7 +50,7 @@
for (i in 1:length (suite at tests)) {
suite at tests[[i]]@libraries <- c(suite at libraries, suite at tests[[i]]@libraries)
- try (res <- rktest.runRKTest(suite at tests[[i]]))
+ try (res <- rktest.runRKTest(test=suite at tests[[i]], standard.path=file.path(testroot, suite at id), suite.id=suite at id))
result <- rktest.appendTestResults (result, res)
}
@@ -57,5 +58,5 @@
for (i in 1:length (suite at postCalls)) try (suite at postCalls[[i]]())
}
- result
+ return(result)
}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.setSuiteStandards.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.setSuiteStandards.R 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rktest.setSuiteStandards.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -4,10 +4,12 @@
#' output and R messages as the standard that will be compared to during following tests.
#'
#' @title Set RKWard suite standards
-#' @usage rktest.setSuiteStandards(suite, basedir=getwd())
+#' @usage rktest.setSuiteStandards(suite, testroot=getwd(), file=TRUE)
#' @aliases rktest.setSuiteStandards
#' @param suite Character string naming the test suite to set standards for.
-#' @param basedir Should point to the testroot, defaults to the working directory.
+#' @param testroot Path to the test root directory, defaults to the working directory.
+#' @param file Logical: If \code{suite} is already a present R object, set this to FALSE.
+#' Otherwise it is assumed to be a file and fed to \code{source}.
#' @return The function simply changes the names of the previously created files,
#' specifically adding the prefix "RKTestStandard.".
#' @author Thomas Friedrichsmeier \email{thomas.friedrichsmeier@@ruhr-uni-bochum.de}
@@ -19,7 +21,10 @@
#' rktest.setSuiteStandards("rkward_application_tests.R")
#' }
-rktest.setSuiteStandards <- function (suite, basedir=getwd ()) {
+rktest.setSuiteStandards <- function (suite, testroot=getwd (), file=TRUE) {
+ if(file){
+ tryCatch(source(suite, local=TRUE), error=function(e) e)
+ } else {}
if (!inherits (suite, "RKTestSuite")) return (result)
if (!validObject (suite)) return (result)
@@ -28,7 +33,7 @@
oldwd = getwd ()
on.exit (setwd (oldwd))
- setwd (file.path(basedir, suite at id))
+ setwd (file.path(testroot, suite at id))
temp.suite.dir <- rktest.createTempSuiteDir(suite at id)
files <- list.files (temp.suite.dir)
@@ -36,5 +41,5 @@
file.copy (file.path(temp.suite.dir, files), paste ("RKTestStandard.", files, sep=""), overwrite=TRUE)
# clean anything that is *not* a standard file
- rktest.cleanRKTestSuite (suite, basedir)
+ rktest.cleanRKTestSuite (suite)
}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rkwardtests-internal.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rkwardtests-internal.R 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/R/rkwardtests-internal.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -32,15 +32,15 @@
objecta
}
-rktest.file <- function (id, extension) {
+rktest.file <- function (id, extension, suite.id) {
# get or create a temporary directory
- temp.suite.dir <- rktest.createTempSuiteDir(suite at id)
+ temp.suite.dir <- rktest.createTempSuiteDir(suite.id)
file.path(temp.suite.dir, paste (id, extension, sep=""))
}
# returns true, if file corresponds to standard.
-rktest.compare.against.standard <- function (file, fuzzy=FALSE) {
- standard_file <- file.path(getwd(), gsub ("^(.*\\/)([^\\/]*)$", "RKTestStandard\\.\\2", file))
+rktest.compare.against.standard <- function (file, standard.path, fuzzy=FALSE) {
+ standard_file <- file.path(standard.path, gsub ("^(.*\\/)([^\\/]*)$", "RKTestStandard\\.\\2", file))
if (file.exists (file)) {
# purge empty files
info <- file.info (file)
@@ -104,7 +104,7 @@
return (failed)
}
-rktest.runRKTest <- function (test) {
+rktest.runRKTest <- function (test, standard.path, suite.id) {
result <- new ("RKTestResult") # FALSE by default
if (!inherits (test, "RKTest")) return (result)
@@ -126,10 +126,14 @@
return (result)
}
- output_file <- rktest.file (test at id, ".rkout")
- code_file <- rktest.file (test at id, ".rkcommands.R")
- message_file <- rktest.file (test at id, ".messages.txt")
+ for (testfile in test at files) {
+ file.copy(file.path(standard.path, testfile), getwd())
+ }
+ output_file <- rktest.file (test at id, ".rkout", suite.id)
+ code_file <- rktest.file (test at id, ".rkcommands.R", suite.id)
+ message_file <- rktest.file (test at id, ".messages.txt", suite.id)
+
# the essence of the test:
res.error <- rktest.runRKTest.internal (test, output_file, code_file, message_file)
passed <- (res.error == test at expect_error)
@@ -141,11 +145,11 @@
else result at error <- "no"
}
- result at output_match = rktest.compare.against.standard (output_file, test at fuzzy_output)
+ result at output_match = rktest.compare.against.standard (output_file, standard.path, test at fuzzy_output)
if (result at output_match == "MISMATCH") passed <- FALSE
- result at message_match = rktest.compare.against.standard (message_file)
+ result at message_match = rktest.compare.against.standard (message_file, standard.path)
if (result at message_match == "MISMATCH") passed <- FALSE
- result at code_match = rktest.compare.against.standard (code_file)
+ result at code_match = rktest.compare.against.standard (code_file, standard.path)
if (result at code_match == "MISMATCH") passed <- FALSE
result at passed <- passed
@@ -153,9 +157,8 @@
result
}
-rktest.cleanRKTestSuite <- function (suite, basedir=getwd ()) {
+rktest.cleanRKTestSuite <- function (suite) {
# kept for backwards compatibility ;-)
- # basedir is superfluous, though
rktest.removeTempSuiteDir(suite at id)
}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/RKTest-class.Rd
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/RKTest-class.Rd 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/RKTest-class.Rd 2010-11-01 16:34:29 UTC (rev 3169)
@@ -6,5 +6,5 @@
\description{This class is used internally by \code{\link[rkwardtests:rktest.makeplugintests]{rktest.makeplugintests}}.}
\keyword{classes}
\author{Thomas Friedrichsmeier \email{thomas.friedrichsmeier at ruhr-uni-bochum.de}}
-\section{Slots}{\describe{\item{\code{id}:}{}\item{\code{call}:}{}\item{\code{fuzzy_output}:}{}\item{\code{expect_error}:}{}\item{\code{libraries}:}{}}}
+\section{Slots}{\describe{\item{\code{id}:}{}\item{\code{call}:}{}\item{\code{fuzzy_output}:}{}\item{\code{expect_error}:}{}\item{\code{libraries}:}{}\item{\code{files}:}{}}}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.runRKTestSuite.Rd
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.runRKTestSuite.Rd 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.runRKTestSuite.Rd 2010-11-01 16:34:29 UTC (rev 3169)
@@ -1,7 +1,7 @@
\name{rktest.runRKTestSuite}
\alias{rktest.runRKTestSuite}
\title{Run RKWard plugin test suite}
-\usage{rktest.runRKTestSuite(suite, basedir=getwd(), test.id=NULL)}
+\usage{rktest.runRKTestSuite(suite, testroot=getwd(), test.id=NULL)}
\description{Run a single RKWard plugin test suite}
\details{This function can be called to run a single plugin test suite.}
\alias{rktest.runRKTestSuite}
@@ -10,7 +10,7 @@
\keyword{utilities}
\seealso{\code{\link[rkwardtests:RKTestSuite]{RKTestSuite-class}}, \code{\link[rkwardtests:rktest.makeplugintests]{rktest.makeplugintests}}}
\arguments{\item{suite}{Character string naming the test suite to run.}
-\item{basedir}{Defaults to the working directory.}
+\item{testroot}{Defaults to the working directory.}
\item{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).}
}
\examples{\dontrun{
Modified: trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.setSuiteStandards.Rd
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.setSuiteStandards.Rd 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/rkward/rbackend/rpackages/rkwardtests/man/rktest.setSuiteStandards.Rd 2010-11-01 16:34:29 UTC (rev 3169)
@@ -1,7 +1,7 @@
\name{rktest.setSuiteStandards}
\alias{rktest.setSuiteStandards}
\title{Set RKWard suite standards}
-\usage{rktest.setSuiteStandards(suite, basedir=getwd())}
+\usage{rktest.setSuiteStandards(suite, testroot=getwd(), file=TRUE)}
\description{Set RKWard plugin test suite standards}
\details{Use this function after you plugin passed all tests to set the resulting code,
output and R messages as the standard that will be compared to during following tests.}
@@ -12,7 +12,9 @@
\keyword{utilities}
\seealso{\code{\link[rkwardtests:RKTestSuite]{RKTestSuite-class}}, \code{\link[rkwardtests:rktest.makeplugintests]{rktest.makeplugintests}}}
\arguments{\item{suite}{Character string naming the test suite to set standards for.}
-\item{basedir}{Should point to the testroot, defaults to the working directory.}
+\item{testroot}{Path to the test root directory, defaults to the working directory.}
+\item{file}{Logical: If \code{suite} is already a present R object, set this to FALSE.
+Otherwise it is assumed to be a file and fed to \code{source}.}
}
\examples{\dontrun{
rktest.setSuiteStandards("rkward_application_tests.R")
Modified: trunk/rkward/tests/analysis_plugins.R
===================================================================
--- trunk/rkward/tests/analysis_plugins.R 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/tests/analysis_plugins.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -35,11 +35,6 @@
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 () {
@@ -124,11 +119,6 @@
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 () {
@@ -143,10 +133,6 @@
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 21:49:24 UTC (rev 3168)
+++ trunk/rkward/tests/distributions.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -43,19 +43,9 @@
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 () {
@@ -69,11 +59,6 @@
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 () {
@@ -87,19 +72,9 @@
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 () {
@@ -109,19 +84,9 @@
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 () {
@@ -131,19 +96,9 @@
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 () {
@@ -153,19 +108,9 @@
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 () {
@@ -181,19 +126,9 @@
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 () {
@@ -203,19 +138,9 @@
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 () {
@@ -225,19 +150,9 @@
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 () {
@@ -247,19 +162,9 @@
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 () {
@@ -269,11 +174,6 @@
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 () {
@@ -283,19 +183,9 @@
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 () {
@@ -305,19 +195,9 @@
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 () {
@@ -327,19 +207,9 @@
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 () {
@@ -349,19 +219,9 @@
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 () {
@@ -371,19 +231,9 @@
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 () {
@@ -393,19 +243,9 @@
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 () {
@@ -415,19 +255,9 @@
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 () {
@@ -437,19 +267,9 @@
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.
Modified: trunk/rkward/tests/import_export_plugins/RKTestStandard.import_spss.rkcommands.R
===================================================================
--- trunk/rkward/tests/import_export_plugins/RKTestStandard.import_spss.rkcommands.R 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/tests/import_export_plugins/RKTestStandard.import_spss.rkcommands.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -2,7 +2,7 @@
## Prepare
require (foreign)
## Compute
-data <- read.spss ("../import_export_plugins_testfile.sav", to.data.frame=TRUE, max.value.labels=1)
+data <- read.spss ("import_export_plugins_testfile.sav", to.data.frame=TRUE, max.value.labels=1)
# set variable labels for use in RKWard
labels <- attr (data, "variable.labels");
@@ -17,8 +17,8 @@
.GlobalEnv$my.spss.data <- data # assign to globalenv()
## Print result
-rk.header("Import SPSS data", parameters=list("File", "../import_export_plugins_testfile.sav",
+rk.header("Import SPSS data", parameters=list("File", "import_export_plugins_testfile.sav",
"Import as", "my.spss.data"))
})
-.rk.rerun.plugin.link(plugin="rkward::import_spss", settings="convert_var_labels.state=1\ndata_frame.state=1\ndo_locale_conversion.state=0\ndoedit.state=0\nfile.selection=../import_export_plugins_testfile.sav\nlabels_limit.real=1.00\nsaveto.objectname=my.spss.data\nsaveto.parent=.GlobalEnv\ntrim_labels.state=0\nuse_labels.state=1", label="Run again")
+.rk.rerun.plugin.link(plugin="rkward::import_spss", settings="convert_var_labels.state=1\ndata_frame.state=1\ndo_locale_conversion.state=0\ndoedit.state=0\nfile.selection=import_export_plugins_testfile.sav\nlabels_limit.real=1.00\nsaveto.objectname=my.spss.data\nsaveto.parent=.GlobalEnv\ntrim_labels.state=0\nuse_labels.state=1", label="Run again")
.rk.make.hr()
Modified: trunk/rkward/tests/import_export_plugins/RKTestStandard.import_stata.rkcommands.R
===================================================================
--- trunk/rkward/tests/import_export_plugins/RKTestStandard.import_stata.rkcommands.R 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/tests/import_export_plugins/RKTestStandard.import_stata.rkcommands.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -2,7 +2,7 @@
## Prepare
require (foreign)
## Compute
-data <- read.dta ("../import_export_plugins_testfile.dta", convert.dates=TRUE, convert.factors=TRUE, missing.type=FALSE, convert.underscore=FALSE)
+data <- read.dta ("import_export_plugins_testfile.dta", convert.dates=TRUE, convert.factors=TRUE, missing.type=FALSE, convert.underscore=FALSE)
# set variable labels for use in RKWard
labels <- attr (data, "var.labels")
@@ -17,8 +17,8 @@
.GlobalEnv$my.stata.data <- data # assign to globalenv()
## Print result
-rk.header("Import Stata File", parameters=list("File", "../import_export_plugins_testfile.dta",
+rk.header("Import Stata File", parameters=list("File", "import_export_plugins_testfile.dta",
"Imported to", "my.stata.data"))
})
-.rk.rerun.plugin.link(plugin="rkward::import_stata", settings="convert_dates.state=1\nconvert_factors.state=1\nconvert_underscore.state=0\ndoedit.state=0\nfile.selection=../import_export_plugins_testfile.dta\nmissing_type.state=0\nsaveto.objectname=my.stata.data\nsaveto.parent=.GlobalEnv", label="Run again")
+.rk.rerun.plugin.link(plugin="rkward::import_stata", settings="convert_dates.state=1\nconvert_factors.state=1\nconvert_underscore.state=0\ndoedit.state=0\nfile.selection=import_export_plugins_testfile.dta\nmissing_type.state=0\nsaveto.objectname=my.stata.data\nsaveto.parent=.GlobalEnv", label="Run again")
.rk.make.hr()
Modified: trunk/rkward/tests/import_export_plugins.R
===================================================================
--- trunk/rkward/tests/import_export_plugins.R 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/tests/import_export_plugins.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -12,11 +12,6 @@
## 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")
@@ -24,11 +19,6 @@
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")
@@ -38,10 +28,6 @@
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")
@@ -58,7 +44,7 @@
stopifnot (oldwd == getwd ())
}),
new ("RKTest", id="import_spss", call=function () {
- rk.call.plugin ("rkward::import_spss", convert_var_labels.state="1", data_frame.state="1", do_locale_conversion.state="0", doedit.state="0", file.selection="../import_export_plugins_testfile.sav", labels_limit.real="1.00", saveto.objectname="my.spss.data", trim_labels.state="0", use_labels.state="1", submit.mode="submit")
+ rk.call.plugin ("rkward::import_spss", convert_var_labels.state="1", data_frame.state="1", do_locale_conversion.state="0", doedit.state="0", file.selection="import_export_plugins_testfile.sav", labels_limit.real="1.00", saveto.objectname="my.spss.data", trim_labels.state="0", use_labels.state="1", submit.mode="submit")
# In order to check, whether the import was correct
rk.print (my.spss.data)
@@ -66,20 +52,15 @@
# WARNING: TODO: We don't use the value labels of the third
# variable, yet.
- }, libraries=c("foreign")),
+ }, libraries=c("foreign"), files=c("../import_export_plugins_testfile.sav")),
new ("RKTest", id="import_stata", call=function () {
- rk.call.plugin ("rkward::import_stata", convert_dates.state="1", convert_factors.state="1", convert_underscore.state="0", doedit.state="0", file.selection="../import_export_plugins_testfile.dta", missing_type.state="0", saveto.objectname="my.stata.data", submit.mode="submit")
+ rk.call.plugin ("rkward::import_stata", convert_dates.state="1", convert_factors.state="1", convert_underscore.state="0", doedit.state="0", file.selection="import_export_plugins_testfile.dta", missing_type.state="0", saveto.objectname="my.stata.data", submit.mode="submit")
# In order to check, whether the import was correct
rk.print (my.stata.data)
for (var in my.stata.data) rk.print (rk.get.description(var))
- }, libraries=c("foreign")),
+ }, libraries=c("foreign"), files=c("../import_export_plugins_testfile.dta")),
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")
@@ -97,10 +78,6 @@
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")
@@ -114,10 +91,6 @@
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")
@@ -127,10 +100,6 @@
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")
@@ -142,10 +111,6 @@
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())
Modified: trunk/rkward/tests/item_response_theory.R
===================================================================
--- trunk/rkward/tests/item_response_theory.R 2010-10-31 21:49:24 UTC (rev 3168)
+++ trunk/rkward/tests/item_response_theory.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -107,11 +107,6 @@
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")
}),
@@ -119,63 +114,33 @@
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 21:49:24 UTC (rev 3168)
+++ trunk/rkward/tests/plots.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -18,111 +18,46 @@
## 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.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 21:49:24 UTC (rev 3168)
+++ trunk/rkward/tests/rkward_application_tests.R 2010-11-01 16:34:29 UTC (rev 3169)
@@ -40,11 +40,6 @@
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
old.options <- options()
options (rk.graphics.type="JPG",
@@ -66,16 +61,11 @@
#
# In R 2.11.0, str (x) produces an error "subecript out of bounds" (only if library (XML) is loaded!
# The main concern is that we should handle this object gracefully, i.e. do not crash while syncing it.
- load ("../rkward_application_tests_strange_object.RData")
+ load ("rkward_application_tests_strange_object.RData")
rk.sync.global ()
rk.sync (x)
- }, libraries=c ("XML")),
+ }, libraries=c ("XML"), files=c("../rkward_application_tests_strange_object.RData")),
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 ()))
@@ -88,11 +78,6 @@
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")) {
@@ -257,11 +242,6 @@
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()
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