Interveners

Interveners preview image

1 collaborator

Default-person Aaron Schecter (Author)

Tags

(This model has yet to be categorized with any tags)
Model group MAM-2015 | Visible to everyone | Changeable by everyone
Model was written in NetLogo 5.2.0 • Viewed 120 times • Downloaded 10 times • Run 0 times
Download the 'Interveners' modelDownload this modelEmbed this model

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


Comments and Questions

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

Click to Run Model

globals [num-adopted num-implementers]
turtles-own [power attitude norm control intent last-attitude last-norm last-control last-intent implementer avg-advice-attitude avg-influence-attitude avg-interveners-influence]
directed-link-breed [advice-ties advice-tie]
directed-link-breed [influencer-ties influencer-tie]
directed-link-breed [intervener-ties intervener-tie]

to setup
  ca
   
  ;; make sure the input number of turtles is integer
  if num-turtles != floor(num-turtles) [set num-turtles floor(num-turtles)]
  
  ;; create turtles and distribute them
  crt num-turtles [
    ;; color turtles blue - not adopted
    set color blue    
    setxy random-xcor random-ycor
    set shape "person"
    
    set size 0.75 ;; this makes it easier to see
    
    ;; set intent levels based on survey data
    let u1 random-float 1
    if u1 < 0.09 [set intent 1]
    if u1 >= 0.09 and u1 < 0.11 [set intent 2]
    if u1 >= 0.11 and u1 < 0.18 [set intent 3]
    if u1 >= 0.18 and u1 < 0.24 [set intent 4]
    if u1 >= 0.24 and u1 < 0.36 [set intent 5]
    if u1 >= 0.36 and u1 < 0.60 [set intent 6]
    if u1 >= 0.60 [set intent 7]
    
    ;; set attitude levels based on survey data
    let u2 random-float 1
    if u2 < 0.002 [set attitude 1]
    if u2 >= 0.002 and u2 < 0.008 [set attitude 2]
    if u2 >= 0.008 and u2 < 0.03 [set attitude 3]
    if u2 >= 0.03 and u2 < 0.1 [set attitude 4]
    if u2 >= 0.1 and u2 < 0.25 [set attitude 5]
    if u2 >= 0.25 and u2 < 0.54 [set attitude 6]
    if u2 >= 0.54 [set attitude 7]
    
    ;; set norm levels based on survey data
    let u3 random-float 1
    if u3 < 0.02 [set norm 1]
    if u3 >= 0.02 and u3 < 0.04 [set norm 2]
    if u3 >= 0.04 and u3 < 0.08 [set norm 3]
    if u3 >= 0.08 and u3 < 0.18 [set norm 4]
    if u3 >= 0.18 and u3 < 0.34 [set norm 5]
    if u3 >= 0.34 and u3 < 0.63 [set norm 6]
    if u3 >= 0.63 [set norm 7]
    
    ;; set control levels based on survey data
    let u4 random-float 1
    if u4 < 0.11 [set control 1]
    if u4 >= 0.11 and u4 < 0.19 [set control 2]
    if u4 >= 0.19 and u4 < 0.27 [set control 3]
    if u4 >= 0.27 and u4 < 0.40 [set control 4]
    if u4 >= 0.40 and u4 < 0.57 [set control 5]
    if u4 >= 0.57 and u4 < 0.80 [set control 6]
    if u4 >= 0.80 [set control 7]
    
    ;; set implementer status based on survey data
    let u5 random-float 1
    ifelse u5 < 0.47 [set implementer true set color green] [set implementer false]
    set num-implementers count turtles with [color = green]
    
    
    
  ]
  
  ask turtles [
    ;; create the two types of ties randomly, according to the density of the original network
    ;; use a poisson distribution to represent a power-law type distribution of degree
    ;; this is done in a separate loop so all ties are possible
    create-advice-ties-to n-of (random-poisson (10.52 * num-turtles / 9799)) other turtles [set color yellow set thickness -0.5]    
    create-influencer-ties-to n-of (random-poisson (2.12 * num-turtles / 9799)) other turtles [set color pink set thickness -0.5]  
  ]
  set num-adopted 0
  
  ;; create interveners who can influence the government agents. these new turtles will exert their influence
  ;; on the other turtles to try to create change
  crt num-interveners [
    set color violet
    set shape "person"
    setxy random-xcor random-ycor
    ;; influencers own a "power variable," which effectively measures their ability to influence someone
    set power 1 + random 6
    ;; they only have ties to potential implementers
    create-intervener-ties-to n-of num-intervener-ties turtles with [color = green]
  ]
  
 
  reset-ticks
end 

to go
  if not any? turtles with [implementer = true and color = green] [stop]
  if ticks > 200 [stop]
  ask turtles [
    ;; create the mean values of their neighbors attitudes; we differentiate between
    ;; advice ties and influencer ties
    
    ;; by initializing this way, the values won't change when turtles update their
    ;; properties
    let advice-attitude []
    ask out-advice-tie-neighbors [set advice-attitude lput attitude advice-attitude]  
    if not empty? advice-attitude [set avg-advice-attitude mean(advice-attitude)] 
    
    
    let influence-attitude []
    ask out-influencer-tie-neighbors [set influence-attitude lput attitude influence-attitude]    
    if not empty? influence-attitude [set avg-influence-attitude mean(influence-attitude)]
    
    ;; save the average influence power of any turtle that is an interventionist
    let interveners-influence []
    ask out-intervener-tie-neighbors [set interveners-influence lput power interveners-influence]    
    if not empty? interveners-influence [set avg-interveners-influence mean(interveners-influence)]
    
    ;; save the current status of beliefs for use later
    set last-attitude attitude
    set last-norm norm
    set last-control control
    set last-intent intent 
  ]
  
  ask turtles [
    ;; if they have not already adopted, adjust their belief systems
    if (color = blue) or (color = green) [
      change-attitude   ;; update attitudes
      change-norm       ;; update normative beliefs
      change-control    ;; update perceived control
      change-intent     ;; update intent
      
      ;; if they have the ability to implement, make change if intent and ability
      ;; are present
      if implementer = true [make-change]  
    ] 
  ]
  
  ;; interventionists can change their influence ties if their target has adopted
  ask turtles with [color = violet] [
    
  ]
  
  set num-adopted count turtles with [color = red]
  tick
end 

to change-attitude
  ;; attitude is positively influenced by norms and perception of control
  ;; this is programmed so that if norms or controls are more than attitude, attitude will increase, and vice-versa
  ;; I divided by 12 so that the max change is 1 unit, and multiplied by a random number so that the increase is further surpressed 
  ;; (change will range from 0 to 1 (plus/minus)
  ;; I also cap the values at 1 to 7
   set attitude (last-attitude + (random-float 1.0) * (norm/control-attitude * (last-norm - last-attitude) + (2 - norm/control-attitude) * (last-control - last-attitude)) / 12)
   if attitude > 7 [set attitude 7]
   if attitude < 1 [set attitude 1]
end 

to change-norm
  ;; norm is positively influenced by attitudes and perception of control
  ;; this is programmed so that if attitudes or controls are more than norms, norms will increase, and vice-versa
  ;; perception of norms is also influenced by the attitudes of those in the advice/influence network. in other words, if people you
  ;; get advice from have a positive attitude, that should positive influence your attitude and vice-versa
  ;; I divided by 24 so that the max change is 1 unit, and multiplied by a random number so that the increase is further surpressed 
  ;; (change will range from 0 to 1 (plus/minus)
  ;; I also cap the values at 1 to 7
   set norm (last-norm + (random-float 1.0) * (control/attitude-norm * (last-attitude - last-norm) + (2 - control/attitude-norm) * (last-control - last-norm) + advice/influence-norm * (avg-advice-attitude - last-norm) + (2 - advice/influence-norm) * (avg-influence-attitude - last-norm)) / 24)
   if norm > 7 [set norm 7]
   if norm < 1 [set norm 1]
end 

to change-control
  ;; perception of control is positively influenced by norms and attitudes
  ;; this is programmed so that if norms or attitudes are more than perceived control, control will increase, and vice-versa
  ;; I divided by 12 so that the max change is 1 unit, and multiplied by a random number so that the increase is further surpressed 
  ;; (change will range from 0 to 1 (plus/minus)
  ;; I also cap the values at 1 to 7
   set control (last-control + (random-float 1.0) * (influencer-control * avg-interveners-influence / 7) + (random-float 1.0) * (attitude/norm-control * (last-attitude - last-control) + (2 - attitude/norm-control) * (last-norm - last-control)) / 12)
   if control > 7 [set control 7]
   if control < 1 [set control 1]
end 

to change-intent
  ;; intent is positively influenced by all of attitudes, norms, and perceived control
  ;; I divided by 18 so that the max change is 1 unit, and multiplied by a random number so that the increase is further surpressed 
  ;; (change will range from 0 to 1 (plus/minus)
  ;; I also cap the values at 1 to 7
   set intent (last-intent + (random-float 1.0) * ((2 - influencer-control) * avg-interveners-influence / 7) + (random-float 1.0) * ( attitude-intent * (last-attitude - last-intent) + norm-intent * (last-norm - last-intent) + (3 - attitude-intent - norm-intent) * (last-control - last-intent)) / 18)
   if intent > 7 [set intent 7]
   if intent < 1 [set intent 1]
end 

to make-change
  ;; to make adoption "hard", I incorporated what effectively functions as a threshold
  ;; in other words, change can only occur if someone perceives themselves to have high control, and have high intent
  ;; then, there is still a random component; the number 0.5 is meant to create randomness
  if control >= control-threshold [
    if intent >= intent-threshold [
      if random-float 1 < 0.5 [set color red]  ;; indicate adoption via changing the color
    ]
  ] 
end 

There are 2 versions of this model.

Uploaded by When Description Download
Aaron Schecter about 4 years ago Commented info tab. Added plot and counter Download this version
Aaron Schecter about 4 years ago Extended model with "interveners," external agents who influence decisions Download this version

Attached files

File Type Description Last updated
AaronSchecter_June1.docx word Project Update 3 about 4 years ago, by Aaron Schecter Download
Interveners.png preview Image about 4 years ago, by Aaron Schecter Download

Parent: Adoption of Health Practices in Rural India

This model does not have any descendants.

Graph of models related to 'Interveners'