genogam {GenoGAM} | R Documentation

## genogam

### Description

The main modelling function.

### Usage

    genogam(ggd, lambda = NULL, theta = NULL, family = "nb", eps = 0,
      kfolds = 10, intervalSize = 20, regions = 20, order = 2, m = 2)

### Arguments

`ggd` | The GenoGAMDataSet object to be fitted
`lambda` | The penalization parameter. If NULL (default) estimated by cross validation. So far only one parameter for all splines is supported.
`theta` | The global overdispersion parameter. If NULL (default) estimated by cross validation.
`family` | The distribution to be used. So far only Negative-Binomial (nb) is supported.
`eps` | The factor for additional first-order regularization. This should be zero (default) in most cases. It can be useful for sparse data with many zero-counts regions or very low coverage. In this cases it is advised to use a small factor like 0.01, which would penalize those regions but not the ones with higher coverage. See Wood S., Generalized Additive Models (2006) for more.
`kfolds` | The number of folds for cross validation
`intervalSize` | The size of the hold-out intervals in cross validation. If replicates are present, this can easily be increased to twice the fragment size to capture more of the local correlation. If no replicates are present, keep the number low to avoid heavy interpolation (default).
`regions` | How many regions should be used in cross validation? The number is an upper limit. It is usually corrected down, such that the total number of models computed during cross validation does not exceed the total number of models to compute for the entire genome. This is usually the case for small organisms such as yeast.
`order` | The order of the B-spline basis, which is order + 2, where 0 is the lowest order. Thus order = 2 is equivalent to cubic order (= 3).
`m` | The order of penalization. Thus m = 2 penalizes the second differences.

### Value

The fit as a GenoGAM object

### Author(s)

Georg Stricker georg.stricker@in.tum.de

### Examples

    ggd <- makeTestGenoGAMDataSet(sim = TRUE)
    res <- genogam(ggd, lambda = 266.8368, theta = 2.415738)

[Package GenoGAM version 2.2.0 Index]