diff --git a/source/rst/functions.md b/source/rst/functions.md index 89422ac5..346cb1b3 100644 --- a/source/rst/functions.md +++ b/source/rst/functions.md @@ -192,8 +192,8 @@ We will break this program into two parts: 1. A user-defined function that generates a list of random variables. 1. The main part of the program that - 1. calls this function to get dat - 1. plots the dat + 1. calls this function to get data + 1. plots the data This is accomplished in the next program diff --git a/source/rst/getting_started.md b/source/rst/getting_started.md index f8fb7537..99632c35 100644 --- a/source/rst/getting_started.md +++ b/source/rst/getting_started.md @@ -20,7 +20,7 @@ single: Python In this lecture, you will learn how to -1. get a Python environment up and runnin +1. get a Python environment up and running 1. execute simple Python commands 1. run a sample program 1. install the code libraries that underpin these lectures @@ -43,7 +43,7 @@ The best such distribution is [Anaconda](https://www.anaconda.com/what-is-anacon Anaconda is -* very popul +* very popular * cross-platform * comprehensive * completely unrelated to the Nicki Minaj song of the same name @@ -126,7 +126,7 @@ Once you have installed Anaconda, you can start the Jupyter notebook. Either -* search for Jupyter in your applications menu, o +* search for Jupyter in your applications menu, or * open up a terminal and type `jupyter notebook` * Windows users should substitute "Anaconda command prompt" for "terminal" in the previous line. @@ -139,7 +139,7 @@ If you use the second option, you will see something like this The output tells us the notebook is running at `http://localhost:8888/` * `localhost` is the name of the local machine -* `8888` refers to [port number](https://en.wikipedia.org/wiki/Port_%28computer_networking%29) 8888 on your compute +* `8888` refers to [port number](https://en.wikipedia.org/wiki/Port_%28computer_networking%29) 8888 on your computer Thus, the Jupyter kernel is listening for Python commands on port 8888 of our local machine. @@ -196,10 +196,10 @@ This means that the effect of typing at the keyboard **depends on which mode you The two modes are 1. Edit mode - * Indicated by a green border around one cell, plus a blinking curso + * Indicated by a green border around one cell, plus a blinking cursor * Whatever you type appears as is in that cell 1. Command mode - * The green border is replaced by a grey (or grey and blue) borde + * The green border is replaced by a grey (or grey and blue) border * Keystrokes are interpreted as commands --- for example, typing b adds a new cell below the current one To switch to diff --git a/source/rst/need_for_speed.md b/source/rst/need_for_speed.md index 414edd2e..953bb0a1 100644 --- a/source/rst/need_for_speed.md +++ b/source/rst/need_for_speed.md @@ -79,7 +79,7 @@ libraries are For us, there's another (relatively new) library that will also be essential for numerical computing: -* Numb +* Numba Over the next few lectures we'll see how to use these libraries. diff --git a/source/rst/numpy.md b/source/rst/numpy.md index 68ac80d3..16dca6e9 100644 --- a/source/rst/numpy.md +++ b/source/rst/numpy.md @@ -74,8 +74,8 @@ NumPy arrays are somewhat like native Python lists, except that The most important of these dtypes are: -* float64: 64 bit floating-point numbe -* int64: 64 bit intege +* float64: 64 bit floating-point number +* int64: 64 bit integer * bool: 8 bit True or False There are also dtypes to represent complex numbers, unsigned integers, etc. diff --git a/source/rst/oop_intro.md b/source/rst/oop_intro.md index 79a53984..e4d9e097 100644 --- a/source/rst/oop_intro.md +++ b/source/rst/oop_intro.md @@ -97,7 +97,7 @@ Consider the following expression Here we are mixing types, and it's unclear to Python whether the user wants to -* convert `'300'` to an integer and then add it to `400`, o +* convert `'300'` to an integer and then add it to `400`, or * convert `400` to string and then concatenate it with `'300'` Some languages might try to guess but Python is *strongly typed* @@ -239,7 +239,7 @@ This includes not just lists, strings, etc., but also less obvious things, such * functions (once they have been read into memory) * modules (ditto) -* files opened for reading or writin +* files opened for reading or writing * integers, etc. Consider, for example, functions. diff --git a/source/rst/pandas.md b/source/rst/pandas.md index 184a9500..c24d87bc 100644 --- a/source/rst/pandas.md +++ b/source/rst/pandas.md @@ -39,7 +39,7 @@ Just as [NumPy](http://www.numpy.org/) provides the basic array data type plus c 1. defines fundamental structures for working with data and 1. endows them with methods that facilitate operations such as - * reading in dat + * reading in data * adjusting indices * working with dates and time series * sorting, grouping, re-ordering and general data munging diff --git a/source/rst/python_advanced_features.md b/source/rst/python_advanced_features.md index 58c060a5..683284fe 100644 --- a/source/rst/python_advanced_features.md +++ b/source/rst/python_advanced_features.md @@ -155,7 +155,7 @@ for line in f: The interpreter just keeps 1. calling `f.__next__()` and binding `line` to the result -1. executing the body of the loo +1. executing the body of the loop This continues until a `StopIteration` error occurs. @@ -800,7 +800,7 @@ var([1]) The advantage is that we can * fail early, as soon as we know there will be a problem -* supply specific information on why a program is failin +* supply specific information on why a program is failing ### Handling Errors During Runtime diff --git a/source/rst/python_oop.md b/source/rst/python_oop.md index 7c8a9f2a..ba60c26b 100644 --- a/source/rst/python_oop.md +++ b/source/rst/python_oop.md @@ -22,7 +22,7 @@ In an earlier lecture, we learned some foundations of object-oriented programmin The objectives of this lecture are -* cover OOP in more dept +* cover OOP in more depth * learn how to build our own objects, specialized to our needs For example, you already know how to @@ -32,14 +32,14 @@ For example, you already know how to So imagine now you want to write a program with consumers, who can -* hold and spend cas +* hold and spend cash * consume goods -* work and earn cas +* work and earn cash A natural solution in Python would be to create consumers as objects with * data, such as cash on hand -* methods, such as `buy` or `work` that affect this dat +* methods, such as `buy` or `work` that affect this data Python makes it easy to do this, by providing you with **class definitions**. @@ -91,7 +91,7 @@ A *class definition* is a blueprint for a particular class of objects (e.g., lis It describes * What kind of data the class stores -* What methods it has for acting on these dat +* What methods it has for acting on these data An *object* or *instance* is a realization of the class, created from the blueprint @@ -363,7 +363,7 @@ k_{t+1} = \frac{s z k_t^{\alpha} + (1 - \delta) k_t}{1 + n} Here * $s$ is an exogenously given saving rate -* $z$ is a productivity paramete +* $z$ is a productivity parameter * $\alpha$ is capital's share of income * $n$ is the population growth rate * $\delta$ is the depreciation rate @@ -564,7 +564,7 @@ plt.show() The next program provides a function that -* takes an instance of `Market` as a paramete +* takes an instance of `Market` as a parameter * computes dead weight loss from the imposition of the tax ```{code-block} python3 diff --git a/source/rst/troubleshooting.md b/source/rst/troubleshooting.md index a8f612e2..16c40782 100644 --- a/source/rst/troubleshooting.md +++ b/source/rst/troubleshooting.md @@ -34,7 +34,7 @@ You also need to keep the external code libraries, such as [QuantEcon.py](https: For this task you can either -* use conda upgrade quantecon on the command line, o +* use conda upgrade quantecon on the command line, or * execute !conda upgrade quantecon within a Jupyter notebook. If your local environment is still not working you can do two things.