def coverage2str(coverage_d):
    """Convert a coverage dict {transcript: coverage} to string."""
    header = 'transcript\tcoverage'
    lines = ['\t'.join([str(transcript), str(coverage)]) for transcript, coverage in coverage_d.items()]
    return '\n'.join([header] + lines)