Skip to content

Commit 58ebf6b

Browse files
committed
Files udpated
1 parent 2e4ae25 commit 58ebf6b

File tree

6 files changed

+129
-188
lines changed

6 files changed

+129
-188
lines changed

Activity01/Activity01.ipynb

Lines changed: 38 additions & 81 deletions
Large diffs are not rendered by default.

Exercise01/Exercise01.ipynb

Lines changed: 0 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,5 @@
11
{
22
"cells": [
3-
{
4-
"cell_type": "markdown",
5-
"metadata": {},
6-
"source": [
7-
"1. Import the numpy package"
8-
]
9-
},
103
{
114
"cell_type": "code",
125
"execution_count": 1,
@@ -16,13 +9,6 @@
169
"import numpy as np"
1710
]
1811
},
19-
{
20-
"cell_type": "markdown",
21-
"metadata": {},
22-
"source": [
23-
"2. create a list of 3 elements."
24-
]
25-
},
2612
{
2713
"cell_type": "code",
2814
"execution_count": 2,
@@ -44,13 +30,6 @@
4430
"list_1"
4531
]
4632
},
47-
{
48-
"cell_type": "markdown",
49-
"metadata": {},
50-
"source": [
51-
"3. convert the list to a numpy array"
52-
]
53-
},
5433
{
5534
"cell_type": "code",
5635
"execution_count": 3,
@@ -72,13 +51,6 @@
7251
"array_1"
7352
]
7453
},
75-
{
76-
"cell_type": "markdown",
77-
"metadata": {},
78-
"source": [
79-
"4. Create an array of floating Numbers"
80-
]
81-
},
8254
{
8355
"cell_type": "code",
8456
"execution_count": 4,
@@ -100,13 +72,6 @@
10072
"a "
10173
]
10274
},
103-
{
104-
"cell_type": "markdown",
105-
"metadata": {},
106-
"source": [
107-
"5. Check the type of both objects"
108-
]
109-
},
11075
{
11176
"cell_type": "code",
11277
"execution_count": 5,
@@ -167,13 +132,6 @@
167132
"type(list_1)"
168133
]
169134
},
170-
{
171-
"cell_type": "markdown",
172-
"metadata": {},
173-
"source": [
174-
"6. load data from a csv into a numpy array"
175-
]
176-
},
177135
{
178136
"cell_type": "code",
179137
"execution_count": 8,
@@ -228,13 +186,6 @@
228186
"source": [
229187
"type(data)"
230188
]
231-
},
232-
{
233-
"cell_type": "code",
234-
"execution_count": null,
235-
"metadata": {},
236-
"outputs": [],
237-
"source": []
238189
}
239190
],
240191
"metadata": {

Exercise02/Exercise02.ipynb

Lines changed: 0 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,5 @@
11
{
22
"cells": [
3-
{
4-
"cell_type": "markdown",
5-
"metadata": {},
6-
"source": [
7-
"1. create an array and a list from exercise 26"
8-
]
9-
},
103
{
114
"cell_type": "code",
125
"execution_count": 1,
@@ -26,13 +19,6 @@
2619
"array_1 = np.array(list_1) "
2720
]
2821
},
29-
{
30-
"cell_type": "markdown",
31-
"metadata": {},
32-
"source": [
33-
"2. concat list_1 with itself."
34-
]
35-
},
3622
{
3723
"cell_type": "code",
3824
"execution_count": 3,
@@ -62,13 +48,6 @@
6248
"list_2"
6349
]
6450
},
65-
{
66-
"cell_type": "markdown",
67-
"metadata": {},
68-
"source": [
69-
"3. concat array_1 with itself"
70-
]
71-
},
7251
{
7352
"cell_type": "code",
7453
"execution_count": 5,
@@ -90,13 +69,6 @@
9069
"array_2"
9170
]
9271
},
93-
{
94-
"cell_type": "markdown",
95-
"metadata": {},
96-
"source": [
97-
"4. Load a csv file and concatinate it with itself."
98-
]
99-
},
10072
{
10173
"cell_type": "code",
10274
"execution_count": 6,
@@ -122,13 +94,6 @@
12294
"data = data.astype('float64')\n",
12395
"data + data"
12496
]
125-
},
126-
{
127-
"cell_type": "code",
128-
"execution_count": null,
129-
"metadata": {},
130-
"outputs": [],
131-
"source": []
13297
}
13398
],
13499
"metadata": {

Exercise16/Exercise16.ipynb

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"cells": [
33
{
44
"cell_type": "code",
5-
"execution_count": 4,
5+
"execution_count": 1,
66
"metadata": {},
77
"outputs": [
88
{
@@ -67,7 +67,7 @@
6767
],
6868
"source": [
6969
"import pandas as pd \n",
70-
"df = pd.read_csv(\"stock.csv\")\n",
70+
"df = pd.read_csv(\"../datasets/stock.csv\")\n",
7171
"df.head()\n",
7272
"print(\"\\nA column is created by assigning it in relation\\n\",'-'*75, sep='')\n",
7373
"df['New'] = df['Price']+df['Price']\n",
@@ -78,7 +78,7 @@
7878
},
7979
{
8080
"cell_type": "code",
81-
"execution_count": 5,
81+
"execution_count": 2,
8282
"metadata": {},
8383
"outputs": [
8484
{
@@ -150,7 +150,7 @@
150150
},
151151
{
152152
"cell_type": "code",
153-
"execution_count": 6,
153+
"execution_count": 3,
154154
"metadata": {},
155155
"outputs": [
156156
{
@@ -220,7 +220,7 @@
220220
},
221221
{
222222
"cell_type": "code",
223-
"execution_count": 7,
223+
"execution_count": 4,
224224
"metadata": {},
225225
"outputs": [
226226
{
@@ -313,7 +313,7 @@
313313
"name": "python",
314314
"nbconvert_exporter": "python",
315315
"pygments_lexer": "ipython3",
316-
"version": "3.7.3"
316+
"version": "3.7.4"
317317
}
318318
},
319319
"nbformat": 4,

Exercise18/Exercise18.ipynb

Lines changed: 45 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"cells": [
33
{
44
"cell_type": "code",
5-
"execution_count": null,
5+
"execution_count": 1,
66
"metadata": {},
77
"outputs": [],
88
"source": [
@@ -11,29 +11,54 @@
1111
},
1212
{
1313
"cell_type": "code",
14-
"execution_count": null,
14+
"execution_count": 2,
1515
"metadata": {},
16-
"outputs": [],
16+
"outputs": [
17+
{
18+
"name": "stdout",
19+
"output_type": "stream",
20+
"text": [
21+
"3\n"
22+
]
23+
}
24+
],
1725
"source": [
1826
"x = np.random.randint(1,10)\n",
1927
"print(x)\n"
2028
]
2129
},
2230
{
2331
"cell_type": "code",
24-
"execution_count": null,
32+
"execution_count": 3,
2533
"metadata": {},
26-
"outputs": [],
34+
"outputs": [
35+
{
36+
"name": "stdout",
37+
"output_type": "stream",
38+
"text": [
39+
"[6]\n"
40+
]
41+
}
42+
],
2743
"source": [
2844
"x = np.random.randint(1,10,size=1)\n",
2945
"print(x)\n"
3046
]
3147
},
3248
{
3349
"cell_type": "code",
34-
"execution_count": null,
50+
"execution_count": 4,
3551
"metadata": {},
36-
"outputs": [],
52+
"outputs": [
53+
{
54+
"name": "stdout",
55+
"output_type": "stream",
56+
"text": [
57+
"[74.65 55.09 98. 92.87 66.13 57.59 93.64 85.92 53.45 52.65 74.01 53.37\n",
58+
" 55.05 70.02 91.54]\n"
59+
]
60+
}
61+
],
3762
"source": [
3863
"x = 50+50*np.random.random(size=15)\n",
3964
"x = x.round(decimals=2)\n",
@@ -42,9 +67,19 @@
4267
},
4368
{
4469
"cell_type": "code",
45-
"execution_count": null,
70+
"execution_count": 5,
4671
"metadata": {},
47-
"outputs": [],
72+
"outputs": [
73+
{
74+
"name": "stdout",
75+
"output_type": "stream",
76+
"text": [
77+
"[[0.77351794 0.60313134 0.18648257]\n",
78+
" [0.19922192 0.87757217 0.44662105]\n",
79+
" [0.01515985 0.74621941 0.0894386 ]]\n"
80+
]
81+
}
82+
],
4883
"source": [
4984
"x = np.random.rand(3,3)\n",
5085
"print(x)\n"
@@ -67,7 +102,7 @@
67102
"name": "python",
68103
"nbconvert_exporter": "python",
69104
"pygments_lexer": "ipython3",
70-
"version": "3.7.3"
105+
"version": "3.7.4"
71106
}
72107
},
73108
"nbformat": 4,

Exercise22/Exercise22.ipynb

Lines changed: 40 additions & 7 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)