adjPlot {NMTox} | R Documentation |
Plot the adjusted p-values, raw p-values and FDR level
Description
This function generates plots of adjusted p-values, raw p-values and selected FDR level
Usage
adjPlot(data.nm, data.control, id, nano, response, dose, end, end.cat,
unit, unit.cat, stat=c("E2","Williams","Marcus","M","ModM"), niter,
method=c("BH","BY"), control.opt=c("same","all"), set.seed, vars, FDR)
Arguments
data.nm |
Data containing the result of toxicity study |
data.control |
Data of control values |
id |
Identifier of the experiment |
nano |
Name of the nanomaterial |
response |
Response (endpoint value) |
dose |
Dose or concentration |
end |
Toxicity endpoint |
end.cat |
Specific toxicity endpoint of interest |
unit |
Unit of measurement of the dose |
unit.cat |
Specific unit of measurement of the dose |
stat |
Test statistics (" |
niter |
Number of permutations |
method |
Method used to adjust for the multiplicity |
control.opt |
Option for the control doses if |
set.seed |
Specify seed |
vars |
Variable(s) used to subset the data |
FDR |
The desired FDR to control |
Details
This function calculates the p-values for each nanomaterial in the dataset (or for each subset of data). The different types of nanomaterials are identified by their names. Therefore, if some control values are named differently (see:
geninvitro
dataset and theExamples
), a separate dataset containing only these values first needs to be created. Controls in the new dataset can be linked to the non-control observations belonging to the same experiment through the identifier of the experiment (the linking is performed inside this function). In this situation, it is necessary to have an indicator that can identify different experiments (such as experiment ID).If all controls in the dataset are named according to the related nanomaterial names,
data.control
andid
do not need to be specified.If doses used in the experiment are all measured in the same unit of measurement, then specify "
same
" incontrol.opt
.Plots can also be generated for subsets of data in each nanomaterial, by specifying the variables used to split the data in
vars
.
Value
This function generates plots of adjusted p-values, raw p-values and selected FDR for both directions (up and down) of the trend
References
Lin D., Pramana, S., Verbeke, T., and Shkedy, Z. (2015). IsoGene: Order-Restricted Inference for Microarray Experiments. R package version 1.0-24. https://CRAN.R-project.org/package=IsoGene
Lin D., Shkedy Z., Yekutieli D., Amaratunga D., and Bijnens, L. (editors). (2012) Modeling Doseresponse Microarray Data in Early Drug Development Experiments Using R. Springer.
Examples
# Create a dataset containing controls (which are named differently)
# from geninvitro dataset:
controldata<-SubsetData(data=geninvitro, x="name", x.cat=c("control", "Control",
"medium", "medium + BSA", "untreated"))
# Exclude controls (which are named differently) from geninvitro dataset:
invitrodata<-SubsetData(data=geninvitro, x="name", x.cat=c("control", "Control",
"medium", "medium + BSA", "untreated"), include=FALSE)
#
adjPlot(data.nm=invitrodata, data.control=controldata, id="experimentID",
nano="name", response="value", dose="concentration", end="endpoint",
end.cat="DNA STRAND BREAKS", unit="concentration_unit", unit.cat="ug/cm2",
stat="E2", niter=1000, method="BH", control.opt="same",
set.seed = 1234, FDR=0.05)