]> git.donarmstrong.com Git - rsem.git/blob - EBSeq/man/GeneMultiSimu.Rd
Included EBSeq for downstream differential expression analysis
[rsem.git] / EBSeq / man / GeneMultiSimu.Rd
1 \name{GeneMultiSimu}
2 \alias{GeneMultiSimu}
3 %- Also NEED an '\alias' for EACH other topic documented here.
4 \title{
5 Gene Level Simulation for multiple conditions
6 }
7 \description{
8 Simulate Gene level expression data from a Negative Binomial assumption. (Without outliers)
9 }
10 \usage{
11 GeneMultiSimu(DVDconstant = NULL, DVDqt1 = NULL, DVDqt2 = NULL, Conditions,AllParti, NumofSample, NumofGene = NULL, DEGeneProp, Phiconstant = NULL, Phi.qt1 = NULL, Phi.qt2 = NULL, Meanconstant = NULL,  NormFactor=NULL, OnlyData = T)
12 }
13 %- maybe also 'usage' for other objects documented here.
14 \arguments{
15   \item{DVDconstant}{
16 Whether want to use constant fold change value for all the DE genes. 
17 If set DVDconstant=4, all the DE genes will have fold change of 4 across two condtions. 
18 If this parameter is specified, the settings of DVDqt1 and DVDqt2 will be ignored. 
19 }
20   \item{DVDqt1, DVDqt2}{
21 If DVDconstant is not specified, the user could use a range of empirical DVD's f
22 rom Gould' data. The lower and upper bound ( quantile) could be specified.
23 The suggested value is c(.96, .97). DVD for each gene will be randomly choosed within the range.
24
25 }
26   \item{Conditions}{
27 A vector of charecters to show each sample's condition. 
28 (Only the two-condition case is supported now)
29 }
30 \item{AllParti}{
31             A matrix indicates the interested patterns. Columns shoule be conditions and rows should be patterns.
32                     The matrix could be obtained by the GetPatterns function. If AllParti=NULL, all possible patterns will be used.
33 }
34
35   \item{NumofSample}{
36 Number of samples to generte.
37 }
38   \item{NumofGene}{
39 Number of genes to generate.
40 }
41   \item{DEGeneProp}{
42 The proportion of genes to be generated as DE. The value should be in [0, 1].
43 Besides, the same proportion of genes will be generated as EE genes with outlier. 
44 The genes will be generated as EE at first, then the count of one of the samples 
45 (randomly selected) will be setted as its original counts multiplied by one of (4, 6, 8, 10).
46 }
47   \item{Phiconstant}{
48 Whether set the disperse parameter phi to be a constant. If this parameter is specified, the settings of Phi.qt1 and Phi.qt2 will be ignored.
49 }
50   \item{Phi.qt1, Phi.qt2}{
51 If Phiconstant is not specified, the user could use a range of empirical phi's from Gould' data. The lower and upper bound ( quantile) could be specified.
52 The suggested value is c(.25, .75). phi for each gene will be randomly choosed w
53 ithin the range.
54
55 }
56   \item{Meanconstant}{
57 Wether set the mean of each gene to be a constant.
58 }
59   \item{OnlyData}{
60 Wether the user only want the generated data matrix. If OnlyData=T, the function will return the simulated matrix
61 and the name of the DE genes.
62 Otherwise the funtion will run DESeq, EBSeq, edgeR, baySeq and BBSeq and provide the results of each method. 
63 }
64
65 \item{NormFactor}{
66 If NormFactor is NULL, each lane will be set to be with the same library size. Otherwise NormFactor should be a 
67 vector with length NumofSample. 
68 }
69
70 }
71 \details{
72 For each gene, we assumed that the expression follows a Negative Binomial distribution with mean mu_g and variance mu_g * (1 + mu_g * phi_g). 
73 For DE genes, we assumed that in one condition the genes are with mean mu_g * DVD.
74 mu, phi and DVD could be specified by the parameter settings.
75 }
76 \value{
77 \item{data}{
78 A matrix of expression values will be generated. The rows of the matrix refer to the genes and the columns of the matrix are the samples. The genes are named "G_1", "G_2", ... The first part of the genes will be the DE ones. (The number depends on the DEGeneProp parameter.)
79 }
80 \item{Patterns}{The pattern each gene belongs to}
81
82 }
83
84 \references{
85 %% ~put references to the literature/web site here ~
86 }
87 \author{
88 Ning Leng
89 }
90 \note{
91 %%  ~~further notes~~
92 }
93
94 %% ~Make other sections like Warning with \section{Warning }{....} ~
95
96 \seealso{
97 IsoSimu, IsoSimuAt, GeneSimuAt
98 }
99 \examples{
100 Conditions=c("C1","C1","C2","C2","C3","C3")
101 PosParti=GetPatterns(Conditions)
102 AllParti=PosParti[-3,]
103
104 MultiData=GeneMultiSimu(Conditions=Conditions,AllParti=AllParti,
105                                                                         NumofSample=6,NumofGene=1000,DEGeneProp=c(.7,.1,.1,.1),
106                                                                                                                         DVDqt1=.98,DVDqt2=.99,Phi.qt1=.25,Phi.qt2=.75)
107
108 }
109 % Add one or more standard keywords, see file 'KEYWORDS' in the
110 % R documentation directory.
111 \keyword{ simulation }
112 \keyword{ ~kwd2 }% __ONLY ONE__ keyword per line