View source: R/02_exported_functions.R
llrTest | R Documentation |
Two outputs of alignReplicates can be tested as nested hypothesis. This can be used to test if e.g. buffer material influence can be neglected or a specific measurement point is an outlier.
llrTest(H0, H1, check = TRUE)
H0 |
output of alignReplicates obeying the null hypothesis. A special
case of |
H1 |
output of alignReplicates, the general case |
list with the log-likelihood ratio, statistical information and the numerical p-value calculated by the evaluating the chi-squared distribution at the present log-likelihood ratio with the current degrees of freedom.
## load provided example data file
lrrDataPath <- system.file(
"extdata", "exampleLlrTest.csv",
package = "blotIt"
)
## import data
llrData <- readWide(
file = lrrDataPath,
description = seq(1, 4),
sep = ",",
dec = "."
)
## generate H0: the buffer column is not named as a biological effect e.g.
## not considered as a biological different condition
H0 <- alignReplicates(
data = llrData,
model = "yi / sj",
errorModel = "value * sigmaR",
biological = yi ~ name + time + stimmulus,
scaling = sj ~ name + ID,
error = sigmaR ~ name + 1,
fitLogscale = FALSE,
normalize = TRUE,
averageTechRep = FALSE,
verbose = FALSE,
normalizeInput = TRUE
)
## generate H1: here the buffer column is named in the biological parameter
## therefore different entries are considered as biologically different
H1 <- alignReplicates(
data = llrData,
model = "yi / sj",
errorModel = "value * sigmaR",
biological = yi ~ name + time + stimmulus + buffer,
scaling = sj ~ name + ID,
error = sigmaR ~ name + 1,
fitLogscale = FALSE,
normalize = TRUE,
averageTechRep = FALSE,
verbose = FALSE,
normalizeInput = TRUE
)
## perform test
llrTest(H0, H1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.