Skip to content

Instantly share code, notes, and snippets.

@merqurio
Created June 4, 2017 09:43
Show Gist options
  • Save merqurio/32776d2f5f0cd6aec4603834216a3b14 to your computer and use it in GitHub Desktop.
Save merqurio/32776d2f5f0cd6aec4603834216a3b14 to your computer and use it in GitHub Desktop.
Plot with plotly offline and without any logo or reference to their site
def plotter(*data):
try:
from plotly.offline import iplot
except ImportError:
print("Try to install plotly first: \n > pip install plotly")
return iplot(*data, config={"displaylogo":False, "showLink":False, 'modeBarButtonsToRemove':['sendDataToCloud']})
from plotly.graph_objs import Scatter
g1 = Scatter(x=X, y=Y, mode='markers')
plotter([g1])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment