Skip to content

Instantly share code, notes, and snippets.

@ceclinux
Created July 3, 2015 14:45
Show Gist options
  • Save ceclinux/3b9576f5490a3500c0da to your computer and use it in GitHub Desktop.
Save ceclinux/3b9576f5490a3500c0da to your computer and use it in GitHub Desktop.
Display the source blob
Display the rendered blob
Raw
{
"cells": [
{
"metadata": {
"collapsed": false,
"trusted": true
},
"cell_type": "code",
"source": "import plotly.plotly as py\nfrom plotly.graph_objs import *\n\ntrace0 = Scatter(\n x=[1, 2, 3, 4],\n y=[10, 15, 13, 17]\n)\ntrace1 = Scatter(\n x=[1, 2, 3, 4],\n y=[16, 5, 11, 9]\n)\ndata = Data([trace0, trace1])\n\npy.iplot(data, filename = 'basic-line')",
"execution_count": 2,
"outputs": [
{
"data": {
"text/plain": "<plotly.tools.PlotlyDisplay object>",
"text/html": "<iframe id=\"igraph\" scrolling=\"no\" style=\"border:none;\"seamless=\"seamless\" src=\"https://plot.ly/~src655/108.embed\" height=\"525\" width=\"100%\"></iframe>"
},
"output_type": "execute_result",
"execution_count": 2,
"metadata": {}
}
]
},
{
"metadata": {
"collapsed": false,
"trusted": true
},
"cell_type": "code",
"source": "import plotly.tools as tls\n\ntls.embed(\"https://plot.ly/~src655/43\")",
"execution_count": 3,
"outputs": [
{
"data": {
"text/plain": "<plotly.tools.PlotlyDisplay object>",
"text/html": "<iframe id=\"igraph\" scrolling=\"no\" style=\"border:none;\"seamless=\"seamless\" src=\"https://plot.ly/~src655/43.embed\" height=\"525\" width=\"100%\"></iframe>"
},
"output_type": "execute_result",
"execution_count": 3,
"metadata": {}
}
]
}
],
"metadata": {
"kernelspec": {
"name": "python3",
"display_name": "Python 3",
"language": "python"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"pygments_lexer": "ipython3",
"nbconvert_exporter": "python",
"mimetype": "text/x-python",
"name": "python",
"file_extension": ".py",
"version": "3.4.3"
}
},
"nbformat": 4,
"nbformat_minor": 0
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment