Last data update: 2014.03.03

R: Creates a pathway data frame
create.pathway.dfR Documentation

Creates a pathway data frame

Description

Returns a data frame with L rows and M columns. L is the number of SNPs in the genotypes data frame and M is the number of tested pathways.

Usage

create.pathway.df(genotypes,snps.paths)

Arguments

genotypes

Genotype matrix, with L SNPs (columns) and N individuals (rows)

snps.paths

A list with entries the SNP members of each pathway. The size of the list is M

Value

A data frame with columns equal to the number of pathways in the pathway.snps list and rows equal to the number of tested SNPs

See Also

SNPs, genes, snps.to.pathways snps.to.genes

Examples

data(SNPs)
data(genes)
data(pathways)
data(genotypes)
snps.genes <- snps.to.genes(snp.info=SNPs,gene.info=genes, distance=0)
pathway.snps <- snps.to.pathways(pathways,snps.genes)
P <- create.pathway.df(genotypes=genotypes,snps.paths=pathway.snps)

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(PAGWAS)
Loading required package: lars
Loaded lars 1.2

Loading required package: foreach
Loading required package: mnormt
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/PAGWAS/create.pathway.df.Rd_%03d_medium.png", width=480, height=480)
> ### Name: create.pathway.df
> ### Title: Creates a pathway data frame
> ### Aliases: create.pathway.df
> 
> ### ** Examples
> 
> data(SNPs)
> data(genes)
> data(pathways)
> data(genotypes)
> snps.genes <- snps.to.genes(snp.info=SNPs,gene.info=genes, distance=0)
> pathway.snps <- snps.to.pathways(pathways,snps.genes)
> P <- create.pathway.df(genotypes=genotypes,snps.paths=pathway.snps)
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>