# HG changeset patch
# User greg
# Date 1488224081 18000
# Node ID 06f121a1974e730a6e9d39dd6027c1af24133aef
# Parent 82144bc3626a2dcd9edb317a7d45246c59cd53c7
Uploaded
diff -r 82144bc3626a -r 06f121a1974e gene_family_classifier.py
--- a/gene_family_classifier.py Mon Feb 27 13:14:40 2017 -0500
+++ b/gene_family_classifier.py Mon Feb 27 14:34:41 2017 -0500
@@ -85,10 +85,14 @@
def write_html_output(output, title, dir):
with open(output, 'w') as fh:
- fh.write('
%s\n' % title)
+ fh.write('%s\n' % title)
+ fh.write('\n')
+ fh.write('Size | Name |
\n')
for fname in os.listdir(dir):
- fh.write('- %s
\n' % (fname, fname))
- fh.write('\n')
+ size = str(os.path.getsixe(fname))
+ link = '%s\n' % (fname, fname)
+ fh.write('%s | %s |
\n' % (size, link))
+ fh.write('
\n')
# Define command response buffers.
@@ -142,11 +146,11 @@
if create_corresponding_coding_sequences:
out_file = args.output_ptorthocs
orthogroups_fasta_dest_dir = args.output_ptorthocs_dir
- title = 'Orthogroups with corresponding coding sequences'
+ title = 'Orthogroups and corresponding coding sequences files'
else:
out_file = args.output_ptortho
orthogroups_fasta_dest_dir = args.output_ptortho_dir
- title = 'Orthogroups'
+ title = 'Orthogroups files'
orthogroups_fasta_src_dir = os.path.join(OUTPUT_DIR, 'orthogroups_fasta')
move_directory_files(orthogroups_fasta_src_dir, orthogroups_fasta_dest_dir)
write_html_output(out_file, title, orthogroups_fasta_dest_dir)
@@ -154,6 +158,6 @@
if args.output_ptsco is not None:
single_copy_fasta_src_dir = os.path.join(OUTPUT_DIR, 'single_copy_fasta')
single_copy_fasta_dest_dir = args.output_ptsco_dir
- title = 'Single copy orthogroups'
+ title = 'Single copy orthogroups files'
move_directory_files(single_copy_fasta_src_dir, single_copy_fasta_dest_dir)
write_html_output(args.output_ptsco, title, single_copy_fasta_dest_dir)