-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathHi-reComb.cpp
More file actions
82 lines (71 loc) · 2.45 KB
/
Copy pathHi-reComb.cpp
File metadata and controls
82 lines (71 loc) · 2.45 KB
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
//
// main.cpp
// Hi-reComb
//
// Created by Milan Malinsky on 02.09.22.
//
// Hi-reComb
// Some questions:
// 1) Are insert length distributions along the genome random in the joint recomb + non-recomb pairs?
#include "generalUtils.hpp"
#include "recombFromInformativePairsSAM.hpp"
#include "findInformativePairs.hpp"
#include "countMendelianViolations.hpp"
#include "TrioPhase.hpp"
#include "simulateAndReconstruct.hpp"
#define AUTHOR "Milan Malinsky"
#define PACKAGE_VERSION "0.1 r1"
static const char *VERSION_MESSAGE =
"evo software Version " PACKAGE_VERSION "\n"
"Written by Milan Malinsky.\n"
"\n";
static const char *USAGE_MESSAGE =
"Program: " PROGRAM_BIN "\n"
"Version: " PACKAGE_VERSION "\n"
"Contact: " AUTHOR " [" PACKAGE_BUGREPORT "]\n"
"Usage: " PROGRAM_BIN " <command> [options]\n\n"
"Commands:\n"
" FindInfoPairs Find read pairs that would be informative for estimating the recombination\n"
" RecombMap Estimate the recombination map from informative Hi-C read pairs\n"
"Utilities:\n"
" Simulate Simulate informative read-pairs for a given map to evaluate confidence in reconstruction\n"
" TrioPhase Generate a phased het file for use with Hi-Recomb from a VCF with trio(s) (mother-father-offspring)\n"
// " CountViolations (specific use case) Find trios in a VCF\n"
"\nReport bugs to " PACKAGE_BUGREPORT "\n\n";
int main(int argc, char **argv) {
if(argc <= 1)
{
std::cout << USAGE_MESSAGE;
return 0;
}
else
{
string command(argv[1]);
if(command == "help" || command == "--help" || command == "-h")
{
std::cout << USAGE_MESSAGE;
return 0;
}
else if(command == "version" || command == "--version")
{
std::cout << VERSION_MESSAGE;
return 0;
}
if(command == "RecombMap")
RecombFromSAMMain(argc - 1, argv + 1);
else if(command == "FindInfoPairs")
InfoReadsMain(argc - 1, argv + 1);
else if (command == "Simulate")
SimulationMain(argc - 1, argv + 1);
else if (command == "CountViolations")
vioMain(argc - 1, argv + 1);
else if (command == "TrioPhase")
trioPhaseMain(argc - 1, argv + 1);
else
{
std::cerr << "Unrecognized command: " << command << "\n";
return 1;
}
return 0;
}
}