diff --git a/lectures/functions.md b/lectures/functions.md index 993d0765..65b3b2fc 100644 --- a/lectures/functions.md +++ b/lectures/functions.md @@ -74,7 +74,7 @@ str(22) type(22) ``` -The full list of Python built-ins is [here](https://docs.python.org/library/functions.html). +The full list of Python built-ins is [here](https://docs.python.org/3/library/functions.html). ### Third Party Functions diff --git a/lectures/numpy.md b/lectures/numpy.md index 564db8a9..3efbf9fe 100644 --- a/lectures/numpy.md +++ b/lectures/numpy.md @@ -1480,9 +1480,9 @@ But this is inefficient relative to computing `Q` once-off. A better option is to use descriptors. A solution from the [quantecon -library](https://github.com/QuantEcon/QuantEcon.py/tree/master/quantecon) +library](https://github.com/QuantEcon/QuantEcon.py/tree/main/quantecon) using descriptors that behaves as we desire can be found -[here](https://github.com/QuantEcon/QuantEcon.py/blob/master/quantecon/discrete_rv.py). +[here](https://github.com/QuantEcon/QuantEcon.py/blob/main/quantecon/discrete_rv.py). ```{solution-end} ``` @@ -1505,7 +1505,7 @@ Your task is to An example solution is given below. -In essence, we've just taken [this code](https://github.com/QuantEcon/QuantEcon.py/blob/master/quantecon/ecdf.py) +In essence, we've just taken [this code](https://github.com/QuantEcon/QuantEcon.py/blob/main/quantecon/ecdf.py) from QuantEcon and added in a plot method ```{code-cell} python3 diff --git a/lectures/pandas.md b/lectures/pandas.md index b43396c0..875d9c52 100644 --- a/lectures/pandas.md +++ b/lectures/pandas.md @@ -606,7 +606,7 @@ time from the World Bank. The World Bank [collects and organizes data](https://data.worldbank.org/indicator) on a huge range of indicators. -For example, [here's](https://data.worldbank.org/indicator/GC.DOD.TOTL.GD.ZS/countries) some data on government debt as a ratio to GDP. +For example, [here's](https://data.worldbank.org/indicator/GC.DOD.TOTL.GD.ZS) some data on government debt as a ratio to GDP. The next code example fetches the data for you and plots time series for the US and Australia diff --git a/lectures/python_essentials.md b/lectures/python_essentials.md index e3c9dc21..e9b252e3 100644 --- a/lectures/python_essentials.md +++ b/lectures/python_essentials.md @@ -701,7 +701,7 @@ In programming, as in mathematics, the opposite is true reversed would be very hard to read, even if the author told you so on the first page. -In Python, the standard style is set out in [PEP8](https://www.python.org/dev/peps/pep-0008/). +In Python, the standard style is set out in [PEP8](https://peps.python.org/pep-0008/). (Occasionally we'll deviate from PEP8 in these lectures to better match mathematical notation) diff --git a/lectures/writing_good_code.md b/lectures/writing_good_code.md index 153eb741..081f2966 100644 --- a/lectures/writing_good_code.md +++ b/lectures/writing_good_code.md @@ -133,7 +133,7 @@ axes[2].legend(loc='upper left', frameon=True) plt.show() ``` -True, the code more or less follows [PEP8](https://www.python.org/dev/peps/pep-0008/). +True, the code more or less follows [PEP8](https://peps.python.org/pep-0008/). At the same time, it's very poorly structured.