[Genabel-commits] r1584 - in pkg/MetABEL: . R man
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Mon Feb 3 16:38:28 CET 2014
Author: lckarssen
Date: 2014-02-03 16:38:27 +0100 (Mon, 03 Feb 2014)
New Revision: 1584
Modified:
pkg/MetABEL/DESCRIPTION
pkg/MetABEL/NAMESPACE
pkg/MetABEL/R/metagwa.files.R
pkg/MetABEL/R/metagwa.tables.R
pkg/MetABEL/man/metagwa.files.Rd
pkg/MetABEL/man/metagwa.tables.Rd
Log:
Use roxygen2 for documetation of the other two functions in MetABEL.
Also includes slightly updated NAMESPACE and DESCRIPTION file as generated by 'roxigenise()'.
Modified: pkg/MetABEL/DESCRIPTION
===================================================================
--- pkg/MetABEL/DESCRIPTION 2014-02-03 15:15:47 UTC (rev 1583)
+++ pkg/MetABEL/DESCRIPTION 2014-02-03 15:38:27 UTC (rev 1584)
@@ -1,12 +1,14 @@
-Package: MetABEL
-Type: Package
-Title: meta-analysis of genome-wide SNP association results
-Version: 0.1-0
-Date: 2013-01-26
-Author: Maksim Struchalin, Yurii Aulchenko
-Maintainer: L.C. Karssen <lennart at karssen.org>
-Depends: R (>= 2.5.1)
-Suggests: GenABEL
-Description: A package for meta-analysis of genome-wide association
- scans between quantitative or binary traits and SNPs
-License: GPL (>= 2)
+Package: MetABEL
+Type: Package
+Title: Meta-analysis of genome-wide SNP association results
+Version: 0.1-0
+Date: 2013-01-26
+Author: Maksim Struchalin, Yurii Aulchenko
+Maintainer: L.C. Karssen <lennart at karssen.org>
+Depends:
+ R (>= 2.5.1)
+Suggests:
+ GenABEL
+Description: A package for meta-analysis of genome-wide association
+ scans between quantitative or binary traits and SNPs
+License: GPL (>= 2)
Modified: pkg/MetABEL/NAMESPACE
===================================================================
--- pkg/MetABEL/NAMESPACE 2014-02-03 15:15:47 UTC (rev 1583)
+++ pkg/MetABEL/NAMESPACE 2014-02-03 15:38:27 UTC (rev 1584)
@@ -1,8 +1,3 @@
-#useDynLib(MetABEL)
-
-export(
- forestplot,
- metagwa.files,
- metagwa.tables
- )
-
+export(forestplot)
+export(metagwa.files)
+export(metagwa.tables)
Modified: pkg/MetABEL/R/metagwa.files.R
===================================================================
--- pkg/MetABEL/R/metagwa.files.R 2014-02-03 15:15:47 UTC (rev 1583)
+++ pkg/MetABEL/R/metagwa.files.R 2014-02-03 15:38:27 UTC (rev 1584)
@@ -1,3 +1,43 @@
+##' Meta-analysis of a series of results from GWA scans
+##'
+##' Performes meta-analysis of results of multiple GWA studies
+##' stored in files.
+##'
+##' The function looks for files named "POPSextens" in the directory
+##' "dir", reads them and pool consecutively using
+##' \code{\link{metagwa.tables}} function.
+##'
+##' The source files should contain a number of variables, such as allelic
+##' coding, code for the effective allele, etc. Please refer to the
+##' formetascore function of GenABEL package for details.
+##'
+##' When the file is not available for the first population, or there are
+##' non-unique population names, the function stops with an error message.
+##'
+##' If there are no files corresponding to next populations, these are
+##' skipped in analysis with a warning message (see details in the
+##' description of returned values).
+##'
+##' @param dir Path to directory containing files with GWA results
+##' @param pops A vector specifying study names, which make the first
+##' part of the file names
+##' @param extens Fixed extension to the file name
+##' @param maf Filter threshold for the absolute number/frequency of
+##' minor allele. If the parameter is < 1, this MAF threshold is used
+##' for filtering before meta-analysis; if this parameter is >1, n*MAF
+##' -- absolute number of the minor allele copies -- is used
+##' @param call Filter threshold for SNP call rate
+##' @param phwe Filter threshold for SNP P-value for HWE
+##' @param precorrect Should GC be applied to the original data before pooling
+##' @param correct.pooled Whether to apply Genomic Control correction to
+##' the study named "POOLED"
+##' @return Results are dumped to file named "POOLEDextens" in the directory
+##' "dir". Additionally, a list is returned with elements
+##' \item{analysed.pops}{list of populations successfully analysed}
+##' @author Yurii Aulchenko
+##' @seealso \code{\link{metagwa.tables}}
+##' @keywords htest
+##' @export
"metagwa.files" <-
function(dir=".", pops, extens, maf=5, call=0.95, phwe=1.e-8,
precorrect=TRUE, correct.pooled=FALSE) {
Modified: pkg/MetABEL/R/metagwa.tables.R
===================================================================
--- pkg/MetABEL/R/metagwa.tables.R 2014-02-03 15:15:47 UTC (rev 1583)
+++ pkg/MetABEL/R/metagwa.tables.R 2014-02-03 15:38:27 UTC (rev 1584)
@@ -1,3 +1,24 @@
+##' Pairwise meta-analysis of results from GWA scans
+##'
+##' Performes meta-analysis of results of two individual GWA studies
+##'
+##' Original data frames should contain a number of variables,
+##' such as allelic coding, code for the effective allele,
+##' etc. Please refer to the \code{formetascore} function of the
+##' \code{GenABEL} package for details.
+##' @param data.x First data frame with GWA data
+##' @param data.y Second data frame with GWA data
+##' @param name.x First study name
+##' @param name.y Second study name
+##' @param precorrect Should GC be applied to the original data before pooling
+##' @param correct.pooled Whether to apply Genomic Control correction to
+##' the study named "POOLED"
+##' @return A data frame containing summary statistics and essential details
+##' of the individual studies
+##' @author Yurii Aulchenko
+##' @seealso \code{\link{metagwa.files}}
+##' @keywords htest
+##' @export
"metagwa.tables" <-
function(data.x, data.y, name.x="P1", name.y="P2",
precorrect=TRUE, correct.pooled=FALSE) {
Modified: pkg/MetABEL/man/metagwa.files.Rd
===================================================================
--- pkg/MetABEL/man/metagwa.files.Rd 2014-02-03 15:15:47 UTC (rev 1583)
+++ pkg/MetABEL/man/metagwa.files.Rd 2014-02-03 15:38:27 UTC (rev 1584)
@@ -1,61 +1,68 @@
-\name{metagwa.files}
-\alias{metagwa.files}
-\title{Meta-analysis of seriens of results GWA scans}
-\description{
-Performes meta-analysis of results of multiple GWA studies
-stored in files.
-}
-
-\usage{
- metagwa.files(dir = ".", pops, extens, maf = 5, call = 0.95, phwe = 1e-08,
- precorrect=TRUE, correct.pooled = FALSE)
-}
-\arguments{
- \item{dir}{Path to directory containing files with GWA results}
- \item{pops}{A vector specifying study names, which make the first
- part of the file names}
- \item{extens}{Fixed extension to the file name}
- \item{maf}{Filter threshold for the absolute number/frequency of minor allele.
- If the parameter is < 1, this MAF threshold is used for filtering before
- meta-analysis; if this parameter is >1, n*MAF -- absolute number of
- the minor allele copies -- is used}
- \item{call}{Filter threshold for SNP call rate}
- \item{phwe}{Filter threshold for SNP P-value for HWE}
- \item{precorrect}{Should GC be applied to the original data before pooling}
- \item{correct.pooled}{Whether to apply Genomic Control correction to
- the study named "POOLED"}
-}
-
-\details{
- The function looks for files named "POPSextens" in the directory
- "dir", reads them and pool consecutively using
- \code{\link{metagwa.tables}} function.
-
- The source files should contain a number of variables, such as allelic
- coding, code for the effective allele, etc. Please refer to the
- formetascore function of GenABEL package for details.
-
- When the file is not available for the first population, or there are
- non-unique population names, the function stops with an error message.
-
- If there are no files corresponding to next populations, these are
- skipped in analysis with a warning message (see details in the
- description of returned values).
-}
-
-\value{
- Results are dumped to file named "POOLEDextens" in the directory
- "dir". Additionally, a list is returned with elements
- \item{analysed.pops}{list of populations successfully analysed}
-}
-
-%\references{ ~put references to the literature/web site here ~ }
-\author{Yurii Aulchenko}
-%\note{ ~~further notes~~
-%}
-\seealso{\code{\link{metagwa.tables}}}
-%\examples{
-%}
-% Add one or more standard keywords, see file 'KEYWORDS' in the
-% R documentation directory.
-\keyword{htest}
+\name{metagwa.files}
+\alias{metagwa.files}
+\title{Meta-analysis of a series of results from GWA scans}
+\usage{
+metagwa.files(dir = ".", pops, extens, maf = 5, call = 0.95,
+ phwe = 1e-08, precorrect = TRUE, correct.pooled = FALSE)
+}
+\arguments{
+ \item{dir}{Path to directory containing files with GWA
+ results}
+
+ \item{pops}{A vector specifying study names, which make
+ the first part of the file names}
+
+ \item{extens}{Fixed extension to the file name}
+
+ \item{maf}{Filter threshold for the absolute
+ number/frequency of minor allele. If the parameter is <
+ 1, this MAF threshold is used for filtering before
+ meta-analysis; if this parameter is >1, n*MAF -- absolute
+ number of the minor allele copies -- is used}
+
+ \item{call}{Filter threshold for SNP call rate}
+
+ \item{phwe}{Filter threshold for SNP P-value for HWE}
+
+ \item{precorrect}{Should GC be applied to the original
+ data before pooling}
+
+ \item{correct.pooled}{Whether to apply Genomic Control
+ correction to the study named "POOLED"}
+}
+\value{
+Results are dumped to file named "POOLEDextens" in the
+directory "dir". Additionally, a list is returned with
+elements \item{analysed.pops}{list of populations
+successfully analysed}
+}
+\description{
+Performes meta-analysis of results of multiple GWA studies
+stored in files.
+}
+\details{
+The function looks for files named "POPSextens" in the
+directory "dir", reads them and pool consecutively using
+\code{\link{metagwa.tables}} function.
+
+The source files should contain a number of variables, such
+as allelic coding, code for the effective allele, etc.
+Please refer to the formetascore function of GenABEL
+package for details.
+
+When the file is not available for the first population, or
+there are non-unique population names, the function stops
+with an error message.
+
+If there are no files corresponding to next populations,
+these are skipped in analysis with a warning message (see
+details in the description of returned values).
+}
+\author{
+Yurii Aulchenko
+}
+\seealso{
+\code{\link{metagwa.tables}}
+}
+\keyword{htest}
+
Modified: pkg/MetABEL/man/metagwa.tables.Rd
===================================================================
--- pkg/MetABEL/man/metagwa.tables.Rd 2014-02-03 15:15:47 UTC (rev 1583)
+++ pkg/MetABEL/man/metagwa.tables.Rd 2014-02-03 15:38:27 UTC (rev 1584)
@@ -1,39 +1,44 @@
-\name{metagwa.tables}
-\alias{metagwa.tables}
-\title{Pairwise meta-analysis of results from GWA scans}
-\description{
-Performes meta-analysis of results of two individual GWA studies
-}
-
-\usage{
- metagwa.tables(data.x, data.y, name.x = "P1", name.y = "P2",
- precorrect=TRUE, correct.pooled = FALSE)
-}
-\arguments{
- \item{data.x}{First data frame with GWA data}
- \item{data.y}{Second data frame with GWA data}
- \item{name.x}{First study name}
- \item{name.y}{Second study name}
- \item{precorrect}{Should GC be applied to the original data before pooling}
- \item{correct.pooled}{Whether to apply Genomic Control correction to
- the study named "POOLED"}
-}
-
-\details{
- Original data frames should contain a number of variables,
- such as allelic coding, code for the effective allele,
- etc. Please refer to formetascore function of GenABEL package
- for details.
-}
-
-\value{
- A data frame containing summary statistics and essential details
- of the individual studies
-}
-
-%\references{}
-\author{Yurii Aulchenko}
-%\note{}
-\seealso{\code{\link{metagwa.files}}}
-%\examples{}
-\keyword{htest}
+\name{metagwa.tables}
+\alias{metagwa.tables}
+\title{Pairwise meta-analysis of results from GWA scans}
+\usage{
+metagwa.tables(data.x, data.y, name.x = "P1", name.y = "P2",
+ precorrect = TRUE, correct.pooled = FALSE)
+}
+\arguments{
+ \item{data.x}{First data frame with GWA data}
+
+ \item{data.y}{Second data frame with GWA data}
+
+ \item{name.x}{First study name}
+
+ \item{name.y}{Second study name}
+
+ \item{precorrect}{Should GC be applied to the original
+ data before pooling}
+
+ \item{correct.pooled}{Whether to apply Genomic Control
+ correction to the study named "POOLED"}
+}
+\value{
+A data frame containing summary statistics and essential
+details of the individual studies
+}
+\description{
+Performes meta-analysis of results of two individual GWA
+studies
+}
+\details{
+Original data frames should contain a number of variables,
+such as allelic coding, code for the effective allele, etc.
+Please refer to the \code{formetascore} function of the
+\code{GenABEL} package for details.
+}
+\author{
+Yurii Aulchenko
+}
+\seealso{
+\code{\link{metagwa.files}}
+}
+\keyword{htest}
+
More information about the Genabel-commits
mailing list