Last active
January 19, 2017 17:01
-
-
Save christophergandrud/56a244b9897fae01b9feff7878b4d947 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Load the Zelig package | |
library(Zelig) | |
# Initialize Zelig5 least squares object | |
z5 <- zls$new() | |
# Estimate ls model | |
z5$zelig(Fertility ~ Education, data = swiss) | |
# Set Education to 5 and 15 | |
z5$setx(Education = 5:15) | |
z5$setx1(Education = 15) | |
# Simulate quantities of interest | |
z5$sim() | |
# Plot quantities of interest | |
z5$graph() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment