R package maftools 源码解读

最后发布时间:2021-07-14 10:03:57 浏览量:

maftools

  • An R package to summarize, analyze and visualize MAF files

S4 Object

MAF object

### vim R/mafObjects.R +16
setClass(Class = 'MAF', slots =  c(data = 'data.table', variants.per.sample = 'data.table', variant.type.summary = 'data.table',
                                         variant.classification.summary = 'data.table', gene.summary = 'data.table',
                                         summary = 'data.table', maf.silent = 'data.table', clinical.data = 'data.table'))

methods

getGeneSummary(maf)

### vim  R/maf_methods.R +67
setGeneric(name = "getGeneSummary", function(x) standardGeneric("getGeneSummary"))
setMethod(f = "getGeneSummary",signature = "MAF", function(x) x@gene.summary)

summarizeMaf function

vim R/summarizeMaf.R
return(list(variants.per.sample = tsb, variant.type.summary = vt.cast, variant.classification.summary = vc.cast,
              gene.summary = hs.cast, summary = summary, sample.anno = sample.anno))