Hi Everyone,
I just uploaded a revised version of the lecture notes for today's
class to the course website.
Best,
Kevin
------------------------------------------------------
Kevin Quinn
Assistant Professor
Department of Government and
Center for Basic Research in the Social Sciences
34 Kirkland Street
Harvard University
Cambridge, MA 02138
I've been on 2 for a while. Here is what I have so far, with a question
following.
p<-matrix(c(2,1,0,6,2,6,-4,-3,9,),3,3,byrow=TRUE)
> E13<-matrix(c(1,0,0,0,1,0,2,0,1),3,3,byrow=TRUE)
> p2<-E13%*%p
> E12<-matrix(c(1,0,0,-3,1,0,0,0,1),3,3,byrow=TRUE)
> p3<-E12%*%p2
> E21<-matrix(c(1,-1,0,0,1,0,0,0,1),3,3,byrow=TRUE)
> p4<-E21%*%p3
> E21<-matrix(c(.5,0,0,0,1,0,0,0,1),3,3,byrow=TRUE)
> p5<-E21%*%p4
> E23<-matrix(c(1,0,0,0,-1,0,0,0,1),3,3,byrow=TRUE)
> p6<-E23%*%p5
> E13b<-matrix(c(1,0,0,0,1,0,0,1,0),3,3,byrow=TRUE)
> p7<-E13b%*%p6
> p7
[,1] [,2] [,3]
[1,] 1 1 -3
[2,] 0 1 -6
[3,] 0 1 -6
> E23b<-matrix(c(1,0,0,0,1,0,0,-1,1),3,3,byrow=TRUE)
> p8<-E23b%*%p7
> p8
[,1] [,2] [,3]
[1,] 1 1 -3
[2,] 0 1 -6
[3,] 0 0 0
I'm skeptical about the third row but I read beore that a line of zeros is
correct....(?)
Marie
Hi, Sheldon. Let's start by trying to eliminate the leading -4 in the 3rd
row (i.e., make it zero). To do so, we could multiply the first row by 2,
and add it to the third. We want the result of this sum to be positioned
in the 3rd row of our product. Since we want the result in the 3rd row of
the product, we should alter the 3rd row in our elementary matrix. Since
we want to double the first row of the coef. matrix, we should alter the
first column of the elementary matrix (picture the inner product at work
here). Calculate the product of the following elementary matrix and the
coefficient matrix:
1 0 0
0 1 0
2 0 1
This should get you started. If it's not clear, feel free to ask again!
Best,
Ryan
------------------------------------------
Ryan T. Moore ~ Government & Social Policy
Ph.D. Candidate ~ Harvard University
Homepage: http://www.people.fas.harvard.edu/~rtmoore/
Gov1000: http://www.courses.fas.harvard.edu/~gov1000/
On Sun, 14 Nov 2004, Sheldon Marshall Bond wrote:
> Greetings,
> I am seriously struggling with Problem 2. I am lost on where to
> start. I have gone back and forth through the handouts and blume and the
> examples, and I can not get the actual math right on paper. In doing
> elementary matrices, how do I set them up so that I can cancel out
> coefficients? I have tried, and everytime I multiply the matrix by the
> elementary matrix, I move farther away from the Row echelon form.
>
> Regards,
> Sheldon
>
> I'm back up to 2. Left-multiplying by the matrix? This is multiplying
> 4,20, and 3 by the inverse of the 3x3 by the inverse of the coefficients
> on the left side of the equality sign?
That's correct (assuming you just meant one "by the inverse" clause
above). But you're also multiplying the 3x3 coefficient matrix by it's
inverse, too, right?
Ryan
Hi, folks. Given the nature of this week's problem set (PS5), there's no
need to send me a source-able .R file with your code. A hard copy of your
R checks of your work will certainly be sufficient.
Thanks,
Ryan
------------------------------------------
Ryan T. Moore ~ Government & Social Policy
Ph.D. Candidate ~ Harvard University
Homepage: http://www.people.fas.harvard.edu/~rtmoore/
Gov1000: http://www.courses.fas.harvard.edu/~gov1000/
Hi, everyone. Here are a few notes on the solution sets from PS4; please
read these tips carefully. This was quite a long set, we recognize, but
it is also a very important one. Given this, I'd like to offer a couple
of rewrite possibilities. For those whose rewrites include graphics or a
substantial number of problems, you'll need to hand in hard-copy rewrites
as usual. I'm happy to help people work through these to make them
efficient and successful. For those whose rewrites include only
interpretation of a set of coefficients (for example), where you've
otherwise proven your mastery, I'm willing to accept electronic, or in
some cases verbal, "rewrites". Talk to me if you have any questions, or
would like to propose a sensible rewrite strategy, given your unique
circumstances. So as to provide ample time for everyone to keep up, but
still master the concepts and techniques of PS4, I'll allow PS4 rewrite
activity until 1 December. This is a full two and a half weeks from now.
Problem sets will be available from me in CBRSS this weekend (just email
to make sure I'm around), or Monday in lecture. As always, if you have
questions of any kind, just let me know. The notes are also attached in
.txt format.
Best,
Ryan
****************************************
NOTES ON PS4
Generally: Plotting several graphs using par(mfrow()), e.g., is often
helpful, but don't let this technique dominate quality visualization. See
P3, in particular.
Generally: Be sure to detach() a dataset after you attach() it. Not doing
so can lead to serious problems.
Generally: Consider spell-checking.
Generally: Drop the normative language. Low t-statistics are not
"unfortunate", for example.
P3. R^2: What does "accounted for" or "explains" mean? Think hard about
this (often-abused) concept.
P3. Be careful about causal interpretations of regression coefficients.
It's much safer to speak in terms of conditional expectation. Usually,
when presented with the clear choice, as in P7, people seemed to realize
this.
P3. Probably the most common error on the problem set -- be sure to
include substantive interpretation of the values of the slope, intercept,
and SE of the regression in X,Y units.
P4. Key for the algebraic portion is the RELATIVE sizes of sum(x_i^2) and
sum(x_i - mean(x))^2, not just size of numerator or denominator.
Graphical explanation is central as well. Be sure when you do want to
isolate the effect of a quantity, you change *only* that quantity. In
this case, hold mean(y), SDx, and SDy constant, only increase mean(x).
P5. Algebraic discussions were good here, but graphically, in order to
make the point, you need to hold SDy constant, too. Otherwise, we can't
tell that it's SDx increasing the precision.
P7b. I awarded full credit here for correct calculations and no false
statements. However, what does "95% confidence" really mean? Consider
calculating the statistic over repeated samples.
P7c. Be sure you are clear on what a p-value is and is not.
------------------------------------------
Ryan T. Moore ~ Government & Social Policy
Ph.D. Candidate ~ Harvard University
Homepage: http://www.people.fas.harvard.edu/~rtmoore/
Gov1000: http://www.courses.fas.harvard.edu/~gov1000/
Hi Everyone,
It sounds like there is some confusion regarding what we are looking
for on Problem 3.d of this week's problem set. Here is another
(hopefully more clear) way to state what we are looking for:
Problem 3.d
What is the value of x that minimizes the function g(x) = (x-y)'Z(x-y)
where x,y \in \real^k and Z is a k \times k positive definite,
symmetric matrix? Use the rules for calculating gradients and Hessians
of quadratic forms in Appendix C of Fox (1997). Show your work. Your
answer should apply to any values of y and Z subject to the constraint
that Z is positive definite and symmetric.
Hope this helps.
Best,
Kevin
------------------------------------------------------
Kevin Quinn
Assistant Professor
Department of Government and
Center for Basic Research in the Social Sciences
34 Kirkland Street
Harvard University
Cambridge, MA 02138
Hi all,
Are we supposed to check our work for number 3 in R? If so, I am not sure
how to enter the variables into R and have R take their derivatives.....
or is there a way to just solve for the final step (the optimal point)?
Thanks!
Best,
Becky
A couple of people have asked when the final paper is due. It is due
on the last day of class (Dec. 20) before lecture.
Hope this helps clarify things.
Best,
Kevin
------------------------------------------------------
Kevin Quinn
Assistant Professor
Department of Government and
Center for Basic Research in the Social Sciences
34 Kirkland Street
Harvard University
Cambridge, MA 02138