コード例 #1
0
ファイル: apytram.py プロジェクト: msemon/apytram
        if not args.no_last_iter_file:
            # Last iteration seqeunces
            ExitCode = ApytramNeeds.write_apytram_output(FileteredTrinityFasta,
                                                         TrinityExonerateResultsDict,
                                                         OutPrefixName+".fasta",
                                                         Header = TrinityExonerateProcess.Ryo.replace('%',"").replace("\n","").split(),
                                                         Names = FilteredSequenceNames)
    # Stats files
    start_output_stat = time.time()
    if args.stats:
        logger.info("Write statistics file (OutPrefix.stats.csv)")
        ApytramNeeds.write_stats(StatsDict,OutPrefixName)
        
        if args.plot:
            logger.info("Create plot from the statistics file (OutPrefix.stats.pdf)")
            ApytramNeeds.create_plot(StatsDict, OutPrefixName)
            logger.debug("Writing stats file --- %s seconds ---" % (time.time() - start_output_stat))
        
    if args.plot_ali:
        start_output_ali = time.time()
        logger.info("Create plot from the statistics file (OutPrefix.ali.png)")
        ApytramNeeds.create_plot_ali(DicPlotCov, OutPrefixName)
        logger.debug("Writing alignment plot --- %s seconds ---" % (time.time() - start_output_ali))
else:
    logger.warn("No results")
    
### Remove tempdir if the option --tmp have not been use
if not args.tmp:
    logger.debug("Remove the temporary directory")
    #Remove the temporary directory :
    if "tmp_apytram" in TmpDirName: