/votingStatLearn

https://github.com/Femarleycode/votingStatLearn.git

Primary LanguageJupyter Notebook

Statistical learning - classical models on brexit data

A replication/extension of the Joseph Rowntree Fowndation study into Brexit https://www.jrf.org.uk/political-mindsets/brexit-vote-explained-poverty-low-skills-and-lack-of-opportunities

! Note that this is a work in progress

Results

The results so far are similar to JRF's findings, that the main factors in predicting how somebody voted for Brexit were: age, education level, how they voted in the last election and region.

Untitled Untitled Untitled

  • For the rest of the results, navigate to: "votingStatLearn/notebooks/model.ipynb" and scroll down to the bottom.

Prerequisite - install packages

  • Have at least python 3.10 installed
  • In command line, navigate to this project folder and run: pip install requirements.txt

Running the model

  • Run "notebooks/model.ipynb" in VSCode, or editor of choice.

Data insights

  • Prior to creating a model, it's helpful to do some basic analysis to get a high level view of the data. Run "notebooks/dataInsightsSav.ipynb" to see the initial data insights.