[Genabel-commits] r867 - branches/ProbABEL-refactoring/ProbABEL/src
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Thu Mar 29 00:28:28 CEST 2012
Author: maartenk
Date: 2012-03-29 00:28:27 +0200 (Thu, 29 Mar 2012)
New Revision: 867
Added:
branches/ProbABEL-refactoring/ProbABEL/src/usage.cpp
Modified:
branches/ProbABEL-refactoring/ProbABEL/src/usage.h
Log:
split of usage.h into usage.cpp and usage.h
Added: branches/ProbABEL-refactoring/ProbABEL/src/usage.cpp
===================================================================
--- branches/ProbABEL-refactoring/ProbABEL/src/usage.cpp (rev 0)
+++ branches/ProbABEL-refactoring/ProbABEL/src/usage.cpp 2012-03-28 22:28:27 UTC (rev 867)
@@ -0,0 +1,49 @@
+#include <fstream>
+#include <cstdlib>
+#include <cstdio>
+
+
+void print_usage(char * program_name, int exit_code) {
+ fprintf(stdout, "Usage: %s options\n", program_name);
+ fprintf(stdout, "Options:\n");
+ fprintf(stdout, "\t --pheno : phenotype file name\n");
+ fprintf(stdout, "\t --info : information (e.g. MLINFO) file name\n");
+ fprintf(stdout,
+ "\t --dose : predictor (e.g. MLDOSE/MLPROB) file name\n");
+ fprintf(stdout, "\t --map : [optional] map file name\n");
+ fprintf(stdout, "\t --nids : [optional] number of people to analyse\n");
+ fprintf(stdout,
+ "\t --chrom : [optional] chromosome (to be passed to output)\n");
+ fprintf(stdout,
+ "\t --out : [optional] output file name (default is regression.out.txt)\n");
+ fprintf(stdout,
+ "\t --skipd : [optional] how many columns to skip in the predictor\n\t (dose/prob) file (default 2)\n");
+#if COXPH
+ fprintf(stdout,"\t --ntraits : [optional] how many traits are analysed (default 2)\n");
+#else
+ fprintf(stdout,
+ "\t --ntraits : [optional] how many traits are analysed (default 1)\n");
+#endif
+ fprintf(stdout,
+ "\t --ngpreds : [optional] how many predictor columns per marker\n\t (default 1 = MLDOSE; else use 2 for MLPROB)\n");
+ fprintf(stdout,
+ "\t --separat : [optional] character to separate fields (default is space)\n");
+ fprintf(stdout, "\t --score : use score test\n");
+ fprintf(stdout, "\t --no-head : do not report header line\n");
+ fprintf(stdout,
+ "\t --allcov : report estimates for all covariates (large outputs!)\n");
+ fprintf(stdout,
+ "\t --interaction: Which covariate to use for interaction with SNP analysis (default is no interaction, 0)\n");
+ fprintf(stdout,
+ "\t --interaction_only: like previous but without covariate acting in interaction with SNP (default is no interaction, 0)\n");
+ fprintf(stdout,
+ "\t --mmscore : score test in samples of related individuals. File with inverse of variance-covariance matrix (for palinear) or inverse correlation (for palogist) as input parameter\n");
+ fprintf(stdout,
+ "\t --robust : report robust (aka sandwich, aka Hubert-White) standard errors\n");
+ fprintf(stdout, "\t --help : print help\n");
+ exit(exit_code);
+}
+
+void print_help(char * program_name, int exit_code) {
+ print_usage(program_name, exit_code);
+}
Property changes on: branches/ProbABEL-refactoring/ProbABEL/src/usage.cpp
___________________________________________________________________
Added: svn:executable
+ *
Added: svn:mime-type
+ text/plain
Modified: branches/ProbABEL-refactoring/ProbABEL/src/usage.h
===================================================================
--- branches/ProbABEL-refactoring/ProbABEL/src/usage.h 2012-03-28 21:54:27 UTC (rev 866)
+++ branches/ProbABEL-refactoring/ProbABEL/src/usage.h 2012-03-28 22:28:27 UTC (rev 867)
@@ -1,44 +1,14 @@
-void print_usage(char * program_name, int exit_code) {
- fprintf(stdout, "Usage: %s options\n", program_name);
- fprintf(stdout, "Options:\n");
- fprintf(stdout, "\t --pheno : phenotype file name\n");
- fprintf(stdout, "\t --info : information (e.g. MLINFO) file name\n");
- fprintf(stdout,
- "\t --dose : predictor (e.g. MLDOSE/MLPROB) file name\n");
- fprintf(stdout, "\t --map : [optional] map file name\n");
- fprintf(stdout, "\t --nids : [optional] number of people to analyse\n");
- fprintf(stdout,
- "\t --chrom : [optional] chromosome (to be passed to output)\n");
- fprintf(stdout,
- "\t --out : [optional] output file name (default is regression.out.txt)\n");
- fprintf(stdout,
- "\t --skipd : [optional] how many columns to skip in the predictor\n\t (dose/prob) file (default 2)\n");
-#if COXPH
- fprintf(stdout,"\t --ntraits : [optional] how many traits are analysed (default 2)\n");
-#else
- fprintf(stdout,
- "\t --ntraits : [optional] how many traits are analysed (default 1)\n");
-#endif
- fprintf(stdout,
- "\t --ngpreds : [optional] how many predictor columns per marker\n\t (default 1 = MLDOSE; else use 2 for MLPROB)\n");
- fprintf(stdout,
- "\t --separat : [optional] character to separate fields (default is space)\n");
- fprintf(stdout, "\t --score : use score test\n");
- fprintf(stdout, "\t --no-head : do not report header line\n");
- fprintf(stdout,
- "\t --allcov : report estimates for all covariates (large outputs!)\n");
- fprintf(stdout,
- "\t --interaction: Which covariate to use for interaction with SNP analysis (default is no interaction, 0)\n");
- fprintf(stdout,
- "\t --interaction_only: like previous but without covariate acting in interaction with SNP (default is no interaction, 0)\n");
- fprintf(stdout,
- "\t --mmscore : score test in samples of related individuals. File with inverse of variance-covariance matrix (for palinear) or inverse correlation (for palogist) as input parameter\n");
- fprintf(stdout,
- "\t --robust : report robust (aka sandwich, aka Hubert-White) standard errors\n");
- fprintf(stdout, "\t --help : print help\n");
- exit(exit_code);
-}
+/*
+ * usage.h
+ *
+ * Created on: Mar 6, 2012
+ * Author: mkooyman
+ */
-void print_help(char * program_name, int exit_code) {
- print_usage(program_name, exit_code);
-}
+#ifndef USAGE_H_
+#define USAGE_H_
+void print_usage(char * program_name, int exit_code);
+
+void print_help(char * program_name, int exit_code);
+
+#endif /* USAGE_H_ */
More information about the Genabel-commits
mailing list