In [1]:
import biojs
theSequence = '111111111122222222223333333333444444444455555555556666666666111111111122222222223333333333444444444455555555556666666666'

In [2]:
options = {
    'sequence' : theSequence,
    'format' : 'CODATA',
}                  
seqs = biojs.Seq(options)

In [3]:
annotations = [
    {
        'name':"track1",
        'html':"<br> Example of <b>HTML</b>",
        'color':"black",
        'regions': [
            {'start': 2, 'end': 2},
            {'start': 20, 'end': 30},
            {'start': 31, 'end': 43}
        ]
    }
]

highlights = [
    { "start": 1, "end": 15, "color": "white", "background": "red", "id": "aaa" },
    { "start": 7, "end": 21, "color": "white", "background": "green", "id": "bbb" },
    { "start": 12, "end": 26, "color": "white", "background": "blue", "id": "ccc" }
]

In [4]:
seqs.addAnnotation(annotations)
seqs.addHighlight(highlights)

In [5]:
seqs.plot()

In [ ]: