===================== INSTRUCTIONS ============================== This document contains the instructions for installing and using the QMCPPAT package in R. Note: please install and use the package under the R (version 3.0.0) environment with 32-bit, otherwise R will report errors and the package cannot work. 1. Install For Windows users, download the compiled R package file for Windows "QMCPPAT_1.0.zip". Then use the following command in R to install the package >install.packages(pkgs="QMCPPAT_1.0.zip",repos=NULL) 2. Use Use >library(QMCPPAT) to load the package into R. Use >?QMCPPAT to read the instruction. 3. Example Download the sample pedigree file "ped.txt". Then use >QMCPPAT("ped.txt",af=NULL,mcsize=50,loci=NULL,c=NULL,QTL_missing=0,allele_missing=0,header=TRUE) $pvalue Q-PPAT1 Q-PPAT2 Q-PPAT3 Q-MCPPAT1 Q-MCPPAT2 Q-MCPPAT3 Marker1_1 0.01699427 0.01430727 0.01532377 0.003247729 0.003500208 0.004378608 Marker2_1 0.17534127 0.18998417 0.18357064 0.847678272 0.661451369 0.766886252 $Tstat Q-PPAT1 Q-PPAT2 Q-PPAT3 Q-MCPPAT1 Q-MCPPAT2 Q-MCPPAT3 Marker1_1 -2.386832 -2.449455 -2.424635 -2.9432625 -2.9200095 -2.8495140 Marker2_1 -1.355239 -1.310626 -1.329841 0.1920816 0.4379102 0.2964503 Note 1. The Q-MCPPAT statistics and P values may be different for different runs, because of the Monte Carlo sampling. Note 2. If af (allele frequency) is unknown, it will be estimated based on all the typed founders. Note 3. If c is unknown, it will be estimated by (1) the mean quantitative trait value based on all the typed founders; (2) the mean quantitative trait value based on all the typed nonfounders; (3) the mean quantitative trait value based on both the typed founders and nonfounders, and this code outputs the Q-PPAT and Q-MCPPAT statistics and the corresponding P values for each value of c. 4. Arguments ped The name of a standard linkage pedigree file or a matrix/dataframe containing the pedigrees. The pedigree file contains the following information: pedigree ID, individual ID, father's ID, mother's ID, sex, phenotype, genotypes. Either father's or mother's id is set to 0 for founders, i.e. individuals with no parents. Numeric coding for sex is 0=unknown, 1=male, 2=female. Numeric coding for genotype is 0=unknown, 1=allele 1, 2=allele 2. For quantitative traits, phenotypes are individuals' trait values. af Dataframe/matrix of marker allele frequencies, one column for each marker locus. If af is unknown, the procedure will estimate the allele frequencies based on typed founders. mcsize The Monte Carlo sample size. It can take value of any positive integer. loci The name of a standard linkage loci file. c c is the constant used in the Q-PPAT statistic. If c = NULL, it will be estimated by the following three ways: the mean quantitative trait value from typed founders; the mean quantitative trait value from typed nonfounders; the mean quantitative trait value for all the typed individuals in the pedigree data set. QTL_missing The input variable "QTL_missing" is the missing value for quantitative trait values in the data files. It can take NA, but cannot take any other string values. allele_missing The input variable "allele_missing" represents that the allele at the locus is missing, e.g., it may be 0 in some data files; or -9 in some data files; or other numeric value. It cannot be NA or string values. header If ped contains variable names, then set header = TRUE (or T), otherwise header = FALSE (or F). The default value is TRUE (or T). 5. Reference Hai-Qiang He, Wei-Gao Mao, Dongdong Pan, Ji-Yuan Zhou, Ping-Yan Chen and Wing Kam Fung. 2013 Detection of parent-of-origin effects for quantitative traits using general pedigree data. (submitted) Jie Ding, Shili Lin, Yang Liu. 2006 Monte Carlo pedigree disequilibrium test for markers on X chromosome. American Journal of Human Genetics, 79, 567-573. ----------------------------------------------------------------- If you have any questions, please email Dr. Ji-Yuan Zhou at zhoujiyuan@gmail.com