Simulateur_EN_v5.7

Simulateur_EN_v5.7 preview image

1 collaborator

Tags

(This model has yet to be categorized with any tags)
Visible to everyone | Changeable by everyone
Model was written in NetLogo 5.2-RC3 • Viewed 420 times • Downloaded 36 times • Run 0 times
Download the 'Simulateur_EN_v5.7' modelDownload this modelEmbed this model

Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)


WHAT IS IT?

Since the pioneering work Abelson & Bernstein in 1963 (1), several researchers have developed computer programs that simulate the diffusion of ideas or opinions within a population.

This software has been designed from the results of work done by the Public Opinion Research Group (GROP) Quebec (Canada).

This work has focused on modeling the Quebec electorate facing political issues. Surveys have revealed the close relationship among the electorate between the bias level on these issues and the importance of representations underlying the accession of voters to these issues, ie the significance of this adhesion for each of the voters.

The operation of this multi-agent simulator is established on this relationship. It models the transmission in a population of a bipolar view.

The representation strength

In surveys of public opinion issues, one quickly realizes that this is not so much socio-demographic characteristics of respondents that best classify them based on these issues, but rather psychocultural variables describing representations favoring one or the other term of the issue. For example, respondents with high results on the scale of authoritarianism present stronger trends towards converging views with this psychological dimension. Respondents favoring one or the other alternative opinion can thus be characterized by measurement scales describing a set of "basins of attraction" influencing trajectories that can follow the cultural traits which they will be exposed. The integration of these is therefore accomplish through the assimilation and accommodation process (2) which build and consolidate representations supporting the adoption of an opinion. This is not an integration using a strictly cognitive processing but also emotional. The share of affect in the consolidation of an opinion is, in many cases, decisive. Join an opinion is to find a psychological comfort zone, which means to make it congruent with the identity of the individual.

Therefore, it is best suited to talk about the significance of an opinion than simply the ability to evoke representations that an individual can possess. Furthermore, an individual may have acquired, on an issue that few salience, thereby limiting its disposions to this issue . For various reasons, ranging from values to his tastes, tagging all its interest, they might not have developed a rudimentary comprehension on a particular issue. The entourage will play an important role in contributing to the opinion that it will forge over the encounters within their social network. So the interest in the news, feelings of competence or ability representations appear to be strongly related to the expression of opinions.

Polarization

Bipolar opinion fails to appear only as a binary choice, but as a set of ideas more or less pronounced characterizing the position of the individual. The spectrum of positions to moderate extreme, can appear there.

Transmission

We can assume that opinions are usually transmitted from one individual to another by the one who has the highest salience to the transmitted opinion. Individuals with weaker performances on a given subject are also the most likely to frequently change of opinion. We call "centrists" people with such behavior because their ambivalence places them in the center of gravity of opinions bi- or multipolar. Thus, the centrists are showing alternating supported at their electoral intentions, often changing allegiance. But they are not so far "undecided" like are usually qualified respondents in surveys that say "do not know". They express a choice, but it can easily change, as they will receive influences around them.

Significant periods of socialization can significantly change the alignment of political centrists. During the federal election campaign of 2005-2006, we could follow such a transformation of the centrist opinion influenced by the intense socialization period in Quebec that is the New Year season. A large fraction of the centrists then modified their electoral intentions. For these reasons, the centrists have been described by some authors as "butterflies" in reference to their frequent changes of opinion.

It is less common for individuals with a strong influence on a topic to change of opinion. Rather, they will form a group of supporters with structured and fairly similar representations on the said subject. Within the complex system formed by a population facing a given subject, supporters represent plus frozen constituents while centrist correspond to a chaotic zone.

Gradually, as the centrist acquire better performances, they "forge" an opinion, then we assume they are influenced by members of their social network with a stronger influence on this subject.

Individuals assimilate some of the cultural traits of their peers by a contamination process involving a multitude of social interactions. This transmission in a population of polarized opinions unfolds in a non-linear dynamic process. Some individuals will act as meta-influencers leading the adhesion of a large number and arousing unexpected reversals for individuals with less strong opinion. External events will disrupt this release, boosting or slowing the progression.(3)

(1) Abelson, R.P. & Bernstein, A. (1963) A Computer Simulation Model of Community Referendum Controversies, The Public Opinion Quarterly, Vol. 27, No. 1. , pp. 93-122.

(2) Assimilation is defined as the process of integration of a new element in a system without changing the structure; if it follows a change in the structure (ex. recalibration), we say that there is accommodation.

(3) Translation of this text from French to English was done with the help of Google Translate.

HOW IT WORKS

Transmission rules of opinions

Let x and x 'an agent and one of its influencers, the significance being defined by the time t P (x) t and the polarization in M (x) t, z being a random noise factor added and e the inverse of the natural logarithm (ie to base e.):

  1. If M (x) t is of opposite polarity to M (x ') and P t (x') T> P (x) t then:

M(x)t+1 = M(x)t -1 M(x)t+1 = M(x´)t - M(x)t+1 . P(x)t / e . | M(x)t | . P(x´)t + z (Transmission) ou M(x)t+1 = M(x)t+1 + M(x´)t . P(x´)t / e . | M(x)t | . P(x)t + z (Polarisation)

  1. IF P(x´)t > P(x)t then:

M(x)t+1 = M(x´)t - M(x)t+1 . P(x)t / e . | M(x)t | . P(x´)t + z (Transmission) ou M(x)t+1 = M(x)t + M(x´)t . P(x´)t / e . | M(x)t | . P(x)t + z (Polarisation)

  1. Si P(x)t >= | M(x)t+1 | alors P(x)t+1 = P(x)t - ( | M(x)t+1 – M(x)t | / 4 + z )

  2. Si P(x)t < | M(x)t+1 | alors P(x)t+1 = P(x)t + ( | M(x)t+1 – M(x)t | / 4 + z )

HOW TO USE IT

THIS MODEL IS STILL IN DEVELOPMENT

  1. You have to click on the setup button to start de configuration process. It will close all files still open, reset all the counters. Then, it will create the number (default 200) of agents indicates by the sample slider distributing them randomly across de limits (default -28, 28) prescribes by the limits slider. Each agent receives a "meme" value for the polarisation of opinion and a "pre" value for the strength of opinion, associate to the xcor and the ycor respectively. It distributes also the influencers amount the agents. The number (default 5) of influencers for each agent is determined by the influencers slider. You can also active the circle switch to get a circle shape distribution of the agents. You can import a distribution file containing all the value for the agents, meme, pre and influencers. You determine the value of the agents for a particular iteration (tick) using the limit_in input window. If the file contains different class of agents and if you active the "model" switch, the first six ones appears with the following color: blue, magenta, orange, yellow, pink and red, instead of all agents red for the left side and blue for the right side.

  2. If you active the pole_right switch, it will save on a file the agent's percent for the total on the right side and, if the components is switch on it will save also the value for each of the components used at each tick.

  3. Using the noise slider ou can adjust the statistical noise affecting the value of the transmission from agent to agent, representing the effect of intermediate variables causing disturbance. The are other sliders that modify the values after a transmission: the effect slider will decrease the value "pre" causing the the distribution to be less higher; the base slider will concentrate around the origin the distribution of values; the squeeze slider will squeeze the width of the distribution.

  4. You can change the rule from transmission to polarisation if the no-polarize switch is off.

  5. The switch Donetwork is activate during the setup. You can stop the creation of networks by changing its value to off. You can also set on the Autonets switch allowing the creation of networks until the value of the Xsamplenets is reach (the range of networks depends on the size of the sample and the number of influencers for each agent. You can monitored the theoretical maximum of networks and the obtained number on the monitors provided.When the creation of networks stop the links showed disappear. But if you want you can hide the links with the Hide_links switch.

  6. Pressing the Go button will start the simulation. If the nb_ticks input windows contains a number greater than 499 or equal to 0, the simulation will continue until you press again on the Go button. But if you enter a number between those two limits, the simulation will stop when the number of ticks will reach the the value entered. You can also activate the majority switch and then the simulation stops when the percentage of agents in the right side pass over 50%.

  7. You can simulate an event perturbing the transmission process. You select the boundaries of the subset of agents you choose with the eventleft and eventright and pretop and prebottom sliders. You opt to move at left (-) or at right (+) with the move slider, the "pre" value being automatically adjust or changing with the move strength slider. To create just one event, just press on the Startevent button before starting the simulation for moving the choosen agents, then toggle off the Startevent button. Although you can let active the Start_event when the simulation goes on.

  8. There are 8 others monitors: "Percentage of agents inversion" give the cumulative inversion of agents from on side to the other. You can reset it with the button labelled "Reinitialize". The 7 other monitors under the plot windows give the total percentage of agents in the right side, as well as the percentage in the right side of agents for the six different class.

  9. Finally, the plot windows gives the graphic of total agents in the right side at each tick. It redraws the plot after 500 ticks.

THINGS TO NOTICE

(suggested things for the user to notice while running the model)

THINGS TO TRY

(suggested things for the user to try to do (move sliders, switches, etc.) with the model)

EXTENDING THE MODEL

(suggested things to add or change in the Code tab to make the model more complicated, detailed, accurate, etc.)

NETLOGO FEATURES

(interesting or unusual features of NetLogo that the model uses, particularly in the Code tab; or where workarounds were needed for missing features)

RELATED MODELS

(models in the NetLogo Models Library and elsewhere which are of related interest)

CREDITS AND REFERENCES

This model was first developed using Visual Basic version 5. It's now adapted for the Netlogo environment. Pierre-Alain Cotnoir owns a doctorate in Comparative Psychology and works as an analyst for public opinion enquiries. You can join him at pac@cam.org

Comments and Questions

Please start the discussion about this model! (You'll first need to log in.)

Click to Run Model

extensions [sound]

turtles-own [meme
             pre
             infl_list
             ]

globals [nb
         rn
         co      
         nets               
         meme_2
         meme_R                
         pre_R
         host         
         change
         pole       
         total
         percentage
         p_class1
         p_class2
         p_class3
         p_class4
         p_class5
         p_class6
         in_data
         iteration                           
         file-data
         list_data      
         percent
         autolink
         Dif
         TermMoins
         TermPlus                          
         u1
         u2
         w1
         w2
         s
         z
         ]

to randomize  ;; générer des variables aléatoires normalisées
  set u1 random-float 1
  set u2 random-float 1
  set w1 (2 * u1 - 1)
  set w2 (2 * u2 - 1)
  set s ((w1 ^ 2) + (w2 ^ 2))
  if s <= 1
     [set z (w1 * sqrt(-2 * ln s / s) * random noise / 10)]
end 

to setup
  set out false 
  set majority false
  file-close-all
  clear-all
  if pole_right = true [out_pole set pole true]
  set nb 0  
  ifelse model = false [set Do_network true]
                       [set Do_network false]
  set change 0
  set total 0 
  ask patches [ set pcolor lime]
  draw
  ifelse model = false [setup-turtles]
                       [set-default-shape turtles "person"]
  if circle [layout-circle turtles limits / 3
              ask turtles [set color yellow
                           set meme xcor
                           set pre ycor]]
 if model = false [ask turtles [ifelse meme < 0 [set color red] [set color blue]]] 
  reset-ticks
end 

to draw  ;; dessiner les axes
  ask patches [if pxcor = 0 and pxcor <= 30 [set pcolor gray]
               if pycor = 0 and pycor <= 30 [set pcolor gray]]
  
 
  ask patch  -5  0 [set pcolor violet]
  ask patch  -10  0 [set pcolor violet]
  ask patch  -15  0 [set pcolor violet]
  ask patch  -20  0 [set pcolor violet]
  ask patch  -25  0 [set pcolor violet]
  ask patch  -30  0 [set pcolor violet]
  ask patch  0  0 [set pcolor violet] 
  ask patch  5  0 [set pcolor violet]
  ask patch  10  0 [set pcolor violet]
  ask patch  15  0 [set pcolor violet]
  ask patch  20  0 [set pcolor violet]
  ask patch  25  0 [set pcolor violet]
  ask patch  30  0 [set pcolor violet]
  ask patch  0  5 [set pcolor violet]
  ask patch  0  10 [set pcolor violet]
  ask patch  0  15 [set pcolor violet]
  ask patch  0  20 [set pcolor violet]
  ask patch  0  25 [set pcolor violet]
  ask patch  0  30 [set pcolor violet]
end 

to strength ;; générer la prégnance initiale en relation avec le niveau de polarisation
   set pre (abs(meme) + log(random-float noise) 2)
   if pre < 0 [set pre random-float 1]
end 

to memetic ;; générer la polarisation des memes à l'intérieur des limites fixées
 set meme random-xcor
 ifelse meme >= 0 [if abs(meme) > limits [set meme random-float limits]]
                 [if abs(meme) > limits [set meme random-float limits * -1]]
 set xcor meme
end 

to setup-turtles  ;; créer les agents
   set-default-shape turtles "person"
   create-turtles sample [memetic
                          strength
                          if model = false [if not circle [setxy meme pre                                                                            
                          ifelse meme < 0 [set color red] [set color blue]]]]
  if model = false [ask turtle 0 [set color magenta]
                         ask turtle 1 [set color yellow]
                         ask turtle 2 [set color orange]
                         ask turtle 3 [set color pink]]
end 

to go 
  set nb 1 
  if out = false and pole_right != true [file-close]
  if pole_right = false [set pole false]
  ask turtles [set co (exp(abs(meme)))
               set host who
               if event_left > event_right [set event_right event_left + 1] ;; faire suivre la limite droite de l'événement en fonction de la limite gauche              
               if Auto_Nets [if autolink >= X_sample_nets * sample * 3 [set Do_Network false ;;envoyer le signal pour l'arrêt de l'auto_nets
                                                                    set Auto_Nets false
                                                                    set out false
                                                                    sound:play-note "CELESTA" 60 64 1]]                                                                                        
               randomize               
               if Do_network [influence]
               set nets round(count links / influencers) 
               if nets >= round(sample * (sample - 1) / influencers) [set out false]                                                                                          
               transmission
               if model = false [ifelse meme < 0 [set color red] [set color blue]]                             
               if out = true and model = true [file-write  who file-write meme file-write pre file-write infl_list]  
               ]
    tick   
    if nb_ticks = ticks [stop]
    if pole = true [set percentage count turtles with [meme > 0]
                    set percentage round(percentage / sample * 100)
                    set p_class1 count turtles with [color = blue and meme > 0]
                    set p_class1 round(p_class1 / count turtles with [color = blue] * 100)
                    set p_class2 count turtles with [color = magenta and meme > 0]
                    set p_class2 round(p_class2 / count turtles with [color = magenta] * 100)
                    set p_class3 count turtles with [color = orange and meme > 0]
                    set p_class3 round(p_class3 / count turtles with [color = orange] * 100)
                    set p_class4 count turtles with [color = yellow and meme > 0]
                    set p_class4 round(p_class4 / count turtles with [color = yellow] * 100)
                    set p_class5 count turtles with [color = pink and meme > 0]
                    set p_class5 round(p_class5 / count turtles with [color = pink] * 100)
                    set p_class6 count turtles with [color = red and meme > 0]
                    set p_class6 round(p_class6 / count turtles with [color = red] * 100)                   
                   ifelse model = true [file-write percentage file-write "; "  file-write p_class1 file-write "; " file-write p_class2 file-write "; " file-write p_class3 file-write "; " file-write p_class4 file-write "; " file-write p_class5 file-write "; "file-print p_class6]
                                          [file-print percentage]]                          
    if majority = true [if count turtles with [meme > 0] / sample * 100 > 50 [stop]]
    set percent (change / total * 100)   
    if Hide_links [ask links [hide-link]]
    set iteration ticks ;;rafraichir le graphique
    if iteration >= 500 [reset-ticks
                         clear-plot]          
end              

to influence  ;; établir les influenceurs pour chaque agent
   set infl_list []
   while [nb <= influencers]
          [set rn random sample 
           while [rn = who]
                 [set rn random sample]
          ifelse in-link-neighbor? turtle rn [set autolink autolink + 1]                                                                                                              
                                             [if length infl_list <= influencers [create-link-from turtle rn]]                                                                                                                                                                                                                                                                                
          set nb nb + 1          
          set infl_list sentence infl_list (list rn)
          if nb > influencers [if out [file-write  who file-write meme file-write pre file-write infl_list]]
          ]                 
end 

to transmission  ;; procéder à la transmission mémétique                                         
   ask in-link-neighbors [set total total + 1                                                  
                          if [pre] of self > [pre] of myself  
                                            [set meme_R ([meme] of self)                                                                                                                                                              
                                             set pre_R ([pre] of self)                                                                                                               
                                             ifelse (([meme] of self < 0 and [meme] of myself > 0) or ([meme] of self > 0 and [meme] of myself < 0))
                                                    [set meme_2 [meme] of myself * -1
                                                     set change change + 1 ]                                                                                                          
                                                    [set meme_2 [meme] of myself]
                                             ifelse no-polarize 
                                                    [if pre_R > [pre] of myself  [set meme_2 (meme_2 + (meme_R * pre_R / co * [pre] of myself) + z * noise) / base]] 
                                                    [if pre_R > [pre] of myself  [set meme_2 (meme_R - ([meme] of myself * [pre] of myself / co * pre_R) + z * noise) / base]]                                           
                                             ifelse meme_2 >= 0 [if abs(meme_2) >= limits [set meme_2 (limits - random-float noise)]]
                                                                [if abs(meme_2) >= limits [set meme_2 (limits - random-float noise) * -1]]                                                                                         
                                     ask turtle host [pregnance
                                     set meme meme_2                                                              
                                     set xcor meme                                      
                                     if pre > limits [set pre limits]
                                     set ycor pre                                  
                                     ]
                                                                                                                         
                         ]]                                            
end 

to pregnance ;; calculer la prégnance après la transmission mémétique
  randomize  
  Set Dif (abs(meme_2 - meme)) / squeeze  
  Set TermMoins (pre - Dif + z) / base
  Set TermPlus (pre + Dif + z) / base
  ifelse pre >= abs(meme_2) - effect
     [if TermMoins >= 0 and TermMoins <= limits [set pre TermMoins]]
     [if TermPlus >= 0 and TermPlus <= limits [set pre TermPlus]]
  if pre <= 0 [set pre random-float noise] 
end 

to event ;; produire un événement
  ask turtles [if meme > event_left and  meme < event_right and pre < pre_top and pre > pre_bottom [set meme_2 meme
                                                              set meme_2 meme_2 + Move
                                                              ifelse meme_2 >= 0 [if abs(meme_2) >= limits [set meme_2 (limits - random-float noise)]]
                                                                                 [if abs(meme_2) >= limits [set meme_2 (limits - random-float noise) * -1]]            
                                                              ifelse Move_strength = 0 [pregnance]
                                                                     [set pre Move_strength + log(random-float noise) 2]
                                                                      
                                                              set meme meme_2                                                            
                                                              setxy meme pre]
               ]
end 

to out_file
  file-close
  set file-data user-new-file
    if is-string? file-data
  [ 
    if file-exists? file-data
      [file-delete file-data]
    file-open file-data   
  ]
if pole_right = false [set out true]
end 

to in_file  
  set file-data user-file
  if (file-data != false)
  [
    set list_data []
   file-open file-data
   while [not file-at-end?]
         [set list_data sentence list_data (list (list file-read file-read file-read file-read)) ]
   user-message "File loading complete!"
   file-close
  ]
  clear-turtles
  set in_data 1
  create-turtles sample
   ifelse (is-list? list_data) [foreach list_data [ask turtle first ? [if in_data <= (limit_in * sample) + 1  [set meme item 1 ?                                                 
                                                                                                               set pre item 2 ?
                                                                                                               set infl_list last ?                                                 
                                                                                                               foreach infl_list [create-link-from turtle ?] 
                                                                                                               ask links [hide-link]
                                                                                                               setxy meme pre
                                                                                                               ifelse model = false [ifelse meme < 0 [set color red] [set color blue]]
                                                                                                                                         [if who <= 50 [set color blue]
                                                                                                                                          if who > 50 and who <= 111 [set color magenta]
                                                                                                                                          if who > 111 and who <= 136 [set color orange]
                                                                                                                                          if who > 136 and who <= 161 [set color yellow]
                                                                                                                                          if who > 161 and who <= 185 [set color pink]
                                                                                                                                          if who > 185 [set color red]]
                                                                                                               set in_data in_data + 1]]]]
                                                                                                                 
                                                                                
                                [user-message "Error loading"]
if pole_right [out_pole set pole true]
end 

to out_pole   
  file-close
  set file-data user-new-file
    if is-string? file-data
  [ 
    if file-exists? file-data
      [file-delete file-data]
    file-open file-data   
  ]
 ;;set pole true
end 

   

              

There is only one version of this model, created over 10 years ago by Pierre-Alain Cotnoir.

Attached files

File Type Description Last updated
Simulateur_EN_v5.7.png preview Preview for 'Simulateur_EN_v5.7' over 10 years ago, by Pierre-Alain Cotnoir Download

This model does not have any ancestors.

This model does not have any descendants.