Description Usage Arguments Details Value References See Also Examples

Function to estimate the copy number profile with a piecewise constant function using mBPCR. Eventually, it is possible to estimate the profile with a
smoothing curve, using either the Bayesian Regression Curve with *K_2* (BRC with *K_2*) or the Bayesian Regression Curve Averaging over k (BRCAk). It is also possible
to choose the estimator of the variance of the levels `rhoSquare`

(i.e. either *\hat{ρ}_1^2* or *\hat{ρ}^2*) and by default *\hat{ρ}_1^2* is used.

1 2 | ```
estProfileWithMBPCRforOligoSnpSet(sampleData, sampleToBeAnalyzed, chrToBeAnalyzed, maxProbeNumber, ifLogRatio=1,
rhoSquare=NULL, kMax=50, nu=NULL, sigmaSquare=NULL, typeEstRho=1, regr=NULL)
``` |

`sampleData` |
object of type oligoSnpSet. The following fields must not be empty: |

`sampleToBeAnalyzed` |
vector containing the number of the columns corresponding to the samples the user wants to analyze. |

`chrToBeAnalyzed` |
array containing the name of the chromosomes that the user wants to analyze. The possible values of the chromosomes are: the integers from 1 to 22, 'X' and 'Y'. |

`maxProbeNumber` |
maximum number of probes that a chromosome (or arm of a chromosome) can have to be analyzed. The procedure of profile estimation
needs the computation of an array of length |

`ifLogRatio` |
denotes whether the original log2 data were centered at zero (i.e. they were in log2ratio scale) or not. By default, they are considered as derived by log2ratio data ( |

`rhoSquare` |
variance of the segment levels. If |

`kMax` |
maximum number of segments |

`nu` |
mean of the segment levels. If |

`sigmaSquare` |
variance of the noise. If |

`typeEstRho` |
choice of the estimator of |

`regr` |
choice of the computation of the regression curve. If |

By default, the function estimates the copy number profile with mBPCR and estimating rhoSquare on the sample, using *\hat{ρ}_1^2*. It is
also possible to use *\hat{ρ}^2* as estimator of `rhoSquare`

, by setting `typeEstRho=0`

, or to directly set the value of the parameter.

The function gives also the possibility to estimate the profile with a Bayesian regression curve: if `regr="BRC"`

the Bayesian Regression Curve with *K_2* is computed (BRC with *K_2*), if `regr="BRCAk"`

the Bayesian
Regression Curve Averaging over k is computed (BRCAk).

A list containing:

`estPC` |
an oligoSnpSet equal to sampleData apart from the field |

`regrCurve` |
an oligoSnpSet equal to sampleData apart from the field |

The matrices `assayData(estPC)$copyNumber`

and `assayData(regrCurve)$copyNumber`

have the same dimension of `assayData(sampleData)$copyNumber`

, hence their elements,
corresponding to the not analyzed chromosomes and samples, are equal to `NA`

.

Rancoita, P. M. V., Hutter, M., Bertoni, F., Kwee, I. (2009).
Bayesian DNA copy number analysis. *BMC Bioinformatics* 10: 10.
http://www.idsia.ch/~paola/mBPCR

`estProfileWithMBPCR`

, `computeMBPCR`

1 2 3 4 5 6 7 8 9 10 11 | ```
###import an example of oligoSnpSet data
#data(oligoSetExample, package="oligoClasses")
##estimation of chromosome 2 in sample 1
#r <-estProfileWithMBPCRforOligoSnpSet(oligoSet, sampleToBeAnalyzed=1, chrToBeAnalyzed=2, maxProbeNumber=1000, ifLogRatio=0, rhoSquare=0.0889637)
##plot of the estimated chromosomes
#library(SNPchip)
#cc <- r$estPC
#cc1 <- cc[chromosome(cc) == "2",1]
#par(las=1)
#plot(position(cc1), copyNumber(cc1)/100, ylim=c(-0.23, 0.1), ylab="copy number", xaxt="n")
#plotIdiogram(2, build=genomeBuild(oligoSet), ylim=c(-0.225, -0.19), new=FALSE)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.