You are on page 1of 8

Statistical and computational Methods

1º semester 2022 | Peñalolén Campus.

Homework 3

Xavier Cazor Marambio


jcazor@alumnos.uai.cl

Isabel Donoso Leiva


isabeldonoso@alumnos.uai.cl

Ahmad Armoush
aarmoush@alumnos.uai.cl

Paulo Espinoza Arriagada


paulespin@alumnos.uai.cl

Professor:
PhD.Enrique Canessa

May 12, 2022


1. Introduction:
The following report contains the result of testing an agent-based model through the NETLOGO
program, in which the Bidding Market model that is within the program’s library of examples
was used.
This model is based on 5 fundamental starting variables for the construction of a population
around a market structure, these variables are:

• Distribution: Of the supply and demand. If it is even for the supplies, then each seller
brings more-or-less the same amount of items as the other sellers. If it is concentrated, then
a few of the sellers will bring a lot more products than the rest. This is represented on the
model by the size of arrows in the inner circle (the bigger the size, the more supplies that
seller brought). Once a vendor sells all the things they brought, their arrow turns dark gray.
Similarly, if the demand distribution is even, all buyers will want to purchase about the
same amount of items. If it’s concentrated, then a few of the buyers will want significantly
more products than the other buyers. This is represented on the model by a the size of the
gray contour around the arrows of the outter ring, as they buy the things they want, they
fill the gray shadow arround them. Once they have purchased all the things they want, the
arrow will turn completely gray.

• Amount: In the amount of supply and demand, it is about seeing how it affects the dynamics
of the interaction between buyer and seller.

• Behavior: The behavior in the model can be set in the following ways, it is necessary to
highlight that, the definition of states applies to both buyers and sellers:

– Normal: Buyer cases will buy their willingness to pay by a small amount if they can’t
buy an item, otherwise if they can buy an item
– Desperate: It will increase the price to the extent that it cannot acquire an item
– Random: he behavior of each agent is random
– Mix of all: each buyer will be set to one of the above three behaviors at random.

• Starting-money and Sellers-ignore-full-buyers?: The dynamics of the market is analyzed


considering different initial moneys, as well as it can be alternated if the sellers will consider
complete buyers or not, the latter are characterized because they are buyers who only go
through each of the buyers, since they have satisfied your demand

Statistical and computational methods, PhD in Complex systems engineering, UAI. 1


2. Model Operation and Examples
The model basically works as follows: buyers are in the outer ring and sellers are in the inner
ring, between the two there is the dynamic of buying and selling products in a supply market.
In each replicate, the buyers move counterclockwise and pair up with a seller, where he mainly
checks the sale price and if it is lower than the one he is willing to pay, he will take an item,
visually the line that joins both is It will turn yellow and a luminous star will emerge, otherwise
the line remains blue. Additionally, in the dynamics of the system, the sellers will adjust their
prices based on the behavior of the buyers and likewise, the buyers will modify their expectations
based on the price offered by the buyers. Finally, it is important to understand that the stop
criterion of the model is given until no buyer wants to buy an item, until the money runs out or
until all items are purchased.

Figure 1: Basic representation of the system at the start (left) and at the end (right)

In the previous figures you can see different representations of the system. In each replica and
as buyers purchase items, they get bigger and fill their gray shadow, and if they complete their
demand, they turn dark gray. In the same vein, buyers start with a size based on their offer and
get smaller and darker gray as they sell items.

Statistical and computational methods, PhD in Complex systems engineering, UAI. 2


Figure 2: Representation of the system at the start (left) and at the end (right) with concentrated
supply and demand.

3. Results
The following section shows the results for different variations of the imputs that were explained on
the introduccion. Basically, the problem was addressed in the way each of the model parameters
was described above. Therefore, we will work modifying these parameters and evidencing the
expected dynamics in the result.

3.1. Distribution
The values given on the table are the average over 50 iterations on each case.
We can see that the average sale price doesn’t change regardless of whether the supplies or their

Supply Demand Mean Sale Price StD Sale Price Money used Ticks
Even Even 22.1 0.54 85.5% 348
Concentrated Even 22.2 0.62 84.9% 358
Even Concentrated 22.1 0.43 74.2% 340
Concentrated Concentrated 22.1 0.60 76.7% 353

Table 1: Results over 50 iterations for each distribution of supply and demand

demand is even or concentrated. What does change is the percentage of money used. This might
be because all buyers start with the same amount of money, which means that the few buyers
that have greater demand won’t get to fulfill said demand, while the buyers that have smaller
demand will fulfill it and have left-over money.

3.2. Amount
It can be seen that for the different combinations of supply and demand, the price remains
invariant, only that for the case of demand and low supply, it is evident that less initial money is

Statistical and computational methods, PhD in Complex systems engineering, UAI. 3


consumed.

Supply Demand Mean Sale Price St.D Sale Prices Money Used Ticks
High High 22.4 0.34 83.0 % 345.1
High Low 22.6 0.21 72.2% 339.6
Low Low 22.7 0.67 67.7% 357.3
Low High 23.1 0.93 82.6 % 290.4

Table 2: Results over 50 iterations for each value of supply and demand

3.3. Behaviour
In this part, we will basically analyze for each state of behavior of the seller and buyer, for this
a table is generated with all the possible combinations. It is important, for each state, to see
how the average sale price and its standard deviation behave, as well as to see the amount of
money used and the total number of replicates on average that were executed for each simulation,
according to the criteria. of the sample model Bidding Market.

Seller-Behavior Buyer-behavior Mean Sale Price St.D Sale Prices Mean Ticks Mean Money Using
normal normal 22.3 0.3 345.8 84.2%
normal desperate 35.4 0.9 330.0 92.1%
normal random 5.2 0.4 390.5 34.8%
normal mix of all 14.3 1.4 350.3 67.8%
desperate normal 10.5 0.1 221.7 62.8%
desperate desperate 21.6 0.4 163.3 79.9%
desperate random 4.7 0.2 175.7 31.2%
desperate mix of all 8.3 0.5 228 51.6%
random normal 34.1 0.9 8,149.3 91.6%
random desperate 39.4 1.6 9,519.3 94.1%
random random 5.1 0.2 25,346.0 34.5%
random mix of all 16.5 2.0 11,346 67.5%
mix of all normal 18.7 1.3 1,542.3 83.2%
mix of all desperate 25.5 0.9 340.7 89.4%
mix of all random 5.6 1.3 15,131.0 35.7%
mix of all mix of all 12.4 0.7 11,968.7 66.7%

Table 3: Results over 50 iterations for each value of behaviour seller and buyer

Regarding the results, showed in table 3, in relation to modifying the behavior parameter,
the following could be observed: Indeed, the behavior explains and gives the character of social
science to a market of offers, mainly because when verifying each one of them, different types of
results are obtained. In relation to the above, it is noteworthy to consider that both the buyer and
the seller if their behavior was random, lower average prices were regularly obtained but under a
high number of replicas, this because for both the buyer and the seller it is more expensive and
time consuming to identify your price signal Another interesting point is the desperate behavior,
which denotes the willingness of the buyer and seller to liquidate or acquire their items quickly
and obviously at a high price.

Statistical and computational methods, PhD in Complex systems engineering, UAI. 4


3.4. Starting money, and ignore full buyers condition
In this part, the dynamics is performed based on the starting price of the buyers and also if they
ignore the full buyers.
For this part, runs were made with different initial prices, given that the price range taken by
the model is [0, 500], 50 runs were made with initial values of [100, 200, 300, 400, 500]. with the
condition of ignoring full buyers turned on and also turned off, thus achieving an overall total of
100 separate runs for both cases and for the five initial values mentioned previously.
The data is presented in the order of initial prices, first putting the tables referring to the full
buyers conditions deactivated (that is, they do not ignore full buyers) and then the full buyers
condition activated (that is, they ignore full buyers), The data is presented in summary format,
as an average of the average sale price, an average of the starting money (%) and finally the
standard deviation of the ticks for which the model finds equilibrium.

Results for the condition of ignoring full buyers desactivated:

Starting money = 100


Ignore full buyers = off
Avg sale price (µ) Starting money (µ) Ticks (σ)
13,96 97,67 2,01

Table 4: Results over 50 iterations for starting money = 100, ignore condition off.

Starting money = 200


Ignore full buyers = off
Avg sale price (µ) Starting money (µ) Ticks (σ)
18,21 93,99 1,90

Table 5: Results over 50 iterations for starting money = 200, ignore condition off.

Starting money = 300


Ignore full buyers = off
Avg sale price (µ) Starting money (µ) Ticks (σ)
19,93 92,61 2,89

Table 6: Results over 50 iterations for starting money = 300, ignore condition off.

Starting money = 400


Ignore full buyers = off
Avg sale price (µ) Starting money (µ) Ticks (σ)
21,83 88,94 3,29

Table 7: Results over 50 iterations for starting money = 400, ignore condition off.

Statistical and computational methods, PhD in Complex systems engineering, UAI. 5


Starting money = 500
Ignore full buyers = off
Avg sale price (µ) Starting money (µ) Ticks (σ)
22,29 85,43 3,09

Table 8: Results over 50 iterations for starting money = 500, ignore condition off.

Results for the condition of ignoring full buyers activated:

Starting money = 100


Ignore full buyers = on
Avg sale price (µ) Starting money (µ) Ticks (σ)
14,29 96,52 8,35

Table 9: Results over 50 iterations for starting money = 100, ignore condition on.

Starting money = 200


Ignore full buyers = on
Avg sale price (µ) Starting money (µ) Ticks (σ)
18,17 95,44 18,93

Table 10: Results over 50 iterations for starting money = 200, ignore condition on.

Starting money = 300


Ignore full buyers = on
Avg sale price (µ) Starting money (µ) Ticks (σ)
20,55 91,52 108,5

Table 11: Results over 50 iterations for starting money = 300, ignore condition on.

Starting money = 400


Ignore full buyers = on
Avg sale price (µ) Starting money (µ) Ticks (σ)
21,89 87,72 31,15

Table 12: Results over 50 iterations for starting money = 400, ignore condition on.

Starting money = 500


Ignore full buyers = on
Avg sale price (µ) Starting money (µ) Ticks (σ)
22,65 86,43 45,20

Table 13: Results over 50 iterations for starting money = 500, ignore condition on.

Something that can be seen at a glance is that the number of ticks that the model must make
in the case of ignoring the complete buyers is quite high, compared to when these buyers are not

Statistical and computational methods, PhD in Complex systems engineering, UAI. 6


ignored, on the other hand it can be seen as the amount of initial money increases in a scaled
way the results obtained from the model.

4. Conclusion
After analyzing each one by itself, each one of the available parameters of the supply market
model is consistent with what can be theoretically seen in a bidding market, clearly the initial
money, distribution and quantity of supply and demand, will affect always the price signal between
buyers and sellers. Likewise, it is interesting to see that in an economic problem, the qualitative
or expectation behaviors of each one of the agents have a strong impact, in the simulations it
can be seen that the average prices change drastically when there is a change in the behavior
of the agents. Making a comparison with real life, one might think that in general agents have
a combination of all types of behavior and clearly the price is obviously lower in a competitive
market with dynamic price signals between buyer and seller.
Another point of interest in the results is that in none of the simulations obtained is all
the initial money consumed, this may be due to the fact that since it is a fixed value and
the interaction is dynamic between buyer and seller, a point to analyze it is like appropriately
distributing the amount of initial money in each of the agents, according to their behavior and
dynamics in each of the scenarios.

Statistical and computational methods, PhD in Complex systems engineering, UAI. 7

You might also like