<commit_before>#!/usr/bin/env python
#coding=utf-8
"""Calculates a network metric"""
__author__ = '<NAME> <<EMAIL>>'
__copyright__ = 'Copyright (c) 2015 <NAME>'
__license__ = 'New-style BSD'
__package__ = 'phylogemetric'

import os
import argparse

try:
    from nexus import NexusReader
except ImportError:
    raise ImportError("Please install python-nexus")

from . import DeltaScoreMetric
from . import QResidualMetric

def main(args=None):
    parser = argparse.ArgumentParser(
        description='Calculates a phylogenetic network metric from a nexus file'
    )
    parser.add_argument("method", help="Method [delta/qresidual]")
    parser.add_argument("filename", help="nexusfile")
    args = parser.parse_args()
    
    if not os.path.isfile(args.filename):
        raise IOError("File %s does not exist" % args.filename)
    nex = NexusReader(args.filename)
    <commit_msg>changing to 2016<commit_after>#!/usr/bin/env python
#coding=utf-8
"""Calculates a network metric"""
__author__ = '<NAME> <<EMAIL>>'
__copyright__ = 'Copyright (c) 2015-2016 <NAME>'
__license__ = 'New-style BSD'
__package__ = 'phylogemetric'

import os
import argparse

try:
    from nexus import NexusReader
except ImportError:
    raise ImportError("Please install python-nexus")

from . import DeltaScoreMetric
from . import QResidualMetric

def main(args=None):
    descr = 'Calculates a phylogenetic network metric from a nexus file'
    parser = argparse.ArgumentParser(description=descr)
    parser.add_argument("method", help="Method [delta/qresidual]")
    parser.add_argument("filename", help="nexusfile")
    args = parser.parse_args()
    
    if not os.path.isfile(args.filename):
        raise IOError("File %s does not exist" % args.filename)
    nex = NexusReader(args.filename)
    
{'fraction_non_alphanumeric': 0.11547085201793722, 'fraction_numerical': 0.010089686098654708, 'mean_word_length': 4.3927492447129906, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1667630', 'n_tokens_mistral': 592, 'n_tokens_neox': 548, 'n_words': 149}