R Studio Portfolio

Spatial Analysis, Interactive Mapping, and Statistical Modeling in R

This portfolio demonstrates applications of spatial visualization, interactive mapping, logistic regression, interaction effects, and predicted probability modeling using R. Through producing these visualizations, I applied advanced statistical techniques to estimate and interpret relationships between variables across multiple empirical contexts, including spatial electoral patterns and individual-level behavioral outcomes. The analysis extends beyond visualization construction to substantive interpretation of model output, including assessments of statistical significance, marginal effects, interaction terms, and predicted probabilities derived from nonlinear models.

In addition to generating figures, I evaluated how changes in key independent variables alter outcome probabilities, holding other factors constant, and I interpreted these effects in terms of both magnitude and direction. In addition to utilizing published datasets, I complied my own data and produced tables that would be more useful to analysis, seen in the Maryland data. Overall, this work reflects the integration of statistical modeling, visualization, and substantive interpretation to produce grounded conclusions within a variety of datasets.


Section 1: Interactive Geographic Mapping

Visualizing Maryland Voting Patterns

This section demonstrates the skills I learned with how to create statistics and interactive maps using county-level election data. The analysis merges Maryland shapefiles with voter data to visualize Democratic and Republican vote share across counties.


Section 2: Logistic Regression and Interaction Effects

Modeling Simulated Judicial Retirement Data

This section models simulated Supreme Court judicial retirement data using logistic regression and interaction effects. Predicted probabilities and marginal effects are visualized across multiple political and institutional conditions, such as tenure, presidential alignment, and Senate alignment.


Section 3: Predicted Probabilities from Logistic Regression

Modeling the Probability of Affairs

This section models the probability of having an affair using logistic regression. Predicted probabilities are visualized by gender and parental status across years married.