JSONOutput: Method "JSONOutput"

Description Usage Arguments Value Author(s) See Also Examples

View source: R/JSONOutput.R

Description

Wrapper for the model fitting results. Returns model fitting and testing results in a JSON format. Assumes that modelling results are stored in the PhenTestResult object (output from function testDataset).

Usage

1
2
    JSONOutput(phenTestResult,
				phenotypeThreshold = 0.01)

Arguments

phenTestResult

instance of the PhenTestResult class that comes from the function testDataset; mandatory argument

phenotypeThreshold

a numerical value defining the threshold to use in classificationTag; default value 0.01

Value

Returns a vector with model fitting results in JSON format: model output summary and other values

Author(s)

Natalja Kurbatova

See Also

PhenTestResult

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
	## Not run:
    # Mixed Model framework
    file <- system.file("extdata", "test1.csv", package="PhenStat")
    test <- PhenStat:::PhenList(dataset=read.csv(file,na.strings = '-'),
            testGenotype="Sparc/Sparc")
    result <- PhenStat:::testDataset(test,
            depVariable="Lean.Mass")
    PhenStat:::JSONOutput(result)

    # Fishe Exact Test framework
    file <- system.file("extdata", "test_categorical.csv", package="PhenStat")
    test2 <- PhenStat:::PhenList(dataset=read.csv(file,na.strings = '-'),
            testGenotype="Aff3/Aff3")
    result2 <- PhenStat:::testDataset(test2,
            depVariable="Thoracic.Processes",
            method="FE")
    PhenStat:::JSONOutput(result2)
	## End(Not run)

PhenStat documentation built on Nov. 8, 2020, 8:13 p.m.