Skip to content

Commit

Permalink
synth data
Browse files Browse the repository at this point in the history
  • Loading branch information
grahamstark committed Aug 27, 2024
1 parent 9d4a7d7 commit 08af1b2
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 0 deletions.
24 changes: 24 additions & 0 deletions CITATION.cff
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
cff-version: 1.2.0
title: Scotben - A Tax Benefit Model For Scotland
message: >-
If you use this software, please cite it using the
metadata from this file.
type: software
authors:
- given-names: Graham
family-names: Stark
email: [email protected]
orcid: 'https://orcid.org/0000-0002-4740-8711'
repository-code: 'https://github.com/grahamstark/ScottishTaxBenefitModel.jl/'
abstract: >-
This is a Tax Benefit Model for Scotland. To my knowledge,
this is the first model specifically built for Scotland,
and the first fully Open Source one anywhere. It is
designed to use data from the Family Resources Survey,
possibly augmented by other datasets later on.
keywords:
- microsimulation
- economics
- taxation
- benefits
license: MIT
23 changes: 23 additions & 0 deletions scripts/conjoint-data-quickie,jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
using StatsBase,CSV,DataFrames

cj = CSV.File( "/mnt/data/Northumbria/conjoint/Data and R code/conjointdata.csv") |> DataFrame

100*collect(values(countmap(cj."Ethnicity simplified")))./n
# 77% white

100*collect(values(countmap(cj."Sex")))./n

# 43% M/F

100*collect(values(countmap(cj."vote.last")))./n

# 25% conservative 35% Labour 17% non-voting

# non voter adj
q = 1/(1-((1710+2400+30+810)/n))

q .* 100*collect(values(countmap(cj."vote.last")))./n

# 44.33 Lab 31.76 Con


0 comments on commit 08af1b2

Please sign in to comment.