ebv/talon_GTF_2_transcript_bed.py
def create_BED_entry(gtf_transcript):
    """ Given a GTF transcript (in list form), create a BED entry. This entails:
        1. Convert coordinates from 1-based to 0-based
        2. Extract unique transcript identifier to use in name field
        3. Extract other attributes (ie chromosome, strand) """

    chromosome = gtf_transcript[0]
    start_1b = int(gtf_transcript[3])
    end_1b = int(gtf_transcript[4])
    strand = gtf_transcript[6]
    meta = gtf_transcript[-1] 
   
    # Convert coords to 0-based
    start_0b = start_1b - 1
    end_0b = end_1b

    # Extract unique transcript identifier
    # Parse description
    transcript_ID = parse_out_transcript_ID(meta)

    # assemble BED
    bed = [ chromosome, start_0b, end_0b, transcript_ID, "0", strand ]
    return bed
 Given a GTF transcript (in list form), create a BED entry. This entails:
        1. Convert coordinates from 1-based to 0-based
        2. Extract unique transcript identifier to use in name field
        3. Extract other attributes (ie chromosome, strand) 
Given a GTF transcript (in list form), create a BED entry. This entails:
1. Convert coordinates from 1-based to 0-based
2. Extract unique transcript identifier to use in name field
3. Extract other attributes
Given a GTF transcript ( in list form ) create a BED entry . This entails : 1 . Convert coordinates from 1 - based to 0 - based 2 . Extract unique transcript identifier to use in name field 3 . Extract other attributes
def create_BED_entry(gtf_transcript):
    chromosome = gtf_transcript[0]
    start_1b = int(gtf_transcript[3])
    end_1b = int(gtf_transcript[4])
    strand = gtf_transcript[6]
    meta = gtf_transcript[-1] 
    start_0b = start_1b - 1
    end_0b = end_1b
    transcript_ID = parse_out_transcript_ID(meta)
    bed = [ chromosome, start_0b, end_0b, transcript_ID, "0", strand ]
    return bed
def create_BED_entry ( gtf_transcript ) : chromosome = gtf_transcript [ 0 ] start_1b = int ( gtf_transcript [ 3 ] ) end_1b = int ( gtf_transcript [ 4 ] ) strand = gtf_transcript [ 6 ] meta = gtf_transcript [ - 1 ] start_0b = start_1b - 1 end_0b = end_1b transcript_ID = parse_out_transcript_ID ( meta ) bed = [ chromosome , start_0b , end_0b , transcript_ID , "0" , strand ] return bed
Given a GTF transcript (in list form), create a BED entry.
Given a GTF transcript ( in list form ) create a BED entry .
""" Given a GTF transcript (in list form), create a BED entry. This entails:
        1. Convert coordinates from 1-based to 0-based
        2. Extract unique transcript identifier to use in name field
        3. Extract other attributes (ie chromosome, strand) """ # Convert coords to 0-based # Extract unique transcript identifier # Parse description # assemble BED
gtf_transcript