Created
January 7, 2014 21:40
-
-
Save alexander-daniel/8307393 to your computer and use it in GitHub Desktop.
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
{ | |
"metadata": { | |
"name": "" | |
}, | |
"nbformat": 3, | |
"nbformat_minor": 0, | |
"worksheets": [ | |
{ | |
"cells": [ | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": [ | |
"import plotly\n", | |
"from numpy import *" | |
], | |
"language": "python", | |
"metadata": {}, | |
"outputs": [], | |
"prompt_number": 14 | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": [ | |
"py = plotly.plotly(username='username',key='api_key')" | |
], | |
"language": "python", | |
"metadata": {}, | |
"outputs": [], | |
"prompt_number": 9 | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": [ | |
"layout = {\n", | |
"\t'autosize': False,\n", | |
"\t'width': 600,\n", | |
"\t'height': 400,\n", | |
"\t'showlegend': False,\n", | |
"\n", | |
"\t'xaxis' : {\n", | |
"\t\t\"linecolor\":\"rgba(0, 0, 0, 0)\",\"ticks\":\"\",\n", | |
"\t\t\"showgrid\":False,\n", | |
"\t\t\"zeroline\":False,\n", | |
"\t\t\"showticklabels\":False\n", | |
"\t},\n", | |
"\n", | |
"\t'yaxis' : {\n", | |
"\t\t\"linecolor\":\"rgba(0, 0, 0, 0)\",\n", | |
"\t\t\"ticks\":\"\",\n", | |
"\t\t\"showgrid\":False,\n", | |
"\t\t\"zeroline\":False,\n", | |
"\t\t\"showticklabels\":False}\n", | |
"}\n", | |
"\n", | |
"py.iplot([{\n", | |
"\t'y': random.randn(5000),\n", | |
"\t'type': 'histogramy', \n", | |
"\t'histnorm':'probability density',\n", | |
"\t'autobinx': False,\n", | |
"\t'xbins':{\n", | |
"\t\t'start': -2.5,\n", | |
"\t\t'end': 3,\t\n", | |
"\t\t'size': 0.5\n", | |
"\t}\n", | |
"}, \n", | |
"\n", | |
"{\n", | |
"\t'x':linspace(-5,5,100),\n", | |
"\t'y': 1./sqrt(2*3.14)*exp(-linspace(-5,5,100)**2/2.),\n", | |
"\t'fill':'tozeroy',\n", | |
"\t'marker':{\n", | |
"\t\t'color': \"rgba(111, 168, 220, 0.44)\"\n", | |
"\t\t}\n", | |
"}],\n", | |
"layout=layout)" | |
], | |
"language": "python", | |
"metadata": {}, | |
"outputs": [ | |
{ | |
"output_type": "stream", | |
"stream": "stdout", | |
"text": [ | |
"\n", | |
"\n", | |
"\n" | |
] | |
}, | |
{ | |
"html": [ | |
"<iframe height=\"650\" id=\"igraph\" scrolling=\"no\" seamless=\"seamless\" src=\"https://plot.ly/~demos/981/600/600\" width=\"650\"></iframe>" | |
], | |
"metadata": {}, | |
"output_type": "pyout", | |
"prompt_number": 15, | |
"text": [ | |
"<IPython.core.display.HTML at 0x10a66e410>" | |
] | |
} | |
], | |
"prompt_number": 15 | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": [], | |
"language": "python", | |
"metadata": {}, | |
"outputs": [], | |
"prompt_number": 7 | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": [], | |
"language": "python", | |
"metadata": {}, | |
"outputs": [] | |
} | |
], | |
"metadata": {} | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment