Created
September 17, 2019 12:27
-
-
Save tanvirstreame/f6c934a2a15df6dc3720bb384255e1c4 to your computer and use it in GitHub Desktop.
line graph
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import plotly.graph_objects as go | |
import datetime | |
x = [datetime.datetime(year=2013, month=10, day=4), | |
datetime.datetime(year=2013, month=11, day=5), | |
datetime.datetime(year=2013, month=12, day=6)] | |
fig = go.Figure(data=[go.Scatter(x=x, y=[1, 3, 6])]) | |
# Use datetime objects to set xaxis range | |
fig.update_layout(xaxis_range=[datetime.datetime(2013, 10, 17), | |
datetime.datetime(2013, 11, 20)]) | |
fig.show() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment