Starting-time Drift Diffusion Model (stDDM)
The relative starting time drift diffusion model (stDDM) characterizes the contributions of multiple unique attributes to the rate of evidence accumulation. Compared to the DDM, which assumes a constant evidence accumulation rate within each trial, the stDDM allows different attributes to enter the evidence accumulation process at various time points relative to one another. By doing so, the stDDM quantifies both the weights given to each attribute and their onset times (Amasino et al., 2019; Barakchian et al., 2021; Chen et al., 2022; Maier et al., 2020; Sullivan and Huettel, 2021).
Example
In this example, we will demonstrate how to use the stDDM in a generic two-alternative forced-choice task with two arbitrary attributes.
Load Packages
The first step is to load the required packages.
using SequentialSamplingModels
using Plots
using Random
Random.seed!(8741)
Random.TaskLocalRNG()
Create Model Object
In the code below, we will define parameters for the stDDM and create a model object to store the parameter values.
Drift Rate
The drift rate controls the speed and direction in which information accumulates. Here, each drift coefficient indicates the weighting strengths given to the first and second attributes (e.g., taste and health, payoff and delay, self and other), respectively, to the total drift rate in a given trial, where the drift rate accumulates relative evidence in favor of an option.
ν = [2.5,2.0]
2-element Vector{Float64}:
2.5
2.0
Diffusion Noise
Diffusion noise is the amount of within trial noise in the evidence accumulation process.
σ = 1.0
1.0
starting time
The starting time parameter $s$ denotes how much earlier one attribute begins to affect the evidence accumulation process relative to the other(s). If $s$ is negative, attribute 1 evidence is accumulated before attribute 2 evidence; if $s$ is positive, attribute 1 evidence is accumulated after attribute 2 evidence. The absolute value of $s$ indicates the difference in starting times for the two attributes.
s = 0.10
0.1
Starting Point
An indicator of an an initial bias towards a decision. The z parameter is relative to a (i.e. it ranges from 0 to 1).
z = 0.50
0.5
Drift Rates Dispersion
Dispersion parameters of the drift rate are drawn from a multivariate normal distribution, with the mean vector ν describing the distribution of actual drift rates from specific trials. The standard deviation or across-trial variability is captured by the η vector, and the corresponding correlation between the two attributes is denoted by ρ.
η = [1.0,1.0]
ρ = 0.3
0.3
Threshold
The threshold α represents the amount of evidence required to make a decision.
α = 1.5
1.5
Non-Decision Time
Non-decision time is an additive constant representing encoding and motor response time.
τ = 0.30
0.3
stDDM Constructor
Now that values have been asigned to the parameters, we will pass them to stDDM
to generate the model object.
dist = stDDM(;ν, σ, s, z, η, ρ, α, τ,)
stDDM
┌───────────┬────────────┐
│ Parameter │ Value │
├───────────┼────────────┤
│ ν │ [2.5, 2.0] │
│ σ │ 1.00 │
│ s │ 0.10 │
│ z │ 0.50 │
│ η │ [1.0, 1.0] │
│ ρ │ 0.30 │
│ α │ 1.50 │
│ τ │ 0.30 │
└───────────┴────────────┘
Simulate Model
Now that the model is defined, we will generate $10,000$ choices and reaction times using rand
.
choices,rts = rand(dist, 10_000)
(choice = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1 … 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], rt = [0.48300000000000015, 0.6230000000000002, 0.7060000000000003, 0.4240000000000001, 0.4120000000000001, 0.4400000000000001, 0.4420000000000001, 0.4260000000000001, 0.4480000000000001, 0.49000000000000016 … 0.4320000000000001, 0.4260000000000001, 0.37400000000000005, 0.5290000000000001, 0.8960000000000005, 0.4560000000000001, 0.4310000000000001, 0.49600000000000016, 0.49500000000000016, 0.5370000000000001])
Compute Choice Probability
The choice probability $\Pr(C=c)$ is computed by passing the model and choice index to cdf
along with a large value for time as the second argument.
cdf(dist, 1, Inf)
0.9769
Plot Simulation
The code below overlays the PDF on reaction time histograms for each option.
histogram(dist)
plot!(dist; t_range=range(.301, 3.0, length=100))
References
Amasino, D.R., Sullivan, N.J., Kranton, R.E. et al. Amount and time exert independent influences on intertemporal choice. Nat Hum Behav 3, 383–392 (2019). https://doi.org/10.1038/s41562-019-0537-2
Barakchian, Z., Beharelle, A.R. & Hare, T.A. Healthy decisions in the cued-attribute food choice paradigm have high test-retest reliability. Sci Rep, (2021). https://doi.org/10.1038/s41598-021-91933-6
Chen, HY., Lombardi, G., Li, SC. et al. Older adults process the probability of winning sooner but weigh it less during lottery decisions. Sci Rep, (2022). https://doi.org/10.1038/s41598-022-15432-y
Maier, S.U., Raja Beharelle, A., Polanía, R. et al. Dissociable mechanisms govern when and how strongly reward attributes affect decisions. Nat Hum Behav 4, 949–963 (2020). https://doi.org/10.1038/s41562-020-0893-y
Sullivan, N.J., Huettel, S.A. Healthful choices depend on the latency and rate of information accumulation. Nat Hum Behav 5, 1698–1706 (2021). https://doi.org/10.1038/s41562-021-01154-0