plotly.js icon indicating copy to clipboard operation
plotly.js copied to clipboard

How to clear annotations

Open rgeos opened this issue 10 years ago • 1 comments

When creating annotations like below

    fig['layout']['annotations'] = go.Annotations([])
    for i in list_of_dictionaries:
        fig['layout']['annotations'].append(go.Annotation(i))

in the first run of the script, the rendering of the annotations is correct: correct rendering

However, on a second run, with a different list of dictionaries, the new annotations are rendered correctly but without clearing the old annotations duplicate annotations

Isn't go.Annotations([]) suppose to initialize with an empty list?

Am I doing something wrong?

rgeos avatar Feb 11 '16 22:02 rgeos

Looks like a https://github.com/plotly/plotly.py bug. Please open an issue there.

etpinard avatar Feb 11 '16 22:02 etpinard