Iβm running a python script on a cron job (ubuntu server in python virtualenv) and every time I generate a plot I am greeted with the documentation (at bottom; opens in w3m via SSH), which blocks my script from finishing. Whatβs frustrating is the plot is being uploaded and is visible from my online profile. How do it set this to not open EVERY time i generate a plot?
Iβve done the
plotly.tools.set_credentials_file(username=βDemoAccountβ, api_key=βlr19g7zw81β) #with actual credentials
Code:
import plotly
import pandas as pd
data = pd.read_csv(βdataβ)
t1 = plotly.graph_objs.Scatter(name=βValueβ, x=data.DateTime, y=data.Value, line=plotly.graph_objs.Line(color=βblueβ))
t2 = plotly.graph_objs.Scatter(name=βValue 2β, x=data.DateTime, y=data.Value2, yaxis=βy2β, line=plotly.graph_objs.Line(color=βgreenβ))
data = [t1, t2, t3, t4, t5]
layout = {βtitleβ: βgraphβ,
βyaxisβ: {βtitleβ: βValueβ, βdomainβ:[0.5,1]},
βyaxis2β: {βtitleβ: βValue2β, βdomainβ:[0.0, 0.5]},
βxaxisβ: {βanchorβ:βy2β}}
fig = plotly.graph_objs.Figure(data=data, layout=layout)
plotly.offline.plot(fig, filename=βfigure.htmlβ, auto_open=False)
plotly.plotly.plot(fig, filename=βFigureβ)
plotly
Sign In SIGN UP UPGRADE REQUEST DEMO
[français]
Feed Pricing Make a Chart
Help
Feed Pricing Make a Chart Help
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Sign In Sign up Upgrade
Plotly is the collaboration platform for modern data science.
Set up a private Plotly cloud at your company.
API
β’ API Home
β’ Python
β’ R
β’ MATLAB
β’ JavaScript