]> git.donarmstrong.com Git - rsem.git/blob - EBSeq/man/PolyFitPlot.Rd
Included EBSeq for downstream differential expression analysis
[rsem.git] / EBSeq / man / PolyFitPlot.Rd
1 \name{PolyFitPlot}
2 \alias{PolyFitPlot}
3 %- Also NEED an '\alias' for EACH other topic documented here.
4 \title{
5 %%  ~~function to do ... ~~
6 Fit the mean-var relationship using polynomial regression
7 }
8 \description{
9 %%  ~~ A concise (1-5 lines) description of what the function does. ~~
10 }
11 \usage{
12 PolyFitPlot(X, Y, nterms, xname = "Estimated Mean", yname = "Estimated Var", pdfname = "", xlim =  c(-1,5), ylim = c(-1,7), ChangeXY = F, col = "red")
13 }
14 %- maybe also 'usage' for other objects documented here.
15 \arguments{
16   \item{X}{
17 The first group of values want to be fitted by the polynomial regression. ( e.g Mean of the data. )
18 }
19   \item{Y}{
20 The second group of values want to be fitted by the polynomial regression. ( e.g. variance of the data.) The length of Y should be the same as the length of X.
21 }
22   \item{nterms}{
23 How many polynomial terms want to be used.
24 }
25   \item{xname}{
26 Name of the x axis.
27 }
28   \item{yname}{
29 Name of the y axis.
30 }
31   \item{pdfname}{
32 Name of the plot.
33 }
34   \item{xlim}{
35 The x limits of the plot. 
36 }
37   \item{ylim}{
38 The y limits of the plot.
39
40 }
41   \item{ChangeXY}{
42 If ChangeXY is setted to be TRUE, X will be treated as the dependent variable and Y will be treated as the independent one. Default is FALSE.
43 }
44   \item{col}{
45 Color of the fitted line.
46 }
47 }
48 \details{
49 %%  ~~ If necessary, more details than the description above ~~
50 }
51 \value{
52         The PolyFitPlot function provides a smooth scatter plot of two variables and their best fitting line of polynomial regression.
53 %%  ~Describe the value returned
54 %%  If it is a LIST, use
55 %%  \item{comp1 }{Description of 'comp1'}
56 %%  \item{comp2 }{Description of 'comp2'}
57 %% ...
58 }
59 \references{
60 %% ~put references to the literature/web site here ~
61 }
62 \author{
63 Ning Leng
64 }
65 \note{
66 %%  ~~further notes~~
67 }
68
69 %% ~Make other sections like Warning with \section{Warning }{....} ~
70
71 \seealso{
72 %% ~~objects to See Also as \code{\link{help}}, ~~~
73 }
74 \examples{
75 GeneData=GeneSimu(DVDconstant=4, DVDqt1=NULL, DVDqt2=NULL, Conditions=rep(c(1,2),each=5), NumofSample=10, NumofGene=10000, DEGeneProp=.1, Phiconstant=NULL, Phi.qt1=.25, Phi.qt2=.75, Meanconstant=NULL, OnlyData="Y")
76
77 EBres=NBBetaEB.bias.uniqueP_PoolVarSpeedUp_MDFPoi(Data=GeneData,NgVector=rep(1,10^4), Vect5End=rep(1,10^4), Vect3End=rep(1,10^4), Conditions=as.factor(rep(c(1,2),each=5)), maxround=5)
78
79 poly=PolyFitPlot(X=EBres$MeanList[[1]], Y=EBres$PoolVar[[1]], nterms=5, xname = "mean", yname = "var", pdfname=NULL, xlim = c(0,4.5),ylim = c(-2,8), ChangeXY = F, col = "red")
80 }
81 % Add one or more standard keywords, see file 'KEYWORDS' in the
82 % R documentation directory.
83 \keyword{ ~kwd1 }
84 \keyword{ ~kwd2 }% __ONLY ONE__ keyword per line