def _single_cluster(c, data, out_file, args):
valid, ann = <NUM_LIT:0>, <NUM_LIT:0><EOL>raw_file = None<EOL>freq = defaultdict()<EOL>[freq.update({s.keys()[<NUM_LIT:0>]: s.values()[<NUM_LIT:0>]}) for s in data[<NUM_LIT:0>][c]['<STR_LIT>']]<EOL>names = [s.keys()[<NUM_LIT:0>] for s in data[<NUM_LIT:0>][c]['<STR_LIT>']]<EOL>seqs = [s.values()[<NUM_LIT:0>] for s in data[<NUM_LIT:0>][c]['<STR_LIT>']]<EOL>loci = data[<NUM_LIT:0>][c]['<STR_LIT>']<EOL>if loci[<NUM_LIT:0>][<NUM_LIT:3>] - loci[<NUM_LIT:0>][<NUM_LIT:2>] > <NUM_LIT>:<EOL><INDENT>logger.info("<STR_LIT>" % loci)<EOL>return valid, ann, {}<EOL><DEDENT>if not file_exists(out_file):<EOL><INDENT>if args.razer:<EOL><INDENT>logger.debug("<STR_LIT>" % loci)<EOL>map_to_precursors(seqs, names, {loci[<NUM_LIT:0>][<NUM_LIT:0>]: [loci[<NUM_LIT:0>][<NUM_LIT:0>:<NUM_LIT:5>]]}, out_file, args)<EOL><DEDENT>else:<EOL><INDENT>logger.debug("<STR_LIT>" % loci)<EOL>if args.debug:<EOL><INDENT>raw_file = out_file<EOL><DEDENT>out_file = map_to_precursor_biopython(seqs, names, loci[<NUM_LIT:0>][<NUM_LIT:0>:<NUM_LIT:5>], args)<EOL><DEDENT><DEDENT>logger.debug("<STR_LIT>")<EOL>df = _convert_to_df(out_file, freq, raw_file)<EOL>if df:<EOL><INDENT>valid, ann = _make(data[<NUM_LIT:0>][c])<EOL><DEDENT>return valid, ann, df<EOL>
Map sequences on precursors and create
expression profile