The applet requires Java 1.4.1 or higher. It will not run on Windows 95 or Mac OS 8 or 9. Mac users must have OS X 10.2.6 or higher and use a browser that supports Java 1.4. (Safari works, IE does not. Mac OS X comes with Safari. Open Safari and set it as your default web browser under Safari/Preferences/General.) On other operating systems, you may obtain the latest Java plugin from Sun's Java site.
powered by NetLogo
view/download model file: a_monetary_experiment.nlogo
It is an economic simulation, with the aim of modelling the outcomes of the introduction in the economy of two alternative, with respect to the default currency (the EURO), means of payment, and of inspecting the conditions under which they diffuse in the economy.
These new currencies are: Tickets-restaurant and a new currency called EAC, that is the acronym of Elena And Claudio, the names of the two creators of this model.
This is closed world composed of one hundred and fifty agents, four shops and two bars, and we have defined seventeen variables referring to each agent. These variables are:
-credit, debt
-EURO-cash, EAC-cash, ticket-cash
-EURO-spent, EAC-spent and ticket-spent
-EURO-spent-at-bars, EAC-spent-at-bars and ticket-spent-at-bars
-credit-received-in-EURO, credit-received-in-EAC and credit-received-in-ticket
-debt-paid-in-EURO, debt-paid-in-EAC and debt-paid-in-ticket.
The credit and debt variables define the financial situation of each agent, whereas the EURO-cash, EAC-cash and ticket-cash variables define the patrimonial situation (that is, how much money does an agent have).
EURO-spent, EAC-spent and ticket-spent represent the amount, updated and increasing at each tick, in each of the three currencies that each agent has spent to buy goods and services at shops.
EURO-spent-at-bars, EAC-spent-at-bars and ticket-spent-at-bars represent the amount, updated and increasing at each tick, in each of the three currencies that each agent has spent to buy food and drinks at bars.
Credit-received-in-EURO, credit-received-in-EAC and credit-received-in-ticket are the amounts, updated and increasing at each tick, of credit that each agent has received in each of the three currencies.
Debt-paid-in-EURO, debt-paid-in-EAC and debt-paid-in-ticket represent the amount of debt, updated and increasing at each tick, paid by each agent in each of the three currencies.
When the “setup” button is pressed, each agent comes into the world with a casual value of each one of the first and second set of variables (credit, debt, EAC-cash, EURO-cash and ticket-cash).
Then, when the “go” button is pressed, agents move across the world, and carry out the normal economic activities: they go to work, and so each month they receive the salary both in EURO and in Tickets-restaurant, with which they can have their meals in the bars; they receive a small part of their credit and pay a small part of their debt every day; and every day they get new credits as well as new debts; then, they go shopping and buy food, clothes, or whatever they need; finally, they go to bars to have a coffee or to have a meal during the lunch break.
The situations in which there can be “acceptance problems” of the two alternative currencies (i.e. EAC and Tickets-restaurant), concern the collection of receivables and, consequently the payment of debts and the purchases at both shops and bars. Therefore the payments of debts, and the payments for purchases, both at bars and at shops, have to respect some “acceptance constraints”, that identify in the model as the desired (by creditors) percentage of received payments of the debts, the desired (by shops owners) percentage of the due payments for good and services purchased at the shops and the desired (by bars owners) percentage of the due payments for food and drink purchased at the bars, respectively in EURO, EAC and Tickets-restaurant out of the total quantity of the due payments.
Besides pressing the "setup" button and then the "go" button, what is important to know in order to use the model adequately, is written below.
The first set of three sliders represent the percentage of each of the three currencies with which the creditors desire to receive the payment of the debt, out of the total payment due.
The second set of three sliders represent the percentage of each of the three currencies with which the owners of the shops desire to receive the payment of the purchase of goods and services, out of the total payment due.
The last set of three sliders represent the percentage of each of the three currencies with which the owners of the bars desire to receive the payment of the purchase of food and drinks, out of the total payment due.
It is important to notice that the three parameters to insert for each set of sliders, must sum up to one.
Some monitors have been added. They can be divided in five groups:
-the first set of three monitors, those up and put horizontally, represent the average quantity between agents, updated at each tick, of, respectively, the EURO, EAC and Tickets-restaurant cash.
-the second set of three monitors that are called respectively,“EAC-average-in-received-credits”, “EURO-average-in-received-credits” and “ticket-average-in-received-credits”, represent the average amount between the agents, updated at each tick, of the received credits in each one of the three currencies in the system.
-in a specular way, the third set of three monitors called respectively, “EAC-average-in-paid-debts”, “EURO-average-in-paid-debts” and “ticket-average-in-paid-debts”, represent the average amount between agents, updated at each tick, of the paid debts in each one of the three currencies present in the economy.
-the fourth set of three monitors, called respectively “EAC-average-expenditure”, “EURO-average-expenditure” and “ticket-average-expenditure”, represent the average amount between agents, updated and incrementing at each tick, of the expenditure for goods and services at the shops, in each one of the currencies in the economy.
-in a specular way, we have defined the fifth set of three monitors called respectively, “EAC-average-expenditure-at-bars”, “EURO-average-expenditure-at-bars”, “ticket-average-expenditure-at-bars”, which are defined as the average amount between agents, updated and incrementing at each tick, of the expenditure for food and drinks at the bars, in each one of the currencies in the system.
It has been added a graph, for each one set of monitors, for a total of five plots.
What it could be interesting to notice, is that, differently from the trend over time of the average quantity of EURO and Tickets-restaurant in cash, that can be both positive and negative, the trend over time of the average quantity of EAC in cash, can only be negative or at most constant, since agents are provided, randomly and just one-off when the world is set, with EAC; whereas this is not the case of EURO and Tickets-restaurant, with which agents are provided every 30 ticks, as payment of the salary.
The average quantity of EAC, therefore will decrease over time, just because the agents buy goods both at shops and at bars using also the EAC, besides the EURO and the Tickets-restaurant, or will stay constant over time, if the user set, via the sliders, the acceptance of the EAC both by shops and bars equal to zero, because the agents would not be allowed to use EAC for these transactions.
The user can try to set different parameters in each set of sliders (provided that the sum of these parameters is one), and see what happens to the average value of each cash, to the average quantity of each of the three currencies spent at bars or at shops, or to the average amount of debt and credit, respectively paid and received in each one of the three means of payments.
breed [agents agent] breed [shops shop] breed [bars bar] agents-own [credit debt EURO-cash ticket-cash EAC-cash EURO-spent EAC-spent ticket-spent EURO-spent-at-bars EAC-spent-at-bars ticket-spent-at-bars credit-received-in-EURO credit-received-in-EAC credit-received-in-ticket debt-paid-in-EURO debt-paid-in-EAC debt-paid-in-ticket ] globals [total-cash EAC-average EURO-average ticket-average EAC-average-expenditure EURO-average-expenditure ticket-average-expenditure EAC-average-expenditure-at-bars EURO-average-expenditure-at-bars ticket-average-expenditure-at-bars EURO-average-in-received-credits EAC-average-in-received-credits ticket-average-in-received-credits EURO-average-in-paid-debts EAC-average-in-paid-debts ticket-average-in-paid-debts] to setup clear-all setup-agents setup-shops setup-bars setup-credit setup-debt setup-EAC-cash setup-ticket-cash setup-EURO-cash end to setup-agents create-agents 150 ask agents [ setxy random-xcor random-ycor set color green set shape "person"] end to setup-shops create-shops 4 ask shops [ set color blue set shape "house" set label "Shop"] ask turtle 150 [ set xcor 5 set ycor 5] ask turtle 151 [ set xcor 5 set ycor -5] ask turtle 152 [ set xcor -5 set ycor -5] ask turtle 153 [ set xcor -5 set ycor 5] end to setup-bars create-bars 2 ask bars [ set color brown set shape "house" set label "Bar"] ask turtle 155 [ set xcor 15 set ycor 15] ask turtle 154 [ set xcor -15 set ycor -15] end to setup-credit ask agents [ set credit random 45000 + 5000] end to setup-debt ask agents [ set debt random 45000 + 5000] end to setup-EAC-cash ask agents [ set EAC-cash random 12000 + 3000] end to setup-ticket-cash ask agents [ set ticket-cash random 4000 + 1000] end to setup-EURO-cash ask agents [ set EURO-cash random 80000 + 20000] end to go if ticks >= 1000 [stop] move-agents move-EURO-and-ticket-cash move-financial-situation receiving-payments paying-debts buying-goods-to-shops buying-goods-to-bars tick do-plot-1 do-plot-2 do-plot-3 do-plot-4 do-plot-5 end to move-agents ask agents [ right random 360 forward 1] end to move-EURO-and-ticket-cash ask agents [ if remainder ticks 30 = 0 [ set EURO-cash (EURO-cash + random 9000 + 1000) set ticket-cash (ticket-cash + random 70 + 30) ] ] end to move-financial-situation ask agents [ set credit (credit + random 120) set debt (debt + random 120) ] end to receiving-payments ask agents [ let a random-float 0.002 let x desired-percentage-of-EURO-in-received-payments let y desired-percentage-of-EAC-in-received-payments let w desired-percentage-of-ticket-in-received-payments set credit ((1 - a) * credit) set EURO-cash (EURO-cash + credit * a * x) set EAC-cash (EAC-cash + credit * a * y) set ticket-cash (ticket-cash + credit * a * w) set credit-received-in-EURO (credit-received-in-EURO + a * x * credit) set credit-received-in-EAC (credit-received-in-EAC + a * y * credit) set credit-received-in-ticket (credit-received-in-ticket + a * w * credit) ] end to paying-debts ask agents [ set total-cash (EURO-cash + ticket-cash + EAC-cash) let a random-float 0.002 let x desired-percentage-of-EURO-in-received-payments let y desired-percentage-of-EAC-in-received-payments let w desired-percentage-of-ticket-in-received-payments if (x * a * debt <= EURO-cash) and (y * a * debt <= EAC-cash) and (w * a * debt <= ticket-cash) [set debt ((1 - a) * debt) set EURO-cash (EURO-cash - debt * a * x) set debt-paid-in-EURO (debt-paid-in-EURO + debt * a * x) set EAC-cash (EAC-cash - debt * a * y) set debt-paid-in-EAC (debt-paid-in-EAC + debt * a * y) set ticket-cash (ticket-cash - debt * a * w) set debt-paid-in-ticket (debt-paid-in-ticket + debt * a * w)] if (x * a * debt <= EURO-cash) and (y * a * debt <= EAC-cash) and (w * a * debt > ticket-cash) [set debt (debt - (x * a * debt + y * a * debt + ticket-cash)) set EURO-cash (EURO-cash - debt * a * x) set debt-paid-in-EURO (debt-paid-in-EURO + debt * a * x) set EAC-cash (EAC-cash - debt * a * y) set debt-paid-in-EAC (debt-paid-in-EAC + debt * a * y) set debt-paid-in-ticket (debt-paid-in-ticket + ticket-cash) set ticket-cash (ticket-cash - ticket-cash)] if (x * a * debt <= EURO-cash) and (y * a * debt > EAC-cash) and (w * a * debt <= ticket-cash) [set debt (debt - (x * a * debt + w * a * debt + EAC-cash)) set EURO-cash (EURO-CASH - debt * a * x) set debt-paid-in-EURO (debt-paid-in-EURO + debt * a * x) set ticket-cash (ticket-cash - debt * a * w) set debt-paid-in-ticket (debt-paid-in-ticket + debt * a * w) set debt-paid-in-EAC (debt-paid-in-EAC + EAC-cash) set EAC-cash (EAC-cash - EAC-cash)] if (x * a * debt > EURO-cash) and (y * a * debt <= EAC-cash) and (w * a * debt <= ticket-cash) [set debt (debt - (y * a * debt + w * a * debt + EURO-cash)) set debt-paid-in-EURO (debt-paid-in-EURO + EURO-cash) set EURO-cash (EURO-cash - EURO-cash) set ticket-cash (ticket-cash - debt * a * w) set debt-paid-in-ticket (debt-paid-in-ticket + a * w * debt) set EAC-cash (EAC-cash - debt * a * y) set debt-paid-in-EAC (debt-paid-in-EAC + debt * a * y)] if (x * a * debt > EURO-cash) and (y * a * debt > EAC-cash) and (w * a * debt > ticket-cash) [set debt (debt - total-cash) set debt-paid-in-EURO (debt-paid-in-EURO + EURO-cash) set EURO-cash (EURO-cash - EURO-cash) set debt-paid-in-ticket (debt-paid-in-ticket + ticket-cash) set ticket-cash (ticket-cash - ticket-cash) set debt-paid-in-EAC (debt-paid-in-EAC + EAC-cash) set EAC-cash (EAC-cash - EAC-cash)] if (x * a * debt <= EURO-cash) and (y * a * debt > EAC-cash) and (w * a * debt > ticket-cash) [set debt (debt - (x * a * debt + ticket-cash + EAC-cash)) set EURO-cash (EURO-cash - debt * a * x) set debt-paid-in-EURO (debt-paid-in-EURO + debt * a * x) set debt-paid-in-EAC (debt-paid-in-EAC + EAC-cash) set EAC-cash (EAC-cash - EAC-cash) set debt-paid-in-ticket (debt-paid-in-ticket + ticket-cash) set ticket-cash (ticket-cash - ticket-cash)] if (x * a * debt > EURO-cash) and (y * a * debt > EAC-cash) and (w * a * debt <= ticket-cash) [set debt (debt - (w * a * debt + EURO-cash + EAC-cash)) set ticket-cash (ticket-cash - debt * a * w) set debt-paid-in-ticket (debt-paid-in-ticket + a * w * debt) set debt-paid-in-EURO (debt-paid-in-EURO + EURO-cash) set EURO-cash (EURO-cash - EURO-cash) set debt-paid-in-EAC (debt-paid-in-EAC + EAC-cash) set EAC-cash (EAC-cash - EAC-cash)] if (x * a * debt > EURO-cash) and (y * a * debt <= EAC-cash) and (w * a * debt > ticket-cash) [set debt (debt - (y * a * debt + EURO-cash + ticket-cash)) set debt-paid-in-EAC (debt-paid-in-EAC + debt * a * y) set EAC-cash (EAC-cash - debt * a * y) set debt-paid-in-EURO (debt-paid-in-EURO + EURO-cash) set EURO-cash (EURO-cash - EURO-cash) set debt-paid-in-ticket (debt-paid-in-ticket + ticket-cash) set ticket-cash (ticket-cash - ticket-cash)] ] end to buying-goods-to-shops ask agents [ let a random 270 + 30 let x desired-percentage-of-EURO-in-payments-of-goods let y desired-percentage-of-EAC-in-payments-of-goods let w desired-percentage-of-ticket-in-payments-of-goods if any? shops in-radius 6 [ if (x * a <= EURO-cash) and (y * a <= EAC-cash) and (w * a <= ticket-cash) [set EURO-cash (EURO-cash - x * a) set EURO-spent (EURO-spent + x * a) set EAC-cash (EAC-cash - y * a) set EAC-spent (EAC-spent + y * a) set ticket-cash (ticket-cash - w * a) set ticket-spent (ticket-spent + w * a)] if (x * a <= EURO-cash) and (y * a <= EAC-cash) and (w * a > ticket-cash) [set EURO-cash (EURO-cash - x * a) set EURO-spent (EURO-spent + x * a) set EAC-cash (EAC-cash - y * a) set EAC-spent (EAC-spent + y * a) set ticket-spent (ticket-spent + ticket-cash) set ticket-cash (ticket-cash - ticket-cash)] if (x * a <= EURO-cash) and (y * a > EAC-cash) and (w * a <= ticket-cash) [set EURO-cash (EURO-cash - a * x) set EURO-spent (EURO-spent + a * x) set ticket-cash (ticket-cash - a * w) set ticket-spent (ticket-spent + a * w) set EAC-spent (EAC-spent + EAC-cash) set EAC-cash (EAC-cash - EAC-cash)] if (x * a > EURO-cash) and (y * a <= EAC-cash) and (w * a <= ticket-cash) [set EURO-spent (EURO-spent + EURO-cash) set EURO-cash (EURO-cash - EURO-cash) set ticket-cash (ticket-cash - a * w) set ticket-spent (ticket-spent + a * w) set EAC-cash (EAC-cash - a * y) set EAC-spent (EAC-spent + a * y)] if (x * a > EURO-cash) and (y * a > EAC-cash) and (w * a > ticket-cash) [set EURO-spent (EURO-spent + EURO-cash) set EURO-cash (EURO-cash - EURO-cash) set ticket-spent (ticket-spent + ticket-cash) set ticket-cash (ticket-cash - ticket-cash) set EAC-spent (EAC-spent + EAC-cash) set EAC-cash (EAC-cash - EAC-cash)] if (x * a <= EURO-cash) and (y * a > EAC-cash) and (w * a > ticket-cash) [set EURO-cash (EURO-cash - a * x) set EURO-spent (EURO-spent + a * x) set EAC-spent (EAC-spent + EAC-cash) set EAC-cash (EAC-cash - EAC-cash) set ticket-spent (ticket-spent + ticket-cash) set ticket-cash (ticket-cash - ticket-cash)] if (x * a > EURO-cash) and (y * a > EAC-cash) and (w * a <= ticket-cash) [set ticket-cash (ticket-cash - a * w) set ticket-spent (ticket-spent + a * w) set EURO-spent (EURO-spent + EURO-cash) set EURO-cash (EURO-cash - EURO-cash) set EAC-spent (EAC-spent + EAC-cash) set EAC-cash (EAC-cash - EAC-cash)] if (x * a > EURO-cash) and (y * a <= EAC-cash) and (w * a > ticket-cash) [set EAC-cash (EAC-cash - a * y) set EAC-spent (EAC-spent + a * y) set EURO-spent (EURO-spent + EURO-cash) set EURO-cash (EURO-cash - EURO-cash) set ticket-spent (ticket-spent + ticket-cash) set ticket-cash (ticket-cash - ticket-cash)] ] ] end to buying-goods-to-bars ask agents [ let a random 15 + 5 let x desired-percentage-of-EURO-in-payments-to-bars let y desired-percentage-of-EAC-in-payments-to-bars let w desired-percentage-of-ticket-in-payments-to-bars if any? bars in-radius 6 [ if (x * a <= EURO-cash) and (y * a <= EAC-cash) and (w * a <= ticket-cash) [set EURO-cash (EURO-cash - x * a) set EURO-spent-at-bars (EURO-spent-at-bars + x * a) set EAC-cash (EAC-cash - y * a) set EAC-spent-at-bars (EAC-spent-at-bars + y * a) set ticket-cash (ticket-cash - w * a) set ticket-spent-at-bars (ticket-spent-at-bars + w * a)] if (x * a <= EURO-cash) and (y * a <= EAC-cash) and (w * a > ticket-cash) [set EURO-cash (EURO-cash - x * a) set EURO-spent-at-bars (EURO-spent-at-bars + x * a) set EAC-cash (EAC-cash - y * a) set EAC-spent-at-bars (EAC-spent-at-bars + y * a) set ticket-spent-at-bars (ticket-spent-at-bars + ticket-cash) set ticket-cash (ticket-cash - ticket-cash)] if (x * a <= EURO-cash) and (y * a > EAC-cash) and (w * a <= ticket-cash) [set EURO-cash (EURO-cash - a * x) set EURO-spent-at-bars (EURO-spent-at-bars + a * x) set ticket-cash (ticket-cash - a * w) set ticket-spent-at-bars (ticket-spent-at-bars + a * w) set EAC-spent-at-bars (EAC-spent-at-bars + EAC-cash) set EAC-cash (EAC-cash - EAC-cash)] if (x * a > EURO-cash) and (y * a <= EAC-cash) and (w * a <= ticket-cash) [set EURO-spent-at-bars (EURO-spent-at-bars + EURO-cash) set EURO-cash (EURO-cash - EURO-cash) set ticket-cash (ticket-cash - a * w) set ticket-spent-at-bars (ticket-spent-at-bars + a * w) set EAC-cash (EAC-cash - a * y) set EAC-spent-at-bars (EAC-spent-at-bars + a * y)] if (x * a > EURO-cash) and (y * a > EAC-cash) and (w * a > ticket-cash) [set EURO-spent-at-bars (EURO-spent-at-bars + EURO-cash) set EURO-cash (EURO-cash - EURO-cash) set ticket-spent-at-bars (ticket-spent-at-bars + ticket-cash) set ticket-cash (ticket-cash - ticket-cash) set EAC-spent-at-bars (EAC-spent-at-bars + EAC-cash) set EAC-cash (EAC-cash - EAC-cash)] if (x * a <= EURO-cash) and (y * a > EAC-cash) and (w * a > ticket-cash) [set EURO-cash (EURO-cash - a * x) set EURO-spent-at-bars (EURO-spent-at-bars + a * x) set EAC-spent-at-bars (EAC-spent-at-bars + EAC-cash) set EAC-cash (EAC-cash - EAC-cash) set ticket-spent-at-bars (ticket-spent-at-bars + ticket-cash) set ticket-cash (ticket-cash - ticket-cash)] if (x * a > EURO-cash) and (y * a > EAC-cash) and (w * a <= ticket-cash) [set ticket-cash (ticket-cash - a * w) set ticket-spent-at-bars (ticket-spent-at-bars + a * w) set EURO-spent-at-bars (EURO-spent-at-bars + EURO-cash) set EURO-cash (EURO-cash - EURO-cash) set EAC-spent-at-bars (EAC-spent-at-bars + EAC-cash) set EAC-cash (EAC-cash - EAC-cash)] if (x * a > EURO-cash) and (y * a <= EAC-cash) and (w * a > ticket-cash) [set EAC-cash (EAC-cash - a * y) set EAC-spent-at-bars (EAC-spent-at-bars + a * y) set EURO-spent-at-bars (EURO-spent-at-bars + EURO-cash) set EURO-cash (EURO-cash - EURO-cash) set ticket-spent-at-bars (ticket-spent-at-bars + ticket-cash) set ticket-cash (ticket-cash - ticket-cash)] ] ] end to do-plot-1 ask agents[ set EAC-average mean [EAC-cash] of agents set EURO-average mean [EURO-cash] of agents / 100 set ticket-average mean [ticket-cash] of agents ] set-current-plot "Average quantities of EURO, EAC, Ticket owned by agents" set-current-plot-pen "EAC-average-in-cash" plot EAC-average set-current-plot-pen "EURO-average-in-cash / 100" plot EURO-average set-current-plot-pen "ticket-average-in-cash" plot ticket-average end to do-plot-2 ask agents [ set EAC-average-expenditure mean [EAC-spent] of agents set EURO-average-expenditure mean [EURO-spent] of agents / 100 set ticket-average-expenditure mean [ticket-spent] of agents ] set-current-plot "Average quantities of EURO, EAC, Ticket spent by agents in buying goods" set-current-plot-pen "EAC-average-expenditure" plot EAC-average-expenditure set-current-plot-pen "EURO-average-expenditure / 100" plot EURO-average-expenditure set-current-plot-pen "ticket-average-expenditure" plot ticket-average-expenditure end to do-plot-3 ask agents [ set EAC-average-expenditure-at-bars mean [EAC-spent-at-bars] of agents set EURO-average-expenditure-at-bars mean [EURO-spent-at-bars] of agents / 100 set ticket-average-expenditure-at-bars mean [ticket-spent-at-bars] of agents ] set-current-plot "Average quantities of EURO, EAC, Ticket spent by agents at bars" set-current-plot-pen "EAC-average-expenditure-at-bars" plot EAC-average-expenditure-at-bars set-current-plot-pen "EURO-average-expenditure-at-bars / 100" plot EURO-average-expenditure-at-bars set-current-plot-pen "ticket-average-expenditure-at-bars" plot ticket-average-expenditure-at-bars end to do-plot-4 ask agents [ set EAC-average-in-received-credits mean [credit-received-in-EAC] of agents set EURO-average-in-received-credits mean [credit-received-in-EURO] of agents / 100 set ticket-average-in-received-credits mean [credit-received-in-ticket] of agents ] set-current-plot "Average quantities of EURO, EAC, Ticket received as payment of credits" set-current-plot-pen "EAC-average-in-received-credits" plot EAC-average-in-received-credits set-current-plot-pen "EURO-average-in-received-credits / 100" plot EURO-average-in-received-credits set-current-plot-pen "ticket-average-in-received-credits" plot ticket-average-in-received-credits end to do-plot-5 ask agents [ set EAC-average-in-paid-debts mean [debt-paid-in-EAC] of agents set EURO-average-in-paid-debts mean [debt-paid-in-EURO] of agents / 100 set ticket-average-in-paid-debts mean [debt-paid-in-ticket] of agents ] set-current-plot "Average quantities of EURO, EAC, Ticket used as payment of debts" set-current-plot-pen "EAC-average-in-paid-debts" plot EAC-average-in-paid-debts set-current-plot-pen "EURO-average-in-paid-debts / 100" plot EURO-average-in-paid-debts set-current-plot-pen "ticket-average-in-paid-debts" plot ticket-average-in-paid-debts end