Last data update: 2014.03.03
R: Method "TFDataset"
Method "TFDataset"
Description
Removes of all non-concurrent batches from the dataset.
Returns dataset suitable for TF framework or original dataset if data removal was not successful.
Usage
TFDataset(phenList, depVariable, outputMessages=TRUE, forDecisionTree = FALSE)
Arguments
phenList
instance of the PhenList
class; mandatory argument
depVariable
a character string defining the dependent variable of interest; mandatory argument
outputMessages
flag: "FALSE" value to suppress output messages; "TRUE" value to show output messages;
default value TRUE
forDecisionTree
flag: "FALSE" value for normal procedure;
"TRUE" value to indicate that is called form decisionTree function; default value FALSE
Value
Returns dataset suitable for TF framework or original dataset if data removal was not successful.
Author(s)
Natalja Kurbatova, Natasha Karp, Jeremy Mason
References
Karp N, Melvin D, Sanger Mouse Genetics Project, Mott R (2012): Robust and Sensitive Analysis of Mouse Knockout Phenotypes. PLoS ONE 7 (12): e52410. doi:10.1371/journal.pone.0052410
West B, Welch K, Galecki A (2007): Linear Mixed Models: A practical guide using statistical software New York: Chapman & Hall/CRC 353 p.
See Also
PhenList
Examples
file <- system.file("extdata", "test1.csv", package="PhenStat")
test <- PhenList(dataset=read.csv(file),
testGenotype="Sparc/Sparc")
test2 <- TFDataset(test,"Lean.Mass")
Results
R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
> library(PhenStat)
> png(filename="/home/ddbj/snapshot/RGM3/R_BC/result/PhenStat/TFDataset.Rd_%03d_medium.png", width=480, height=480)
> ### Name: TFDataset
> ### Title: Method "TFDataset"
> ### Aliases: TFDataset
>
> ### ** Examples
>
> file <- system.file("extdata", "test1.csv", package="PhenStat")
> test <- PhenList(dataset=read.csv(file),
+ testGenotype="Sparc/Sparc")
Warning:
Dataset's column 'Assay.Date' has been renamed to 'Batch' and will be used for the batch effect modelling.
Information:
Dataset's 'Genotype' column has following values: '+/+', 'Sparc/Sparc'
Information:
Dataset's 'Sex' column has following value(s): 'Female', 'Male'
> test2 <- TFDataset(test,"Lean.Mass")
Data points containing 'Lean.Mass' by batch levels:
| ----------- | ----------- | ----------- | ----------- | ----------- |
| | +/+ | +/+ | Sparc/Sparc | Sparc/Sparc |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| Batch | Female | Male | Female | Male |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 01-Jun-09 | 1 | 2 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 01-Mar-10 | 0 | 0 | 0 | 3 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 02-Jun-09 | 0 | 2 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 02-Sep-09 | 8 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 03-Jun-09 | 4 | 4 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 04-Jun-09 | 4 | 0 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 04-Nov-09 | 8 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 05-May-09 | 1 | 4 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 06-Jan-10 | 0 | 0 | 0 | 3 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 06-Jul-09 | 4 | 4 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| 07-Aug-09 | 8 | 8 | 4 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 07-Jul-09 | 4 | 4 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 07-May-09 | 2 | 2 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 07-Oct-09 | 7 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 08-Jun-09 | 2 | 0 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 08-May-09 | 4 | 4 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 08-Sep-09 | 8 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 10-Jun-09 | 5 | 2 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 10-Nov-09 | 8 | 7 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 11-Jun-09 | 1 | 6 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 12-Aug-09 | 7 | 7 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 14-Jul-09 | 8 | 7 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 14-May-09 | 4 | 2 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 15-Jun-09 | 1 | 0 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 15-May-09 | 1 | 5 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 15-Oct-09 | 8 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 16-Jun-09 | 0 | 2 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 16-Sep-09 | 8 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 17-Jun-09 | 8 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 17-Nov-09 | 8 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 18-Aug-09 | 6 | 7 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 18-May-09 | 3 | 0 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 19-Oct-09 | 8 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 20-May-09 | 4 | 4 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 21-May-09 | 6 | 0 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 22-Jul-09 | 8 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 22-May-09 | 1 | 0 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 22-Sep-09 | 8 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 23-Jun-09 | 0 | 0 | 0 | 2 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 23-Nov-09 | 0 | 0 | 3 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 25-Jun-09 | 8 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 26-May-09 | 4 | 4 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 26-Oct-09 | 8 | 4 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 27-Aug-09 | 4 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 27-May-09 | 0 | 1 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 28-May-09 | 4 | 2 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 28-Sep-09 | 8 | 7 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 29-Jul-09 | 8 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
| * 29-Jun-09 | 7 | 8 | 0 | 0 |
| ----------- | ----------- | ----------- | ----------- | ----------- |
* - removed record(s)
Number of batch levels left: 1
Records removed (reference genotype): 93%
Records removed (test genotype): 2%
Error:
There are not enough records for TF method after the removal of all non-concurrent batches.
>
>
>
>
>
> dev.off()
null device
1
>