hmm {VanillaICE} | R Documentation

## Fits the hidden Markov model

### Description

Fits the hidden Markov model

### Usage

    hmm(object, params)

### Arguments

`object` | An object of class `HmmOptions`
`params` | An object of class `HmmParameter`

### Details

None yet.

### Value

An object of class `HmmPredict`

### Author(s)

R. Scharpf

### References

RB Scharpf et al. (2008) Hidden Markov Models for the assessment of chromosomal alterations using high-throughput SNP arrays, Annals of Applied Statistics

### See Also

`HmmParameter-class` `HmmPredict-class` `SnpLevelSet-class`

### Examples

    data(chromosome1)
    chromosome1 <- chromosome1[1:500, ]
    options <- new("HmmOptions",
                   states=c("D", "N", "L", "A"),
                   snpset=chromosome1,
                   copyNumber.location=c(1, 2, 2, 3),
                   probHomCall=c(0.99, 0.7, 0.99, 0.7))
    validObject(options)
    params <- new("HmmParameter",
                  states=states(options),
                  initialStateProbability=0.99)
    cn.emission <- copyNumber.emission(options)
    gt.emission <- calls.emission(options)
    emission(params) <- cn.emission + gt.emission ##log scale
    genomicDistance(params) <- exp(-2 *calculateDistance(options)/(100*1e6))
    ##no scaling
    transitionScale(params) <- matrix(1, length(states(options)), length(states(options)))
    if(validObject(params)) fit <- hmm(options, params)

[Package VanillaICE version 1.4.0 Index]