swerik-project / riksdagen-persons

A repository for metadata on politicians who participate in the Riksdag.
0 stars 1 forks source link

Improve handling of seats #23

Open MansMeg opened 1 month ago

MansMeg commented 1 month ago

Below is a problem identified by Jan Teorell.

We should try to solve this issue. I suggest the following steps:

corrected-seats-party-data7176.csv From Jan:

Hi Bob, thanks for sending this and sorry for the late reply (I’ve been traveling). I had to find another workaround for the problem with seat allocation by party for the 1971-1975/76 period, please find it attached. The “p” variable is my shorthand for the five parties at the time in alphabetical order (so 1=C, 2=FP, 3=M, 4=S and 5=VPK). This perfectly replicates seat shares by party each parliamentary year, BUT, as you can also see, there are quite a few switches of seats between MPs (and hence parties) from year to year.

If you merge this by seat number and parliamentary year to your MP data, for example at the start of each parliamentary year, you will see the discrepancies – and, hence, errors, in the seat number allocation in your MP data.

As I’ve noted before, this reallocation of seats (within electoral districts) each parliamentary year was going on throughout the whole of the Tvåkammarriksdag as well, so if your merge of seat numbers is based on the assumption that seats were allocated after elections and then fixed throughout each parliamentary period (which your data for 1971-1975/76 seems to suggest), I suggest you redo the matching of MPs to seat numbers anew with this in mind.

The sources for the data I am attaching is in almost every case the “matrikel” (or actually Joe’s scraped version of that from the Riksdag’s website), but actually I found an error there too and had to look up the seat number by checking the voteringsprotokoll.

Jan

P.S. We also have other problems with the MP data for the Enkammarriksdag, mostly love seats but also some MPs with missing data and a few seats with a missing MP, we will get back to you on those in due course. D.S.

potmo commented 3 weeks ago

Hi I'm doing a separate project (see https://github.com/orgs/swerik-project/discussions/29 for a small introduction). In the data I've collected from roll call records of AK 1957-1966 and FK 1957-1959 I have also seen some seating movements. A lot of the times these movements seems to be due to changing speakers and sometimes due to a MP being replaced. It seems like these changes are more common later than in the 50s and 60s. I have a manually checked list of seat numberings (and votes) for all MPs for the above mentioned periods of you want to cross reference and check. My MP ids are are not Swerik- or Rikdsags-ids so that has to be normalised and referenced first though unfortunately.

MansMeg commented 2 weeks ago

This is excellent @potmo ! We can do this. But if you want, feel free to do the crosscheck and contribute to the database using a pull request. That will speed this up since we are currently busy with other stuff right now. We would be happy to help you do this if you want.