Skip to content

Commit 7b5b489

Browse files
committed
differences for PR #1103
1 parent 7bc4b10 commit 7b5b489

File tree

6 files changed

+16
-16
lines changed

6 files changed

+16
-16
lines changed

03-matplotlib.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ image = matplotlib.pyplot.imshow(data)
4848
matplotlib.pyplot.show()
4949
```
5050

51-
![](fig/inflammation-01-imshow.svg){alt='Heat map representing the data variable. Each cell is colored by value along a color gradientfrom blue to yellow.'}
51+
![](fig/inflammation-01-imshow.svg){alt='Heat map representing the data variable. Each cell is colored by value along a color gradient from blue to yellow.'}
5252

5353
Each row in the heat map corresponds to a patient in the clinical trial dataset, and each column
5454
corresponds to a day in the dataset. Blue pixels in this heat map represent low values, while
@@ -242,7 +242,7 @@ axes3.set_ylim(numpy.amin(min_data), numpy.amax(min_data) * 1.1)
242242
## Drawing Straight Lines
243243

244244
In the center and right subplots above, we expect all lines to look like step functions because
245-
non-integer value are not realistic for the minimum and maximum values. However, you can see
245+
non-integer values are not realistic for the minimum and maximum values. However, you can see
246246
that the lines are not always vertical or horizontal, and in particular the step function
247247
in the subplot on the right looks slanted. Why is this?
248248

04-lists.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ Since a list can contain any Python variables, it can even contain other lists.
169169
For example, you could represent the products on the shelves of a small grocery shop
170170
as a nested list called `veg`:
171171

172-
![](fig/04_groceries_veg.png){alt='veg is represented as a shelf full of produce. There are three rows of vegetableson the shelf, and each row contains three baskets of vegetables. We can labeleach basket according to the type of vegetable it contains, so the top rowcontains (from left to right) lettuce, lettuce, and peppers.'}
172+
![](fig/04_groceries_veg.png){alt='veg is represented as a shelf full of produce. There are three rows of vegetables on the shelf, and each row contains three baskets of vegetables. We can label each basket according to the type of vegetable it contains, so the top row contains (from left to right) lettuce, lettuce, and peppers.'}
173173

174174
To store the contents of the shelf in a nested list, you write it this way:
175175

@@ -183,7 +183,7 @@ Here are some visual examples of how indexing a list of lists `veg` works. First
183183
you can reference each row on the shelf as a separate list. For example, `veg[2]`
184184
represents the bottom row, which is a list of the baskets in that row.
185185

186-
![](fig/04_groceries_veg0.png){alt='veg is now shown as a list of three rows, with veg\[0\] representing the top row ofthree baskets, veg\[1\] representing the second row, and veg\[2\] representing the bottom row.'}
186+
![](fig/04_groceries_veg0.png){alt='veg is now shown as a list of three rows, with veg\[0\] representing the top row of three baskets, veg\[1\] representing the second row, and veg\[2\] representing the bottom row.'}
187187

188188
Index operations using the image would work like this:
189189

@@ -206,7 +206,7 @@ print(veg[0])
206206
To reference a specific basket on a specific shelf, you use two indexes. The first
207207
index represents the row (from top to bottom) and the second index represents
208208
the specific basket (from left to right).
209-
![](fig/04_groceries_veg00.png){alt='veg is now shown as a two-dimensional grid, with each basket labeled according toits index in the nested list. The first index is the row number and the secondindex is the basket number, so veg\[1\]\[3\] represents the basket on the far rightside of the second row (basket 4 on row 2): zucchini'}
209+
![](fig/04_groceries_veg00.png){alt='veg is now shown as a two-dimensional grid, with each basket labeled according to its index in the nested list. The first index is the row number and the second index is the basket number, so veg\[1\]\[3\] represents the basket on the far right side of the second row (basket 4 on row 2): zucchini'}
210210

211211
```python
212212
print(veg[0][0])

05-loop.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ In the episode about visualizing data,
2323
we wrote Python code that plots values of interest from our first
2424
inflammation dataset (`inflammation-01.csv`), which revealed some suspicious features in it.
2525

26-
![](fig/03-loop_2_0.png){alt="Line graphs showing average, maximum and minimum inflammation across all patients over a 40-dayperiod."}
26+
![](fig/03-loop_2_0.png){alt="Line graphs showing average, maximum and minimum inflammation across all patients over a 40-day period."}
2727

2828
We have a dozen data sets right now and potentially more on the way if Dr. Maverick
2929
can keep up their surprisingly fast clinical trial rate. We want to create plots for all of
@@ -142,7 +142,7 @@ for variable in collection:
142142

143143
Using the odds example above, the loop might look like this:
144144

145-
![](fig/05-loops_image_num.png){alt="Loop variable 'num' being assigned the value of each element in the list odds in turn andthen being printed"}
145+
![](fig/05-loops_image_num.png){alt="Loop variable 'num' being assigned the value of each element in the list odds in turn and then being printed"}
146146

147147
where each number (`num`) in the variable `odds` is looped through and printed one number after
148148
another. The other numbers in the diagram denote which loop cycle the number was printed in (1

06-files.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -93,13 +93,13 @@ inflammation-01.csv
9393
inflammation-02.csv
9494
```
9595

96-
![](fig/03-loop_49_3.png){alt='Output from the second iteration of the for loop. Three line graphs showing the daily average, maximum and minimum inflammation over a 40-day period for all patients in the seconddataset.'}
96+
![](fig/03-loop_49_3.png){alt='Output from the second iteration of the for loop. Three line graphs showing the daily average, maximum and minimum inflammation over a 40-day period for all patients in the second dataset.'}
9797

9898
```output
9999
inflammation-03.csv
100100
```
101101

102-
![](fig/03-loop_49_5.png){alt='Output from the third iteration of the for loop. Three line graphs showing the daily average, maximum and minimum inflammation over a 40-day period for all patients in the thirddataset.'}
102+
![](fig/03-loop_49_5.png){alt='Output from the third iteration of the for loop. Three line graphs showing the daily average, maximum and minimum inflammation over a 40-day period for all patients in the third dataset.'}
103103

104104
The plots generated for the second clinical trial file look very similar to the plots for
105105
the first file: their average plots show similar "noisy" rises and falls; their maxima plots
@@ -111,7 +111,7 @@ the first two datasets, however the minima plot shows that the third dataset min
111111
consistently zero across every day of the trial. If we produce a heat map for the third data file
112112
we see the following:
113113

114-
![](fig/inflammation-03-imshow.svg){alt='Heat map of the third inflammation dataset. Note that there are sporadic zero values throughoutthe entire dataset, and the last patient only has zero values over the 40 day study.'}
114+
![](fig/inflammation-03-imshow.svg){alt='Heat map of the third inflammation dataset. Note that there are sporadic zero values throughout the entire dataset, and the last patient only has zero values over the 40 day study.'}
115115

116116
We can see that there are zero values sporadically distributed across all patients and days of the
117117
clinical trial, suggesting that there were potential issues with data collection throughout the

08-func.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -909,7 +909,7 @@ def numbers(one, two=2, three, four=4):
909909
print(numbers(1, three=3))
910910
```
911911

912-
what do you expect will be printed? What is actually printed?
912+
What do you expect will be printed? What is actually printed?
913913
What rule do you think Python is following?
914914

915915
1. `1234`

md5sum.txt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,12 @@
55
"index.md" "da8fda99fa46f56798dc90573766b75a" "site/built/index.md" "2023-12-14"
66
"episodes/01-intro.md" "0d994b7ac56219852fcaa82bb54e2ee2" "site/built/01-intro.md" "2025-05-07"
77
"episodes/02-numpy.md" "1b9c4000cea628f84024abab49012a06" "site/built/02-numpy.md" "2023-11-07"
8-
"episodes/03-matplotlib.md" "3bb8e6088285f01152e2e24da6f36fbc" "site/built/03-matplotlib.md" "2023-11-07"
9-
"episodes/04-lists.md" "d1768916dafc023eeb2f3838932b6289" "site/built/04-lists.md" "2023-11-07"
10-
"episodes/05-loop.md" "80a7584340db6ec23b0c592d8e9553d2" "site/built/05-loop.md" "2024-08-25"
11-
"episodes/06-files.md" "eda3d2e5ff2a23f37048631427cb4f48" "site/built/06-files.md" "2023-11-07"
8+
"episodes/03-matplotlib.md" "99bc94eda2f04d6b155548295528435a" "site/built/03-matplotlib.md" "2025-05-21"
9+
"episodes/04-lists.md" "d319b00a34dd6e1fb95247496e192de7" "site/built/04-lists.md" "2025-05-21"
10+
"episodes/05-loop.md" "7d7aaff2b87317ca054f1c38c4b1f7cc" "site/built/05-loop.md" "2025-05-21"
11+
"episodes/06-files.md" "37a155be3b1a18f0dc4fec46bba7810f" "site/built/06-files.md" "2025-05-21"
1212
"episodes/07-cond.md" "e2e4b672a3cc52150cc74b4296f16531" "site/built/07-cond.md" "2023-11-17"
13-
"episodes/08-func.md" "c52d2937ad2fc21d3594d0a0c07012cf" "site/built/08-func.md" "2025-05-07"
13+
"episodes/08-func.md" "99ce890dbe4944fd729665b566159d07" "site/built/08-func.md" "2025-05-21"
1414
"episodes/09-errors.md" "9eb44385622246a7b9e5e51ab0057c81" "site/built/09-errors.md" "2023-04-21"
1515
"episodes/10-defensive.md" "ec548cde2f4a5a3b7aa5301cc9bbc2f4" "site/built/10-defensive.md" "2023-11-16"
1616
"episodes/11-debugging.md" "38db92997cae328f8e53a60735c46f97" "site/built/11-debugging.md" "2025-05-07"

0 commit comments

Comments
 (0)