Skip to content

Participatory experiment designed and implemented to be performed in the framework of BiblioLab (Ciència i Acció Ciutadana), a co-created citizen science project with public libraries of Barcelona. It presents a dilemma that studies a common social concern how we behave in front of a situation of rent a house and how our decisions affect the mar…

License

Notifications You must be signed in to change notification settings

CitizenSocialLab/Housing-Dilemma

Repository files navigation

README

CitizenSocialLab: Housing Dilemma

Experiment designed and implemented to be performed in the framework of BiblioLab (Ciència i Acció Ciutadana), a co-created citizen science project with public libraries of Barcelona.

This participatory experiment presents a very common dilemma that studies how we behave in front of a situation of rent a house. The participants (6) have to rent a house in a period of 12 months, they have to decide whether the market price is acceptable or not. Their decisions affect the market and, therefore, to the other participants. This experiment tests different treatments with or without public intervention, with varied endowments and/or initial market prices.

Note: This experiment is performed in groups of 6 participants.

Data

Not available

Derived Scientific Publications

Not available

Configuration

Steps are necessary to get Housing Dilemma install, up and running in the local network.

Creation of the project

Experimental Variables Modify the file vars.py with the experimental settings:

  • INCREMENT = 5 (increment or decrement of price in each month)
  • MUNICIPI = 'Barcelona' (municipality, experimental public space)
  • HOUSING_PRICE = 1000 (rental price per month in the municipality)
  • ENDOWMENTS_EQUAL = [2000, 2000, 2000, 2000, 2000, 2000] (equal endowments for the six partcipants)
  • ENDOWMENTS_UNEQUAL = [1600, 1800, 2000, 2000, 2200, 2400] (unequal endowments for the six partcipants)
  • LIMIT_HIGH = 1300 (upper limit of the rental price per month)
  • LIMIT_LOW = 700 (lower limit of the rental price per month)
  • SUBSIDY = 47.66 (subsidy in case of participant can afford the rental -limit low- )
  • TAX = 9.53 (tax to other participant to finance subsidy)

Database MySQL
Create MySQL database: name_db
Create user database: user_db
Create password database: pass_db

Introduce this information about the database in: /Housing-Dilemma/settings.py

Environment
mkvirtualenv housing

Requirements
pip install -r requirements.txt

MongoDB
mongod --dbpath /.../Housing-Dilemma/ddbb

Load text
File with text and translations: /.../Housing-Dilemma/game/i18n/translations_code.xlsx

python excel_to_mongodb.py code

Run Server
python manage.py runserver localhost:port

Migrations
python manage.py makemigrations
python manage.py migrate

Run project in Local

Step 1: Run MySQL server
Run MySQL: mysql.server start

Step 2: Open terminal tabs and work on the environment

in Tab 1: MongoDB
in Tab 2: MySQL
in Tab 3: Run Application

Work on environment (in each terminal tab): workon housing

Step 3: Run MongoDB (Tab 1)
Run mongodb: mongod --dbpath /.../Housing-Dilemma/ddbb

Step 4: MySQL actions (Tab 2)

Directory: cd /.../Housing-Dilemma/
Database: mysql -u user_db -p (pass_db)

Drop database (if name_db exits): drop database name_db; Create database: create database name_db;
Exit: exit;

Modificate fields of database: python manage.py makemigrations
Refresh database: python manage.py migrate

Step 5: Load texts (Tab 2) Load translations: python excel_to_mongodb.py code

Step 6: Run Server (Tab 3)
Directory: cd /.../Housing-Dilemma/
Runserver: python manage.py runserver localhost:port

Access client

Client application:
http://localhost:port/

Control and Administration:
http://localhost:port/admin

Versions

Version 1.0

License

CitizenSocialLab is licensed under a GNU Affero General Public License

All the contents of Housing Dilemma repository are under the license CC BY-NC-SA license

Contributors

Julián Vicens

Contact

Julian Vicens: [email protected]

About

Participatory experiment designed and implemented to be performed in the framework of BiblioLab (Ciència i Acció Ciutadana), a co-created citizen science project with public libraries of Barcelona. It presents a dilemma that studies a common social concern how we behave in front of a situation of rent a house and how our decisions affect the mar…

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published