R Tutorial 2 Econ 520, Fall 2007
1. Vectors
In R, a variable can hold a vector of numbers. (You can also dene matrices and arrays, as we'll see later on.) This is very handy because we can do a set of operations simultaneously on a large set of numbers. A
Econ 520, Fall 2007 Midterm Review Questions Note: I will not provide solutions to these questions. Some of these questions are drawn from previous years exams. 1. Events M and N are said to be mutually exclusive provided that M N = . Suppose that P (A) >
Final Review Questions Note: Many of these questions are drawn from previous years nals. I will not provide solutions to these questions. The nal will cover material from the entire semester, but with more weight on the second half of the course. 1. Suppo
A Simple Poker Game
There are two players. Each player places $1 into the pot as his ante. Then Player 1 is dealt a single card from a deck consisting of only Aces and Kings, in equal numbers. Player 1 is allowed to look at his card, but Player 2 cannot s
Is Nash Equilibrium a Good Prediction?
Is the Nash equilibrium really a good prediction about what outcome we should expect to see? We can use our in-class Prisoners' Dilemma and Oligopoly games as examples, or guides. If you were the manager of one of th
Mixed Strategies: Minimax/Maximin and Nash Equilibrium
In the preceding lecture we analyzed maximin strategies. A maximin strategy is an assurance strategy: it achieves the best expected payoff a player can possibly assure himself, i.e., its the mixture t
Mixed Strategies: Some Examples, and Maximin Analysis
In the preceding lecture we analyzed the pursuit-and-evasion matches we had played in class. A critical strategic element of a pursuit-and-evasion situation is the need to be unpredictable. Some furthe
Mixed Strategies: Outline of the Lecture
1. Some questions about the winner-take-all match/game we played. 2. Predictions about play in the game (with accumulated winnings, not pay-per-play):
http:/www.u.arizona.edu/~mwalker/RSWPredictions.pdf
3. How did
Exercise Set #9
Part I (Nim) The game Nim is defined as follows. Several rows of matchsticks are laid on the table. There can be any number of rows, and any number of matchsticks in any of the rows. We will analyze only Nim games that have two rows, and w
Exercise Set #8
1. Suppose that Raiffas oil wildcatter can hire a company to do a geological study of the site on which he has oil rights, in order to provide himself with somewhat better information about the sites characteristics. There are two possible
Exercise Set #7
1. A state is considering mandatory drug testing for all state employees. It is known that five percent of the state's population uses drugs, and it is reasonable to assume that state employees are typical of the population as a whole. It
Exercise Set #6
1. When Venus is at the net, Martina can choose to hit the ball either cross-court or down-the-line. Similarly, Venus can guess that the ball will come cross-court or downthe-line and react accordingly. Here is a table giving the probabili
Econ 431 Solution to Problem Set #5
2. Solve the equation ( r, L ) = ( r, R ) i.e., r (1) + (1 r) (-1) = r (-1) + (1 r) (1), which yields r = 1/2, and the value of each side of the equation is zero. 3. Using the spreadsheet youve constructed for this prob
Exercise Set #5
1. Use Excel (or another spreadsheet program) to reproduce the table of Row-player (Pursuer) winning probabilities that appears on page 5 of the lecture notes for Lecture #14. This is much easier than it appears at first. You can create th
Solution to Duttas Exercise #4.2
We want to show that a player has an undominated strategy i.e., that he has some strategy that is not dominated by any other strategy. The way well do this is to suppose that every one of his strategies is dominated by som
Duttas Commons Example in Chapter 7
The example has two features: A common resource its freely available to everyone The resource is exhaustible any use depletes the total available in the future There are two players, labeled i = 1 and i = 2. There are y
Overuse of a Common Resource: A Two-player Example
There are two fishermen who fish a common fishing ground a lake, for example Each can choose either xi = 1 (light fishing; for example, use one boat), or xi = 2 (heavy fishing; for example, use two boats
Name: _
Economics 431 Quiz #5
People, animals, and organizations often find themselves in a situation where each must choose to fight (be tough) or concede (give in). Here are the payoffs for a twoplayer game of this kind, a game of chicken:
Give Up Row G
Name: _
Economics 431 Quiz #5
People, animals, and organizations often find themselves in a situation where each must choose to fight (be tough) or concede (give in). Here are the payoffs for a twoplayer game of this kind, a game of chicken:
Give Up Row G
Name: _
Economics 431 Quiz #2
Amy and Beth are competing sellers. Their price competition can be described by the following game, which is derived from the demand curve Q = 6 p, where p dollars per unit is the lowest price, and where the games payoffs rep
Name: _
Economics 431 Quiz #2
Amy and Beth are competing sellers. Their price competition can be described by the following game, which is derived from the demand curve Q = 6 p, where p dollars per unit is the lowest price, and where the games payoffs rep
Name: _
Economics 431 Quiz #1
Amy and Beth are competing sellers. Their price competition can be described by the following game, which is derived from the demand curve Q = 6 p, where p dollars per unit is the lowest price, and where the games payoffs rep
Name: _
Economics 431 Quiz #1
Amy and Beth are competing sellers. Their price competition can be described by the following game, which is derived from the demand curve Q = 6 p, where p dollars per unit is the lowest price, and where the games payoffs rep
A Thumbnail History of Auctions
Human slave auctions: - Egypt, Greece, Roman empire, Southern U.S. Marriage auctions for brides in Asia Minor: - positive and negative prices! Estate auctions in 16th Century France Art auctions in the Netherlands - descen
Economics 520: Introduction to R, Part 3
Keisuke Hirano
September 19, 2011
1 Random sampling with R
R has extensive facilities for working with random numbers and probability distributions. The
sample command draws samples from a given vector of possible
Economics 520: Introduction to R, Part 2
and R Exercises for HW2
Keisuke Hirano
August 28, 2011
1 Vectors
In R, a variable can hold a vector of values. An easy way to construct a vector is the c command,
which combines or concatenates numbers into a vecto
Economics 520: Introduction to R, Part 1
and Problem Set 1, Due Monday, 8/29/11
Keisuke Hirano
August 17, 2011
1 Installing R
The main web page for the R system is http:/www.r-project.org. From the main R page, you can
download a copy of R by clicking on
Economics 520, Fall 2011
Midterm Review Questions
Note: I will not provide solutions to these questions. Most of these questions are drawn from previous
years exams.
1. Events M and N are said to be mutually exclusive provided that M N = .
Suppose that P