Skip to content

Commit 38c700d

Browse files
committed
Adding extended setup instructions
1 parent d7d3d8a commit 38c700d

1 file changed

Lines changed: 105 additions & 39 deletions

File tree

setup.md

Lines changed: 105 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -24,78 +24,144 @@ title: Setup
2424

2525

2626

27-
> ## Software
28-
> [Python](http://python.org) is a popular language for
29-
> scientific computing, and great for general-purpose programming as
30-
> well. Installing all of its scientific packages individually can be
31-
> a bit difficult, so we recommend an all-in-one installer.
27+
> ## Installing Python using Anaconda
28+
> [Python][python] is a popular language for scientific computing, and great for
29+
> general-purpose programming as well. Installing all of its scientific packages
30+
> individually can be a bit difficult, however, so we recommend the all-in-one
31+
> installer [Anaconda][anaconda].
3232
>
33-
> For this workshop we use Python version 3.x.
34-
>
35-
> ### Required Python Packages for this workshop
36-
>
37-
> * [Pandas](http://pandas.pydata.org/)
38-
> * [Jupyter notebook](http://jupyter.org/)
39-
> * [Numpy](http://www.numpy.org/)
40-
> * [Matplotlib](http://matplotlib.org/)
33+
> Regardless of how you choose to install it, please make sure you install Python
34+
> version 3.x (e.g., 3.6 is fine). Also, please set up your Python environment at
35+
> least a day in advance of the workshop. If you encounter problems with the
36+
> installation procedure, ask your workshop organizers via e-mail for assistance so
37+
> you are ready to go as soon as the workshop begins.
4138
{: .prereq}
4239

43-
## Install the workshop packages
40+
### Windows - [Video tutorial][video-windows]
41+
42+
1. Open [https://www.anaconda.com/distribution/][anaconda-windows] with your web browser.
43+
44+
2. Download the Python 3 installer for Windows.
45+
46+
3. Double-click the executable and install Python 3 using the recommended settings. Make sure that **Register Anaconda as my default Python 3.x** option is checked - it should be in the latest version of Anaconda
47+
48+
49+
### Mac OS X - [Video tutorial][video-mac]
50+
51+
1. Visit [https://www.anaconda.com/distribution/][anaconda-mac] with your web browser.
52+
53+
2. Download the Python 3 installer for OS X. These instructions assume that you use the graphical installer `.pkg` file.
54+
55+
3. Follow the Python 3 installation instructions. Make sure that the install location is set to "Install only for me" so Anaconda will install its files locally, relative to your home directory. Installing the software for all users tends to create problems in the long run and should be avoided.
56+
57+
58+
### Linux
59+
60+
Note that the following installation steps require you to work from the terminal (shell).
61+
If you run into any difficulties, please request help before the workshop begins.
62+
63+
1. Open [https://www.anaconda.com/distribution/][anaconda-linux] with your web browser.
64+
65+
2. Download the Python 3 installer for Linux.
66+
67+
3. Install Python 3 using all of the defaults for installation.
68+
69+
a. Open a terminal window.
4470

45-
For installing these packages we will use Anaconda or Miniconda.
46-
They both use [Conda](https://conda.io/en/latest/), the main difference is
47-
that Anaconda comes with a lot of packages pre-installed.
48-
With Miniconda you will need to install the required packages.
71+
b. Navigate to the folder where you downloaded the installer
4972

50-
### Anaconda installation
73+
c. Type
5174

52-
Anaconda will install the workshop packages for you.
75+
~~~
76+
$ bash Anaconda3-
77+
~~~
78+
{: .bash}
5379
54-
#### Download and install Anaconda
80+
and press tab. The name of the file you just downloaded should appear.
5581
56-
Download and install [Anaconda](https://www.anaconda.com/distribution/#download-section).
57-
Remember to download and install the installer for Python 3.x.
82+
d. Press enter.
5883
59-
#### Download plotting package
84+
e. Follow the text-only prompts. When the license agreement appears (a colon
85+
will be present at the bottom of the screen) press the space bar until you see the
86+
bottom of the text. Type `yes` and press enter to approve the license. Press
87+
enter again to approve the default location for the files. Type `yes` and
88+
press enter to prepend Anaconda to your `PATH` (this makes the Anaconda
89+
distribution your user's default Python).
6090
61-
The plotting package plotnine is not installed by default. From the terminal,
62-
type:
91+
92+
[anaconda]: https://www.anaconda.com/
93+
[anaconda-mac]: https://www.anaconda.com/download/#macos
94+
[anaconda-linux]: https://www.anaconda.com/download/#linux
95+
[anaconda-windows]: https://www.anaconda.com/download/#windows
96+
[jupyter]: http://jupyter.org/
97+
[python]: https://python.org
98+
[video-mac]: https://www.youtube.com/watch?v=TcSAln46u9U
99+
[video-windows]: https://www.youtube.com/watch?v=xxQ0mzZ8UvA
100+
101+
## Opening a Conda-enabled Terminal and Verifying the Installation:
102+
103+
### Windows
104+
Click Start, search, or select Anaconda Prompt from the menu. A window should pop up where you can now type commands such as checking your Conda installation with:
63105
64106
~~~
65-
conda install -c conda-forge plotnine
107+
conda --help
66108
~~~
67109
{: .language-bash}
68110
69-
### Miniconda installation
111+
### Mac OSX
70112
71-
Miniconda is a "light" version of Anaconda. If you install and use Miniconda
72-
you will also need to install the workshop packages.
113+
Click the Launchpad icon in the Dock, type Terminal in the search field, then click Terminal.
114+
A window should pop up where you can now type commands such as checking your conda installation with:
73115
74-
#### Download and install Miniconda
116+
~~~
117+
conda --help
118+
~~~
119+
{: .language-bash}
75120
76-
Download and install [Miniconda](https://docs.conda.io/en/latest/miniconda.html)
77-
following the instructions. Remember to download and run the installer for
78-
Python 3.x.
121+
### Linux
122+
This depends a bit on your Linux distribution, but often you will have an Applications listing in which you can select a Terminal icon you can click. A window should pop up where you can now type commands such as checking your conda installation with:
79123
80-
#### Check the installation of Miniconda
124+
~~~
125+
conda --help
126+
~~~
127+
{: .language-bash}
128+
129+
130+
## Required Python Packages for this Workshop
131+
The following are packages needed for this workshop:
132+
133+
* [Pandas](http://pandas.pydata.org/)
134+
* [Jupyter notebook](http://jupyter.org/)
135+
* [Numpy](http://www.numpy.org/)
136+
* [Matplotlib](http://matplotlib.org/)
137+
* [Plotnine](https://plotnine.readthedocs.io/en/stable/)
81138
82-
From the terminal, type:
139+
All packages apart from plotnine will have automatically been installed with Anaconda and we can use anaconda as a package manager to install the missing `plotnine` package:
140+
You need to open up a *Terminal*, if you are using Mac OSX, or Linux (see instructions above), or launch an *anaconda-promt*, if you are using Windows. In your terminal window type the following:
83141
84142
~~~
85-
conda list
143+
conda install -y -c conda-forge plotnine
86144
~~~
87145
{: .language-bash}
88146
89-
### Install the required workshop packages with conda
147+
This will then install the latest version of plotnine into your conda environment.
90148
91-
From the terminal, type:
149+
## Installing other Packages (Not required)
150+
If you want to install any additional packages, you can do so by opening a terminal window and type:
151+
~~~
152+
conda install -y package_name
153+
~~~
154+
{: .language-bash}
92155
156+
You may need to install the required packages in this way, if you opted for installing Miniconda, instead of Anaconda. Miniconda is a "light" version of Anaconda. If you install and use Miniconda
157+
you will also need to install the workshop packages manually in the following way:
93158
~~~
94159
conda install -y numpy pandas matplotlib jupyter
95160
conda install -c conda-forge plotnine
96161
~~~
97162
{: .language-bash}
98163
164+
99165
## Launch a Jupyter notebook
100166
101167
After installing either Anaconda or Miniconda and the workshop packages,

0 commit comments

Comments
 (0)