Commit 7bb6c672 authored by O'Reilly Media, Inc's avatar O'Reilly Media, Inc
Browse files

Initial commit

parents
Loading
Loading
Loading
Loading
+22 −0
Changes for Learning iPython Notebook - Working Files/Chapter 1/Installation of IPython Notebook using Anaconda.ipynb: 22 added lines, 0 removed lines.
Original line number Diff line number Diff line
{
 "metadata": {
  "name": ""
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [],
     "language": "python",
     "metadata": {},
     "outputs": []
    }
   ],
   "metadata": {}
  }
 ]
}
 No newline at end of file
+649 −0
Changes for Learning iPython Notebook - Working Files/Chapter 1/Introduction.ipynb: 649 added lines, 0 removed lines.
Original line number Diff line number Diff line
{
 "metadata": {
  "celltoolbar": "Slideshow",
  "name": "",
  "signature": "sha256:2a450d4211220db77edf733cefb5e2ddb631f8699a13d8d3a5454e8ad8f326cc"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "markdown",
     "metadata": {
      "slideshow": {
       "slide_type": "slide"
      }
     },
     "source": [
      "<div style=\"text-align: center\">\n",
      "    <h1>Infinite Skills &mdash; Intro to Python with IPython Notebook</h1>\n",
      "    <h2>Introduction</h2>\n",
      "    <h2>James Powell &mdash; <a href=\"james@pythonquants.com\">james@pythonquants.com</a></h2>\n",
      "</div>"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from IPython.display import IFrame, HTML, display\n",
      "from __future__ import division, unicode_literals\n",
      "\n",
      "def IFrame(url, width='100%', height=350, IFrame=IFrame):\n",
      "    display(HTML('<a href=\"{0}\">{0}</a>'.format(url)))\n",
      "    display(IFrame(url, width=width, height=height))"
     ],
     "language": "python",
     "metadata": {
      "slideshow": {
       "slide_type": "skip"
      }
     },
     "outputs": [],
     "prompt_number": 42
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "IFrame('http://www.infiniteskills.com', width='100%', height=250)"
     ],
     "language": "python",
     "metadata": {
      "slideshow": {
       "slide_type": "slide"
      }
     },
     "outputs": [
      {
       "html": [
        "<a href=\"http://www.infiniteskills.com\">http://www.infiniteskills.com</a>"
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.core.display.HTML at 0x3365990>"
       ]
      },
      {
       "html": [
        "\n",
        "        <iframe\n",
        "            width=\"100%\"\n",
        "            height=250\"\n",
        "            src=\"http://www.infiniteskills.com\"\n",
        "            frameborder=\"0\"\n",
        "            allowfullscreen\n",
        "        ></iframe>\n",
        "        "
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.lib.display.IFrame at 0x3365d50>"
       ]
      }
     ],
     "prompt_number": 50
    },
    {
     "cell_type": "markdown",
     "metadata": {
      "slideshow": {
       "slide_type": "slide"
      }
     },
     "source": [
      "Agenda \n",
      "------\n",
      "\n",
      "[Introductions](#intro)\n",
      "\n",
      "[Video Overview: Projects & Goals](#overview)\n",
      "\n",
      "[What this Video Will NOT Cover](#notcover)\n",
      "\n",
      "[About the Author](#author)\n",
      "\n",
      "[Course Links & Resources](#resources)\n",
      "\n",
      "[Prerequisites](#prereqs)"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from IPython.display import Javascript, display\n",
      "display(Javascript('''IPython.notebook.kernel.execute(\"filename = '\" + IPython.notebook.notebook_name + \"'\");'''))"
     ],
     "language": "python",
     "metadata": {
      "slideshow": {
       "slide_type": "skip"
      }
     },
     "outputs": [
      {
       "javascript": [
        "IPython.notebook.kernel.execute(\"filename = '\" + IPython.notebook.notebook_name + \"'\");"
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.core.display.Javascript at 0x1c5c690>"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from json import load\n",
      "with open(filename) as f:\n",
      "    nb = load(f)\n",
      "\n",
      "headings = [line for cell in nb['worksheets'][0]['cells']\n",
      "                     if cell['cell_type'] == 'markdown' and any(line.strip().startswith('Agenda') \n",
      "                                                                for line in cell['source'])\n",
      "                 for line in cell['source'] \n",
      "                     if '#' in line]\n",
      "\n",
      "for heading in headings:\n",
      "    if heading:\n",
      "        title, anchor = heading.strip()[1:-1].split('](')\n",
      "        print '<h2 id=\"{anchor}\">{title}</h2>'.format(title=title, anchor=anchor)"
     ],
     "language": "python",
     "metadata": {
      "slideshow": {
       "slide_type": "skip"
      }
     },
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "<h2 id=\"#intro\">Introductions</h2>\n",
        "<h2 id=\"#overview\">Video Overview: Projects & Goals</h2>\n",
        "<h2 id=\"#notcover\">What this Video Will NOT Cover</h2>\n",
        "<h2 id=\"#author\">About the Author</h2>\n",
        "<h2 id=\"#resources\">Course Links & Resources</h2>\n",
        "<h2 id=\"#prereqs\">Prerequisites</h2>\n"
       ]
      }
     ],
     "prompt_number": 4
    },
    {
     "cell_type": "markdown",
     "metadata": {
      "slideshow": {
       "slide_type": "slide"
      }
     },
     "source": [
      "<h2 id=\"#intro\">Introductions</h2>"
     ]
    },
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {
      "slideshow": {
       "slide_type": "subslide"
      }
     },
     "source": [
      "James Powell"
     ]
    },
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {
      "slideshow": {
       "slide_type": "fragment"
      }
     },
     "source": [
      "James Powell <james@pythonquants.com>"
     ]
    },
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {
      "slideshow": {
       "slide_type": "subslide"
      }
     },
     "source": [
      "[@dontusethiscode](http://twitter.com/dontusethiscode)"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from IPython.display import HTML\n",
      "\n",
      "HTML('''\n",
      "<a class=\"twitter-timeline\"  href=\"https://twitter.com/dontusethiscode\"  data-widget-id=\"503767208321765376\">Tweets by @dontusethiscode</a>\n",
      "    <script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+\"://platform.twitter.com/widgets.js\";fjs.parentNode.insertBefore(js,fjs);}}(document,\"script\",\"twitter-wjs\");</script>\n",
      "''')"
     ],
     "language": "python",
     "metadata": {
      "slideshow": {
       "slide_type": "fragment"
      }
     },
     "outputs": [
      {
       "html": [
        "\n",
        "<a class=\"twitter-timeline\"  href=\"https://twitter.com/dontusethiscode\"  data-widget-id=\"503767208321765376\">Tweets by @dontusethiscode</a>\n",
        "    <script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+\"://platform.twitter.com/widgets.js\";fjs.parentNode.insertBefore(js,fjs);}}(document,\"script\",\"twitter-wjs\");</script>\n"
       ],
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 51,
       "text": [
        "<IPython.core.display.HTML at 0x3365dd0>"
       ]
      }
     ],
     "prompt_number": 51
    },
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {
      "slideshow": {
       "slide_type": "subslide"
      }
     },
     "source": [
      "`dutc` (#nycpython, #python on Freenode)"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "IFrame('https://webchat.freenode.net/', width='100%', height=350)"
     ],
     "language": "python",
     "metadata": {
      "slideshow": {
       "slide_type": "fragment"
      }
     },
     "outputs": [
      {
       "html": [
        "<a href=\"https://webchat.freenode.net/\">https://webchat.freenode.net/</a>"
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.core.display.HTML at 0x3365750>"
       ]
      },
      {
       "html": [
        "\n",
        "        <iframe\n",
        "            width=\"100%\"\n",
        "            height=350\"\n",
        "            src=\"https://webchat.freenode.net/\"\n",
        "            frameborder=\"0\"\n",
        "            allowfullscreen\n",
        "        ></iframe>\n",
        "        "
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.lib.display.IFrame at 0x3365f50>"
       ]
      }
     ],
     "prompt_number": 52
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "IFrame('http://quant-platform.com', width='100%', height=350)"
     ],
     "language": "python",
     "metadata": {
      "slideshow": {
       "slide_type": "subslide"
      }
     },
     "outputs": [
      {
       "html": [
        "<a href=\"http://quant-platform.com\">http://quant-platform.com</a>"
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.core.display.HTML at 0x3365e90>"
       ]
      },
      {
       "html": [
        "\n",
        "        <iframe\n",
        "            width=\"100%\"\n",
        "            height=350\"\n",
        "            src=\"http://quant-platform.com\"\n",
        "            frameborder=\"0\"\n",
        "            allowfullscreen\n",
        "        ></iframe>\n",
        "        "
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.lib.display.IFrame at 0x3365f10>"
       ]
      }
     ],
     "prompt_number": 53
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "IFrame('http://forpythonquants.com', width='100%', height=350)"
     ],
     "language": "python",
     "metadata": {
      "slideshow": {
       "slide_type": "subslide"
      }
     },
     "outputs": [
      {
       "html": [
        "<a href=\"http://forpythonquants.com\">http://forpythonquants.com</a>"
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.core.display.HTML at 0x3365910>"
       ]
      },
      {
       "html": [
        "\n",
        "        <iframe\n",
        "            width=\"100%\"\n",
        "            height=350\"\n",
        "            src=\"http://forpythonquants.com\"\n",
        "            frameborder=\"0\"\n",
        "            allowfullscreen\n",
        "        ></iframe>\n",
        "        "
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.lib.display.IFrame at 0x3365b50>"
       ]
      }
     ],
     "prompt_number": 54
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "IFrame('http://meetup.com/nycpython', width='100%', height=350)"
     ],
     "language": "python",
     "metadata": {
      "slideshow": {
       "slide_type": "subslide"
      }
     },
     "outputs": [
      {
       "html": [
        "<a href=\"http://meetup.com/nycpython\">http://meetup.com/nycpython</a>"
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.core.display.HTML at 0x3365510>"
       ]
      },
      {
       "html": [
        "\n",
        "        <iframe\n",
        "            width=\"100%\"\n",
        "            height=350\"\n",
        "            src=\"http://meetup.com/nycpython\"\n",
        "            frameborder=\"0\"\n",
        "            allowfullscreen\n",
        "        ></iframe>\n",
        "        "
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.lib.display.IFrame at 0x3365ed0>"
       ]
      }
     ],
     "prompt_number": 55
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "IFrame('http://pygotham.org', width='100%', height=350)"
     ],
     "language": "python",
     "metadata": {
      "slideshow": {
       "slide_type": "subslide"
      }
     },
     "outputs": [
      {
       "html": [
        "<a href=\"http://pygotham.org\">http://pygotham.org</a>"
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.core.display.HTML at 0x3246090>"
       ]
      },
      {
       "html": [
        "\n",
        "        <iframe\n",
        "            width=\"100%\"\n",
        "            height=350\"\n",
        "            src=\"http://pygotham.org\"\n",
        "            frameborder=\"0\"\n",
        "            allowfullscreen\n",
        "        ></iframe>\n",
        "        "
       ],
       "metadata": {},
       "output_type": "display_data",
       "text": [
        "<IPython.lib.display.IFrame at 0x3365490>"
       ]
      }
     ],
     "prompt_number": 56
    },
    {
     "cell_type": "markdown",
     "metadata": {
      "slideshow": {
       "slide_type": "slide"
      }
     },
     "source": [
      "<h2 id=\"#overview\">Video Overview: Projects & Goals</h2>"
     ]
    },
    {
     "cell_type": "heading",
     "level": 3,
     "metadata": {
      "slideshow": {
       "slide_type": "fragment"
      }
     },
     "source": [
      "1. Learn about the IPython Notebook programming environment"
     ]
    },
    {
     "cell_type": "heading",
     "level": 3,
     "metadata": {
      "slideshow": {
       "slide_type": "fragment"
      }
     },
     "source": [
      "2. Learn some Python basics"
     ]
    },
    {
     "cell_type": "heading",
     "level": 3,
     "metadata": {
      "slideshow": {
       "slide_type": "fragment"
      }
     },
     "source": [
      "3. Apply #1 and #2 to complete some small projects using Python and IPython notebook"
     ]
    },
    {
     "cell_type": "markdown",
     "metadata": {
      "slideshow": {
       "slide_type": "slide"
      }
     },
     "source": [
      "<h2 id=\"#notcover\">What this Video Will NOT Cover</h2>"
     ]
    },
    {
     "cell_type": "heading",
     "level": 3,
     "metadata": {
      "slideshow": {
       "slide_type": "fragment"
      }
     },
     "source": [
      "1. In-Depth Python & Data Analytics Topics"
     ]
    },
    {
     "cell_type": "heading",
     "level": 3,
     "metadata": {
      "slideshow": {
       "slide_type": "fragment"
      }
     },
     "source": [
      "2. Python 2 vs Python 3 (Unicode, Timezones)"
     ]
    },
    {
     "cell_type": "markdown",
     "metadata": {
      "slideshow": {
       "slide_type": "slide"
      }
     },
     "source": [
      "<h2 id=\"#resources\">Course Links & Resources</h2>"
     ]
    },
    {
     "cell_type": "markdown",
     "metadata": {
      "slideshow": {
       "slide_type": "fragment"
      }
     },
     "source": [
      "[Python documentation](https://docs.python.org/2/)\n",
      "\n",
      "[Python tutorial](https://docs.python.org/2/tutorial/index.html)\n",
      "\n",
      "[IPython Notebook](http://ipython.org/notebook.html)\n",
      "\n",
      "[Pandas](http://pandas.pydata.org)\n",
      "\n",
      "[Anaconda](https://store.continuum.io/cshop/anaconda/)\n",
      "\n",
      "[matplotlib](http://matplotlib.org/)"
     ]
    },
    {
     "cell_type": "markdown",
     "metadata": {
      "slideshow": {
       "slide_type": "slide"
      }
     },
     "source": [
      "<h2 id=\"#prereqs\">Prerequisites</h2>"
     ]
    },
    {
     "cell_type": "heading",
     "level": 3,
     "metadata": {
      "slideshow": {
       "slide_type": "fragment"
      }
     },
     "source": [
      "1. Web Browser (Chrome, Firefox, Internet Explorer)"
     ]
    },
    {
     "cell_type": "heading",
     "level": 3,
     "metadata": {
      "slideshow": {
       "slide_type": "fragment"
      }
     },
     "source": [
      "2. Anaconda (we'll install together)"
     ]
    }
   ],
   "metadata": {}
  }
 ]
}
 No newline at end of file
+7 −0
Changes for Learning iPython Notebook - Working Files/Chapter 2/No Work Files.rtf: 7 added lines, 0 removed lines.
Original line number Diff line number Diff line
{\rtf1\ansi\ansicpg1252\cocoartf1038\cocoasubrtf350
{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
{\colortbl;\red255\green255\blue255;}
\margl1440\margr1440\vieww9000\viewh8400\viewkind0
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\ql\qnatural\pardirnatural

\f0\fs24 \cf0 No work files for this lesson...}
 No newline at end of file
+611 −0

File added.

Preview size limit exceeded, changes collapsed.

+2200 −0

File added.

Preview size limit exceeded, changes collapsed.

Loading