Jupyter Business Demo
Here we demonstrate a workflow of how business processes could evolve by 2021, in a way that'll create a staging ground for even greater paradigm shifts after that.
The workflow here is that an "insightful" business analyst will be writing this report in Google Colab, while being supported by software engineers ("code monkeys") who will be writing useful code here in this repository.
It shall be shown how business reports can quickly be re-generated, with any assumptions tested against the current state of the world, for the easy spotting of new opportunities and risks. By running in Colab, people can start writing and executing their own code without having to install anything locally.
Note that by convention, programming is conducted in US English, even if the resultant report is in some other language (in this case, British English).
This project demonstrates the quickest and easiest way to introduce programming into the workflow of an executive or any sort of "non-technical" person.
It can be seen that even if business executives implement placeholder functions returning constants, it lays the groundwork for later contributors to turn the thinking into something that's repeatable over a timescale of decades rather than months.
Jupyter notebooks use the easiest programming language to learn, giving access to the state of the art in terms of natural-language processing, computer vision, web scraping and even monetary transactions, enabling you to run a business well into the future, even beyond the extent of your own life.
Note that this is intended as a tutorial, hence there are gaps for excited readers to implement!
Setup for Business Analysts
- Have a look at the associated Colab file and save a copy − this is where you'll be working.
- Go through some of Google's tutorial.
- Note that although most of the functionality is meant to come from the code in GitHub, it will be possible for you to create your own functions too, within the Colab document.
If you'd like to export the Colab file for presenting in a more typical way to fellow business executives, the current method is to download the notebook file, then use nbconvert at the command line in order to generate a file in HTML.
jupyter nbconvert --to HTML Kamarian_trade.ipynb
- Download the notebook (
- Use nbconvert to convert it to LaTeX format.
- Use xelatex to convert the LaTeX format to PDF. If we tried to skip the LaTeX step, the paths to imagery would be messed up.
Setup for Engineers
- In considering IDEs:
- The jupyter-notebook package for Atom says that it lacks autocompletion, which is a core reason for using an IDE.
- PyCharm only offers support in its Professional edition, whereas this code is aimed at newcomers.
- Editing is possible in Google's Colaboratory, with the possibility of local or cloud computation.
- Running a Jupyter notebook locally and accessing it through a browser, both Chrome and Brave require users to press
Tab. Chrome omits showing the actual suggestions.
- Install Python and Jupyter.
pip install --requirement requirements.txt
- If using a virtual environment, you'll need to create a local Python kernel too.
- Set up an account with Wolfram Alpha and get an API key here.
- You might wish to install jupyter_contrib_nbextensions.
- You might like to enable a filter for notebooks in Git repositories, stripping their output so that only the source code is kept in version control.
- At your command line, run
echo PATHand choose one of the folders as a place to put your script.
- Visit here and scroll down to find the new script for Jupyter v4. Also note that you should take the suggestion of adding the argument
ensure_ascii=False. Download the script into your chosen folder.
- Follow the rest of that script's installation instructions.
- At your command line, run
- In the directory where your notebook is saved (and where this
READMEfile exists), run:
- Going to «Edit» and «nbextension config», you might wish to enable Python Markdown. Instructions discussed here.
- Notice the awkward importing mechanism imposed by the path mismatch in Google Colab. Explanation is available here.
- Feel free to reach out with questions in a public forum, such as the Issues tab.
- How do engineers get notified that the business executives want a new function?
- Is there an easier way to export a published version? Ideally it would stay as HTML rather than being printed on trees, so as to keep the accessibility afforded by web browsers, and to maintain the benefits of hyperlinks.
- Include a demonstration of how Scrapy could be included here.
- Include the lunar cycles in the calculation for shipping distance.
- Unit tests for shipping distance.
- Include some financial data for pig futures markets.
- Include some data directly from Google Drive.
- Demonstration with numpy, including this tutorial.
For further discussion regarding the reasoning behind integrating Jupyter notebooks into business operations, you may be interested in: