gravatar

tomhanna-uh

Tom Hanna

Recently Published

Demonstration Project
Demonstration for students of completing semester project in R Studio.
POLS 3316: OLS Regression Part 2
Second lecture on OLS Regression for POLS 3316: Statistics for Political Scientists. Review of part I and interpreting regression results
POLS 3316: Intro to OLS Regression
First lecture on OLS regression from POLS 3316: Statistics for Political Scientists
POLS3316: Lecture 15: Confidence Intervals
Confidence intervals using t- and z-scores. Graphical example of regression plot with confidence interval using ggplot.
GOVT2306: Week of November 6
GOVT 2306 Lecture and discussion slides for week of November 6, 2023
POLS3316: Student's t-test
Lecture for Statistics for Political Scientists, focusing on Student's t-test with review or mentions of Chi square, ANOVA, and z-scores.
GOVT2306: Lecture Slides Week of October 30
Brief overview of regions, political culture, and introduction to Texas Constitution
GOVT2306L Lecture Slides Week of October 30
Lecture slides for week of October 30. Brief overview of Texas regions, political culture and
POLS3316: Lecture 12: Causal Inference and Hypothesis Testing
Basic overview of the role of hypothesis testing in causal inference, a simple Z-Score example. For POLS 3316: Statistics for Political Scientists
October 16 Lecture Slides GOVT 2306
Lecture slides for my GOVT 2306 Class for the week of October 16, 2023
October9_Lectures
Lectures week of October 9 for GOVT2306
test
Testing RPubs publishing and update using the manual technique instead of the IDE.
Problem Set 1 Answers - POLS 3316 Fall 2023
Answers for a problem set where students were asked to use R Studio to produce answers to simple descriptive statistics for some small sequences of numbers.
POLS3316: Probabilities and Frequency Distributions
Lectures from Statistics for Political Scientists. Two part lecture finishing probability and sets, continuing to frequency distributions including a preview of the Central Limit Theorem, Law of Large Numbers, and 68-95-99 rule.
POLS3316: Variable types, Population and Sample, Miscellaneous
Lectures for Statistics for Political Science for two days. Concludes material on probability, covers variable types, sample and population basics, correlation and covariance introduction.
POLS3316: Measures of Dispersion 2
Second lecture on Measures of Dispersion from undergraduate course I am teaching, POLS 3316 Statistics for Political Scientists. Written with Quarto. This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
POLS3316: Introduction to Probability and Set Notation
Lecture introducing basic probability and set notation for undergraduate statistics for political science. Includes brief notes on probability in statistical inference.
Civil Liberties and Civil Rights
Two lectures on civil liberties and civil rights from GOVT2306, United States and Texas Constitution and Politics.
The Bill of Rights and Evolution of Federalism
Lecture slides for introductory American Government college course covering the Bill of Rights and the evolution of federalism starting with the ratification of the 10th Amendment through the New Federalism. Creative Commons License and Author information on final slide
GOVT2306: Federalism Part 1
Lecture on Federalism from US and Texas Constitution and Politics course I am teaching. For demonstration, not guaranteed to be free from errors at this point
POLS3316: Measures of Dispersion
Lecture from undergraduate course I am teaching, POLS 3316 Statistics for Political Scientists. Written with Quarto. This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
Introduction to R
This is an introduction to R and R Studio (Posit) for the undergraduate Statistics for Political Scientists course I am teaching in Fall 2023 at University of Houston. The first version was a long R Markdown file used when I taught in the Summer of 2022. This version has been updated to a self-contained Quarto Presentation. This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
Create a lagged variable conditional on another variable
I have a panel data set of countries that joined an organization at varying dates, denoted by a variable member where 0 is not a member and 1 is a member. I have good theoretical reason to believe that there is a selection effect based on some of my dependent variables of interest. For example, I am interested in the effect of joining on the countries ideology, but I know that those with left wing ideologies to start with are more likely to join. I want to account for this at least in part by taking into account their initial ideology. To do this, I want to create new variables, d in the example, for the existing value of certain variables that I think may have a selection effect, in the example c, during the year prior to joining. For years before they joined, the value of d would simply equal the current year’s actual value of c. For countries that never join, d will also equal c. A simple lag won’t work, because they don’t all join at the same time and because for years prior to joining I want d = c.
Help for Redditor 1/30/23
Dummy Variables Question
Some question as to why we don't use one variable for each category of a binary variable