Animation Produces extremely large files

Hi @cmccully,

I couldn’t find one, so here’s a simple one you can start with

from plotly.offline import plot

fig = {
    'data': [{
        'type': 'scatter',
        'mode': 'lines',
        'x': [0, 1, 2, 3, 4, 5, 6, 7, 8, 9],
        'y': [0, 2, 2, 3, 2, 4, 1, 4, 3, 6],
        'transforms': [{
            'type': 'filter',
            'target': 'x',
            'operation': '<=',
            'value': 0
        }]
    }],
    'layout': {
        'xaxis': {'range': [0, 10]},
        'yaxis': {'range': [0, 10]}
    },
    'frames': [{
        'data': [{
            'transforms': [{
                'value': i
            }]
        }]
    } for i in range(10)]
}

plot(fig, validate=False)

filter_animate

Hope that helps!
-Jon

2 Likes