Last data update: 2014.03.03
R: Class "HaploCode"
HaploCode-class R Documentation
Class "HaploCode"
Description
The object stores the haplotype coding for each of the candidate brake-points. It is typically generated by calling the function codeHaplo
on a GenoDat
object.
Objects from the Class
Objects can be created by calls of codeHaplo(objectGenoDat, blockSize, minAllele, saveRes = TRUE, file = NULL, ROI)
Slots
haploCode
:Object of class "matrix"
Haplotype coding into decimal integers
blockSize
:Object of class "numeric"
block size of SNP used to identify the haplotype of each candidate brake-point.
minAllele
:Object of class "numeric"
minimum allele above which candidate brake-points are considered
Methods
initialize signature(.Object = "HaploCode")
: Internal, users should use codeHaplo
show signature(object = "HaploCode")
: shows HaploCode
Author(s)
Alejandro Caceres acaceres@creal.cat
See Also
codeHaplo
, GenoDat
Examples
data(gDat)
hapCode <-codeHaplo(gDat,blockSize=3,minAllele=0.3,saveRes=FALSE)
hapCode
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(inveRsion)
Loading required package: haplo.stats
Hola!
welcome to inevRsion package.
type: manual() for full manual
vignette("inveRsion") for a quick start
> png(filename="/home/ddbj/snapshot/RGM3/R_BC/result/inveRsion/HaploCode-class.Rd_%03d_medium.png", width=480, height=480)
> ### Name: HaploCode-class
> ### Title: Class "HaploCode"
> ### Aliases: HaploCode-class initialize,HaploCode-method
> ### show,HaploCode-method
> ### Keywords: classes
>
> ### ** Examples
>
> data(gDat)
> hapCode <-codeHaplo(gDat,blockSize=3,minAllele=0.3,saveRes=FALSE)
-Code haplotypes-
preparing data
Number of brakepoints: 3
...
-computation done-
> hapCode
-Showing object of class: HaploCode-
@haploCode: Binary code for haplotypes of brake-points flanked by SNP blocks
* numeric matrix ~ 18 chromosomes by 3 brake points
* first elements =
0.001393 0.001467 0.001467 0.001531 0.001531 0.001761
[1,] 1 0 0 1 0 1
[2,] 2 2 6 4 5 2
[3,] 1 2 0 0 0 0
[4,] 4 4 3 4 7 1
[5,] 1 2 2 4 5 1
[6,] 1 2 2 4 5 1
[7,] 1 2 0 0 0 0
[8,] 4 4 3 4 7 1
[9,] 0 2 0 0 0 0
[10,] 1 4 3 4 7 1
[11,] 0 0 0 0 0 0
[12,] 0 0 0 0 0 0
[13,] 0 0 0 0 0 0
[14,] 4 1 0 2 0 4
[15,] 1 2 2 4 5 1
[16,] 1 2 2 4 5 1
[17,] 0 0 0 0 0 0
[18,] 0 2 0 4 1 1
attr(,"locilim")
[,1] [,2]
[1,] 1 6
[2,] 2 7
[3,] 3 8
attr(,"phasing")
[1] inversion&BP
@blockSize: Block Size of 3 SNPs
@minAllele: Brake points with minimum allele frequency of 0.3
-end showing HaploCode-
>
>
>
>
>
> dev.off()
null device
1
>