Plot point estimates and standard errors from a PanelEstimate calculation.
Plot point estimates and standard errors from a PanelEstimate calculation.
The plot.PanelEstimate method takes an object returned by the PanelEstimate function and plots the calculated point estimates and standard errors over the specified lead time period. The only mandatory argument is an object of the PanelEstimate class.
## S3 method for class 'PanelEstimate'plot( x, ylab ="Estimated Effect of Treatment", xlab ="Time", main ="Estimated Effects of Treatment Over Time", ylim =NULL, pch =NULL, cex =NULL, confidence.level =NULL, bias.corrected =FALSE,...)
Arguments
x: a PanelEstimate object
ylab: default is "Estimated Effect of Treatment." This is the same argument as the standard argument for plot()
xlab: default is "Time". This is the same argument as the standard argument for plot()
main: default is "Estimated Effects of Treatment Over Time". This is the same argument as the standard argument for plot
ylim: default is NULL. This is the same argument as the standard argument for plot()
pch: default is NULL. This is the same argument as the standard argument for plot()
cex: default is NULL. This is the same argument as the standard argument for plot()
confidence.level: confidence.level Confidence level to be used for confidence interval calculations. Must be numeric between 0 and 1. If NULL, confidence level from PanelEstimate() specification is used.
bias.corrected: logical indicating whether or not bias corrected estimates should be plotted Default is FALSE. This argument only applies for standard errors calculated with the bootstrap.
...: Additional optional arguments to be passed to plot().
Examples
dem.sub <- dem[dem[,"wbcode2"]<=100,]dem.sub.panel <- PanelData(dem.sub,"wbcode2","year","dem","y")# create subset of data for simplicityPM.results <- PanelMatch(panel.data = dem.sub.panel, lag =4, refinement.method ="ps.match", match.missing =TRUE, covs.formula =~ tradewb, size.match =5, qoi ="att", lead =0:4, forbid.treatment.reversal =FALSE)PE.results <- PanelEstimate(sets = PM.results, panel.data = dem.sub.panel, se.method ="unconditional")plot(PE.results)