-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathLearn_to_code_test_notebook.ipynb.txt
More file actions
75 lines (75 loc) · 2.84 KB
/
Learn_to_code_test_notebook.ipynb.txt
File metadata and controls
75 lines (75 loc) · 2.84 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Software installation test\n",
"\n",
"This Jupyter notebook is for The Open University's [_Learn to code for data analysis_](http://futurelearn.com/courses/learn-to-code) course.\n",
"\n",
"It aims to help you do a basic check whether your software installation is working as expected.\n",
"\n",
"To do that, in the menu above this, click on 'Cell' and then on 'Run all'. This will execute the code below. (The code will be explained in the course.)\n",
"\n",
"After a while you should see some text stating which version of pandas (the data analysis software we will be using) you have installed, and a graph with two dots plotted on it. \n",
"\n",
"If the version displayed is 0.16.2 and you don't get any error messages, then all's well and you can close this notebook (menu 'File', option 'Close and Halt') and then delete the notebook from your disk.\n",
"\n",
"If there is an error message saying you don't have Python 3, or if the pandas version displayed is not 0.16.2, then one of the following has probably happened: \n",
"\n",
"- you installed the wrong version of Anaconda;\n",
"- you installed the wrong variant of Anaconda (there is the same version of Anaconda both for Python 3 and Python 2); \n",
"- during the installation you decided to keep your existing Python installation. \n",
"\n",
"To see which software versions you have installed, click on the 'Help' menu above, and then on the 'About' option. You should have Python version 3.4.3, Anaconda version 2.3.0 and IPython (also known as Jupyter) notebooks version 3.2.0. \n",
"\n",
"If not, make a note of which versions you have and ask for help on the [installation instruction page](http://www.open.edu/openlearn/learn-to-code-installation)."
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": false
},
"outputs": [],
"source": [
"from pandas import *\n",
"print('Your pandas version is', pandas.__version__)\n",
"\n",
"if 1 / 2 == 0:\n",
" print('Error: you are not running Python 3')\n",
" \n",
"df = DataFrame(data=[[1,2], [2,1]], columns=['x','y'])\n",
"\n",
"%matplotlib inline\n",
"df.plot('x', 'y', kind='scatter')\n",
"\n",
"from scipy.stats import spearmanr\n",
"from pandas.io.wb import download"
]
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.4.3"
}
},
"nbformat": 4,
"nbformat_minor": 0
}