Appendix A — Installing what you need
A.1 Prerequisites
No specific Python knowledge is assumed for this book, though you do need to install some software. Most of it can be done using your computer’s graphical interface.
- Python 3 via Anaconda
- A reasonably recent web-browser
- The
vcfpy
andbiopython
python packages - The files example.vcf and SRR020192.fastq.gz
- A text-editor
A.2 Installing Python 3 with Anaconda
Follow this link and install Python 3.x for your operating system. https://www.anaconda.com/distribution/
A.2.1 Note for macOS users
Accept all of the defaults during installation
Here is a video tutorial https://www.youtube.com/watch?v=TcSAln46u9U
A.2.2 Note for Windows users
Install Python 3 using all of the defaults for installation except make sure to check Add Anaconda to my PATH environment variable.
Here is a video tutorial https://www.youtube.com/watch?v=xxQ0mzZ8UvA
A.2.3 Note for Linux Users
You’ll need to be able to use the command-line to install with Anaconda. If you aren’t comfortable with this, ask for assistance from the local support team.
- Open https://www.anaconda.com/download/#linux with your web browser.
- Download the Python 3 installer for Linux.
- Open a terminal window. 4.Type
bash Anaconda3-
and then press Tab. The name of the file you just downloaded should appear. If it does not, navigate to the folder where you downloaded the file, for example with:cd Downloads
. Then, try again. - Press
enter
. You will follow the text-only prompts. To move through the text, press thespacebar
. - Type
yes
and pressenter
to approve the license. - Press
enter
to approve the default location for the files. - Type
yes
and pressenter
to prepend Anaconda to yourPATH
(this makes the Anaconda distribution the default Python). - Close the terminal window.
A.3 Starting a Jupyter Notebook
A.3.1 macOS
- Start the
Terminal
application inApplications -> Utilities
- Type
jupyter notebook
, it should start in your web browser
A.3.2 Windows
- From the Start menu, search for and open
Anaconda 3
orJupyter Notebook
. You should be able to start a notebook directly by clicking theJupyter Notebook
icon.
A.3.3 Linux
- Open the terminal application. It is usually in the task bar or dock
- Type
jupyter notebook
, it should start in your web browser
A.4 Installing Python Packages with conda
You can use conda
to install new Python packages using the Terminal by typing conda install <package_name>
.
You can install the required packages with the following commands:
conda install vcfpy
conda install biopython
Accept all defaults when the system asks a question.
A.5 Installing a Text Editor
A text editor is a program that deals with text in a way that is appropriate to writing programs. It is quite different to a word processor. Many such programs are available, try the options below:
- TextMate (macOS) https://macromates.com/
- Atom (macOS/Windows) https://atom.io/
- Notepad++ (Windows) https://notepad-plus-plus.org/