Title: | Pick and Plot Key Opinion Leaders from a Network Given Constraints |
Version: | 0.0.1 |
Description: | Assists researchers in choosing Key Opinion Leaders (KOLs) in a network to help disseminate or encourage adoption of an innovation by other network members. Potential KOL teams are evaluated using the ABCDE framework (Neal et al., 2025 <doi:10.31219/osf.io/3vxy9_v1>). This framework which considers: (1) the team members' Availability, (2) the Breadth of the team's network coverage, (3) the Cost of recruiting a team of a given size, and (4) the Diversity of the team's members, (5) which are pooled into a single Evaluation score. |
License: | GPL-3 |
Encoding: | UTF-8 |
RoxygenNote: | 7.3.1 |
Depends: | R (≥ 2.10) |
Imports: | igraph, methods, utils |
Suggests: | knitr, rmarkdown |
URL: | https://github.com/zpneal/KOLaide |
BugReports: | https://github.com/zpneal/KOLaide/issues |
NeedsCompilation: | no |
Packaged: | 2025-05-02 20:21:05 UTC; zacharyneal |
Author: | Zachary Neal |
Maintainer: | Zachary Neal <zpneal@msu.edu> |
Repository: | CRAN |
Date/Publication: | 2025-05-06 08:50:02 UTC |
Pick key opinion leaders from a network given constraints
Description
Pick key opinion leaders from a network given constraints
Usage
pick_kols(
network,
tosource = TRUE,
goal = "diffusion",
m = 1,
range = c(1, 1),
top = NULL,
include = NULL,
exclude = NULL,
attribute = NULL,
alpha = 0.9,
beta = 0.9,
file = NULL
)
Arguments
network |
a unipartite unweighted network as an adjacency |
tosource |
logical: edges point toward a source of information |
goal |
string: goal for the KOL team (either |
m |
integer: KOL team centrality parameter ( |
range |
vector: a vector of length 2 containing the minimum and maximum number of KOLs on a team |
top |
numeric: restrict scope to the |
include |
vector: names or indices of nodes that must be included on the KOL team |
exclude |
vector: names or indices of nodes that can not be included on the KOL team |
attribute |
string or vector: if |
alpha |
numeric: parameter to control relative weight of breadth and diversity in overall evaluation of KOL teams ( |
beta |
numeric: parameter to control weight of team size in overall evaluation of KOL teams ( |
file |
string: filename to write a sorted list of possible KOL teams as a CSV. |
Details
When seeking to diffuse a piece of information or encourage adoption of a behavior, it is often useful
to recruit the assistance of key opinion leaders (KOL) in a network. pick_kols
facilitates selecting
members of a KOL team by returning a dataframe of possible teams. The selection of a KOL team often depends on
several factors, which this function summarizes as ABCDE:
Availability - The availability of individuals to serve as a KOL. This can be controlled by the
include
andexclude
parameters.Breadth - The fraction of non-KOLs that the KOL team can influence. When
goal=="diffusion"
, breadth is measured as the fraction of non-KOLs that a KOL team can reach inm
steps (i.e., m-reach). Whengoal=="adoption"
, breadth is measured as the fraction of non-KOLs that are directly connected to at leastm
KOLs (i.e., m-contact).Cost - The number of KOLs to be recruited and trained (i.e., team size).
Diversity - The fraction of values of
attribute
represented on the KOL team.Evaluation - Potential KOL teams must be compared and evaluated in a way that balances these considerations.
Evaluating KOL Teams
Potential KOL teams are evaluated on the basis of breadth (B), Cost (C), and (if attribute
is provided), Diversity (D)
using
\frac{B}{C^\beta} \mbox{ or } \frac{B^\alpha D^{1-\alpha}}{C^\beta}
The \alpha
parameter can take values 0.5 < \alpha < 1
and controls the weight placed on breadth relative to diversity.
Smaller values of \alpha
place less weight on breadth and more weight on diversity, while larger values of \alpha
place more weight on breadth and less weight on diversity. The default (\alpha = 0.9
) places the majority of weight on
the breadth of the network that KOL teams cover, while still considering the team's diversity (primarily as a tie-breaker).
The \beta
parameter can take values 0 < \beta < 2
and controls the cost of larger KOL team members. Smaller values of
\beta
imply decreasing marginal costs, while larger values of \beta
imply increasing marginal costs. The default
(\beta = 0.9
) assumes that team members have a slight diminishing marginal cost (i.e. the cost of each additional
team member is slightly smaller than the previous one).
Interpreting Edge Direction
If network
is a directed network, then tosource
controls how the direction of edges is interpreted:
-
tosource = TRUE
(default) - An edge i -> j is interpreted as "i gets information from j" or "i is influenced by j" (i.e., the edge points toward a source of information or influence). This type of data usually results from asking respondents to nominate the people from whom they seek advice. In this case, actors with high in-degree like j are generally better KOLs. -
tosource = FALSE
- An edge i -> j is interpreted as "i sends information to j" or "i influences j" (i.e., the edge points away from a source of information or influence). This type of data usually results from asking respondents to report the people to whom they give advice. In this case, actors with high out-degree like i are generally better KOLs.
Value
A sorted list containing a data frame of possible KOL teams with their characteristics, the network
, m
, goal
, and (optionally) attribute
Examples
network <- igraph::sample_smallworld(1,26,2,.2) #An example network
igraph::V(network)$name <- letters[1:26] #Give the nodes names
igraph::V(network)$gender <- sample(c("M","F"),26,replace=TRUE) #Give the nodes a "gender"
teams <- pick_kols(network, #Find KOL teams in `network`
m = 2,
range = c(2,4), #containing 2-4 members
attribute = "gender", #that are gender diverse
goal = "diffusion") #and can help diffuse information
teams$teams[1:10,] #Look at the top 10 teams
Plot a KOL team in a network
Description
Plot a KOL team in a network
Usage
plot_kols(
KOL,
team = 1,
kol = "red",
reachable = "green",
attribute = TRUE,
...
)
Arguments
KOL |
a KOL object generated by |
team |
numeric: number of team in |
kol |
color to mark KOLs |
reachable |
color to mark nodes reachable by KOLs |
attribute |
boolean: if a node attribute was used to measure KOL team diversity, should nodes be colored accordingly |
... |
arguments passed to |
Value
an igraph plot
Examples
network <- igraph::sample_smallworld(1,26,2,.2) #An example network
teams <- pick_kols(network, m = 2) #Find KOL teams
plot_kols(teams,
vertex.label = NA,
vertex.frame.width = 3)