Last data update: 2014.03.03

R: Count probe GC content
countGCR Documentation

Count probe GC content

Description

Return the GC content for each probe

Usage

countGC(dat, type = "pm", idx)

Arguments

dat

a TilingFeatureSet object

type

pm or bg probes

idx

An optional vector of probe indices for which to return GC content. If not specified, values for all pm (or bg) probes will be returned.

Details

This function returns the sum of #G + #C in the pm or bg probes.

Value

a numeric vector

Author(s)

Martin Aryee <aryee@jhu.edu>

See Also

readCharm

Examples

	if (require(charmData)) {
		phenodataDir <- system.file("extdata", package="charmData")
		pd <- read.delim(file.path(phenodataDir, "phenodata.txt"))
		pd <- subset(pd, sampleID=="441_liver")
		dataDir <- system.file("data", package="charmData")
		setwd(dataDir)
		rawData <- readCharm(files=pd$filename, sampleKey=pd)
		ngc <- countGC(rawData)
		head(ngc)
	}

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(charm)
Loading required package: Biobase
Loading required package: BiocGenerics
Loading required package: parallel

Attaching package: 'BiocGenerics'

The following objects are masked from 'package:parallel':

    clusterApply, clusterApplyLB, clusterCall, clusterEvalQ,
    clusterExport, clusterMap, parApply, parCapply, parLapply,
    parLapplyLB, parRapply, parSapply, parSapplyLB

The following objects are masked from 'package:stats':

    IQR, mad, xtabs

The following objects are masked from 'package:base':

    Filter, Find, Map, Position, Reduce, anyDuplicated, append,
    as.data.frame, cbind, colnames, do.call, duplicated, eval, evalq,
    get, grep, grepl, intersect, is.unsorted, lapply, lengths, mapply,
    match, mget, order, paste, pmax, pmax.int, pmin, pmin.int, rank,
    rbind, rownames, sapply, setdiff, sort, table, tapply, union,
    unique, unsplit

Welcome to Bioconductor

    Vignettes contain introductory material; view with
    'browseVignettes()'. To cite Bioconductor, see
    'citation("Biobase")', and for packages 'citation("pkgname")'.

Loading required package: SQN
Loading required package: mclust
Package 'mclust' version 5.2
Type 'citation("mclust")' for citing this R package in publications.
Loading required package: nor1mix
Loading required package: fields
Loading required package: spam
Loading required package: grid
Spam version 1.3-0 (2015-10-24) is loaded.
Type 'help( Spam)' or 'demo( spam)' for a short introduction 
and overview of this package.
Help for individual functions is also obtained by adding the
suffix '.spam' to the function name, e.g. 'help( chol.spam)'.

Attaching package: 'spam'

The following objects are masked from 'package:base':

    backsolve, forwardsolve

Loading required package: maps

 # maps v3.1: updated 'world': all lakes moved to separate new #
 # 'lakes' database. Type '?world' or 'news(package="maps")'.  #



Attaching package: 'maps'

The following object is masked from 'package:mclust':

    map

Loading required package: RColorBrewer
Loading required package: genefilter
Welcome to charm version 2.18.0
> png(filename="/home/ddbj/snapshot/RGM3/R_BC/result/charm/countGC.Rd_%03d_medium.png", width=480, height=480)
> ### Name: countGC
> ### Title: Count probe GC content
> ### Aliases: countGC
> 
> ### ** Examples
> 
> 	if (require(charmData)) {
+ 		phenodataDir <- system.file("extdata", package="charmData")
+ 		pd <- read.delim(file.path(phenodataDir, "phenodata.txt"))
+ 		pd <- subset(pd, sampleID=="441_liver")
+ 		dataDir <- system.file("data", package="charmData")
+ 		setwd(dataDir)
+ 		rawData <- readCharm(files=pd$filename, sampleKey=pd)
+ 		ngc <- countGC(rawData)
+ 		head(ngc)
+ 	}
Loading required package: charmData
Loading required package: pd.charm.hg18.example
Loading required package: RSQLite
Loading required package: DBI
Loading required package: oligoClasses
Welcome to oligoClasses version 1.34.0
Loading required package: oligo
Loading required package: Biostrings
Loading required package: S4Vectors
Loading required package: stats4

Attaching package: 'stats4'

The following object is masked from 'package:spam':

    mle


Attaching package: 'S4Vectors'

The following objects are masked from 'package:spam':

    colMeans, colSums, rowMeans, rowSums

The following objects are masked from 'package:base':

    colMeans, colSums, expand.grid, rowMeans, rowSums

Loading required package: IRanges
Loading required package: XVector
================================================================================
Welcome to oligo version 1.36.1
================================================================================
The following columns in sampleKey contain discrepant values between channels and are being removed: 1
Platform design info loaded.
Checking designs for each XYS file... Done.
Allocating memory... Done.
Reading ./136421_532.xys.
Checking designs for each XYS file... Done.
Allocating memory... Done.
Reading ./136421_635.xys.
[1] 23 33 37 37 34 25
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>