comparison RepEnrich.py @ 14:bf866bedd4b4 draft

planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/main/tools/repenrich commit 205141a3f695f202d5c3e01e6ab3b2b869fe62b5
author artbio
date Sat, 20 Apr 2024 12:13:52 +0000
parents 530626b0757c
children
comparison
equal deleted inserted replaced
13:530626b0757c 14:bf866bedd4b4
1 import argparse 1 import argparse
2 import csv 2 import csv
3 import os
4 import shlex 3 import shlex
5 import subprocess 4 import subprocess
6 import sys 5 import sys
7 from collections import defaultdict 6 from collections import defaultdict
8 from concurrent.futures import ProcessPoolExecutor 7 from concurrent.futures import ProcessPoolExecutor
43 simple_repeat = "Simple_repeat" 42 simple_repeat = "Simple_repeat"
44 if args.fastqfile2: 43 if args.fastqfile2:
45 paired_end = True 44 paired_end = True
46 else: 45 else:
47 paired_end = False 46 paired_end = False
48
49 # check that the programs we need are available
50 try:
51 subprocess.call(shlex.split("coverageBed -h"),
52 stdout=open(os.devnull, 'wb'),
53 stderr=open(os.devnull, 'wb'))
54 subprocess.call(shlex.split("bowtie --version"),
55 stdout=open(os.devnull, 'wb'),
56 stderr=open(os.devnull, 'wb'))
57 except OSError:
58 print("Error: Bowtie or bedtools not loaded")
59 raise
60 47
61 48
62 def starts_with_numerical(list): 49 def starts_with_numerical(list):
63 try: 50 try:
64 if len(list) == 0: 51 if len(list) == 0: