-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathremovedSnpHWEauto.Rd
68 lines (61 loc) · 2.15 KB
/
removedSnpHWEauto.Rd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/genotypeQC.R
\name{removedSnpHWEauto}
\alias{removedSnpHWEauto}
\title{Hardy Weinberg Equilibrium test for autosomal SNPs}
\usage{
removedSnpHWEauto(
groupLabel,
plink,
inputPrefix,
pval = 1e-06,
outputPvalFile,
outputSNPfile,
outputPrefix
)
}
\arguments{
\item{groupLabel}{a string value indicating the outcome label: "control",
or, "case" or "caseControl" for both existing groups. For more details, see
\code{\link{getGroupLabel}}.}
\item{plink}{an executable program in either the current working directory
or somewhere in the command path.}
\item{inputPrefix}{the prefix of the input PLINK binary files.}
\item{pval}{the p-value cutoff for controlling HWE test in either control or
case subjects. Only autosomal SNPs are considered. The default value is
0.000001.}
\item{outputPvalFile}{the output pure text file that stores autosomal SNPs
and their sorted HWE p-values.}
\item{outputSNPfile}{the output pure text file that stores the removed SNPs,
one per line.}
\item{outputPrefix}{the prefix of the output PLINK binary files.}
}
\value{
The output PLINK binary files after HWE test on the autosome.
}
\description{
Remove autosomal SNPs deviating from Hardy Weinberg Equilibrium (HWE).
}
\examples{
## In the current working directory
bedFile <- system.file("extdata", "genoUpdatedData.bed", package="Gimpute")
bimFile <- system.file("extdata", "genoUpdatedData.bim", package="Gimpute")
famFile <- system.file("extdata", "genoUpdatedData.fam", package="Gimpute")
system(paste0("scp ", bedFile, bimFile, famFile, " ."))
groupLabel <- "control"
inputPrefix <- "genoUpdatedData" ## Specify the input PLINK file prefix
outputPvalFile <- "2_11_snpHwePvalAuto.txt"
outputSNPfile <- "2_11_snpRemovedHweAuto.txt"
outputPrefix <- "2_11_removedSnpHweAuto"
## Not run: Requires an executable program PLINK, e.g.
## plink <- "/home/tools/plink"
## removedSnpHWEauto(groupLabel, plink, inputPrefix, pval=0.000001,
## outputPvalFile, outputSNPfile, outputPrefix)
}
\seealso{
\code{\link{removedSnpFemaleChrXhweControl}},
\code{\link{getGroupLabel}}.
}
\author{
Junfang Chen
}