Lucas Castillo
Current Organizations / Institutes
The organizations/institutes from the scholar's latest article
Research Subjects
Lucas Castillo has a total of 15 co-authors. Here are the top co-authors by number of shared publications:
- Adam N. Sanborn
Department of Psychology, University of Warwick, Coventry, UK
7 shared publications - Johanna K. Falben
School of Psychology, University of Aberdeen, Aberdeen, Scotland, UK
5 shared publications - Yun-Xiao Li
Department of Psychology, University of Warwick, Coventry, UK
5 shared publications - Nick Chater
University of Warwick
4 shared publications - Jake Spicer
Department of Psychology, University of Warwick
3 shared publications - Pablo León-Villagrá
Brown University, USA
3 shared publications
Latest Publications
- Open Access
- 14 October 2026
- Published by Springer Nature in Behavior Research Methods
- Vol. 58 (11) , 319
The samplr package: A tool for modeling human cognition with sampling algorithms
Many models of cognition have sampling as a central component. Researchers have used them to explain human performance across a wide range of tasks involving perception, probability reasoning, and choice. One family of these models takes inspiration from sampling approaches developed in statistics, either by adjusting samples with prior beliefs or by implementing a sampling algorithm that overcomes the difficulty of independent samples at the expense of autocorrelation. While these models have been successful in modeling human behavior, their adoption has been slowed by the technical difficulties in applying them. Here, we introduce the package, which includes a variety of these algorithms and cognitive models built upon them. We show how models in this package can match qualitative patterns found in human data, and walk readers through examples of how to compare these models quantitatively to human data. This tool aims to make these methods accessible to many more researchers.
- 14 October 2026
- Published by Springer Nature in Behavior Research Methods
- Vol. 58 (11) , 319
Open AccessThe samplr package: A tool for modeling human cognition with sampling algorithms
Many models of cognition have sampling as a central component. Researchers have used them to explain human performance across a wide range of tasks involving perception, probability reasoning, and choice. One family of these models takes inspiration from sampling approaches developed in statistics, either by adjusting samples with prior beliefs or by implementing a sampling algorithm that overcomes the difficulty of independent samples at the expense of autocorrelation. While these models have been successful in modeling human behavior, their adoption has been slowed by the technical difficulties in applying them. Here, we introduce the package, which includes a variety of these algorithms and cognitive models built upon them. We show how models in this package can match qualitative patterns found in human data, and walk readers through examples of how to compare these models quantitatively to human data. This tool aims to make these methods accessible to many more researchers.
- Open Access
- 14 October 2026
- Published by Elsevier in SSRN Electronic Journal
Belief Elicitation With Random Generation Tasks
Measuring people's beliefs is important for psychology, applied statistics, and AI alignment, yet established elicitation techniques yield only coarse distributional summaries and can introduce systematic biases. Here we propose random generation---asking participants to produce values as unpredictably as possible---as a belief elicitation method. Our approach draws on theories of mental sampling and needs no visual interface. In three preregistered experiments spanning nine domains, we compared random generation to two standard methods: decile elicitation (Experiments~1--2) and likelihood elicitation (Experiment~3). In Experiments~1 and~2, random generation produced distributions that were overall as close or closer to environmental data than decile elicitation, and predicted participants' conditional expectations at least as well. Random generation also captured idiosyncratic distributional features in one of three tested domains, the irregular score structure of NFL games. In Experiment~3, we elicited categorical distributions---participants' beliefs about the popularity of holiday destinations---and assessed whether they could predict participants' conditional judgments in a different domain (holiday flight durations). Random generation again captured environmental regularities comparably to likelihood elicitation for the derived flight-duration distributions, and both methods were similarly effective in capturing people's conditional predictions.Finally, aggregating small groups of participants on average moved the pooled distributions closer to the environment in all three experiments, and predictive accuracy improved at comparable rates for both tasks. These findings establish random generation as a versatile tool for recovering distributional beliefs and a practical complement to established techniques.
- 14 October 2026
- Published by Elsevier in SSRN Electronic Journal
Open AccessBelief Elicitation With Random Generation Tasks
Measuring people's beliefs is important for psychology, applied statistics, and AI alignment, yet established elicitation techniques yield only coarse distributional summaries and can introduce systematic biases. Here we propose random generation---asking participants to produce values as unpredictably as possible---as a belief elicitation method. Our approach draws on theories of mental sampling and needs no visual interface. In three preregistered experiments spanning nine domains, we compared random generation to two standard methods: decile elicitation (Experiments~1--2) and likelihood elicitation (Experiment~3). In Experiments~1 and~2, random generation produced distributions that were overall as close or closer to environmental data than decile elicitation, and predicted participants' conditional expectations at least as well. Random generation also captured idiosyncratic distributional features in one of three tested domains, the irregular score structure of NFL games. In Experiment~3, we elicited categorical distributions---participants' beliefs about the popularity of holiday destinations---and assessed whether they could predict participants' conditional judgments in a different domain (holiday flight durations). Random generation again captured environmental regularities comparably to likelihood elicitation for the derived flight-duration distributions, and both methods were similarly effective in capturing people's conditional predictions.Finally, aggregating small groups of participants on average moved the pooled distributions closer to the environment in all three experiments, and predictive accuracy improved at comparable rates for both tasks. These findings establish random generation as a versatile tool for recovering distributional beliefs and a practical complement to established techniques.
- Open Access
- 7 May 2026
- Published by Springer Nature in Communications Psychology
- Vol. 4 (1)
Generated outcomes in risky choice reveal biased sampling and sequential dependencies
Recent decision-making models have explained behaviour using mental sampling mechanisms, but there is still little agreement on the specific sampling process, such as whether sampling rates match true probabilities. Here, we seek to trace the sampling process using generation tasks: in two experiments using general online samples ( N s = 52, 51), participants repeatedly produced potential outcomes from pairs of monetary gambles before choosing between them. Results found over-generation of rarer outcomes and under-generation of common outcomes overall, but not in initial responses, as well as avoidance of direct repetitions. Participants also tended to select options with higher average utility across their responses, implying generations guided choice. These findings suggest systematic biases in the information people may consider before a choice, and the influence that this can have on subsequent decisions, carrying implications for mental sampling models of this behaviour. We thus suggest explicit generation is a valuable method to access underlying choice processes, offering new assessments of existing theories of decision making.
- 7 May 2026
- Published by Springer Nature in Communications Psychology
- Vol. 4 (1)
Open AccessGenerated outcomes in risky choice reveal biased sampling and sequential dependencies
Recent decision-making models have explained behaviour using mental sampling mechanisms, but there is still little agreement on the specific sampling process, such as whether sampling rates match true probabilities. Here, we seek to trace the sampling process using generation tasks: in two experiments using general online samples ( N s = 52, 51), participants repeatedly produced potential outcomes from pairs of monetary gambles before choosing between them. Results found over-generation of rarer outcomes and under-generation of common outcomes overall, but not in initial responses, as well as avoidance of direct repetitions. Participants also tended to select options with higher average utility across their responses, implying generations guided choice. These findings suggest systematic biases in the information people may consider before a choice, and the influence that this can have on subsequent decisions, carrying implications for mental sampling models of this behaviour. We thus suggest explicit generation is a valuable method to access underlying choice processes, offering new assessments of existing theories of decision making.
- Open Access
- 25 February 2026
- Published by Elsevier in SSRN Electronic Journal
Does Outcome Utility Bias the Mental Simulations of Risky Events?
Does the utility of an outcome influence people's assessment of risk and uncertainty? Prominent theories propose that people rely on mental simulation to evaluate probabilities and risky events, yet prior empirical findings is mixed as to whether and how utility biases this process. Across four experiments (total N=206, with Experiment 4 pre-registered), we tested this question using a random generation paradigm, in which participants mentally simulated gamble outcomes and said them out loud. Then we compared these responses with probability judgments and predictions. While we identified individual differences, the majority of participants exhibited neutrality, with no systematic impact of utility on their sampling distributions. Nevertheless, an optimism subgroup emerged, with a larger proportion of optimistic participants when the monetary context was more salient. Additionally, outcome utilities have similar effects on probability judgments, predictions, and random generation tasks, consistent with the proposal that these tasks are related to each other and may all rely on mental simulation. These findings indicate that utility does not uniformly distort mental simulation, but can do so for a stable subgroup under particular motivational contexts, and they motivate cognitive models that capture both unbiased and optimistic forms of mental sampling.
- 25 February 2026
- Published by Elsevier in SSRN Electronic Journal
Open AccessDoes Outcome Utility Bias the Mental Simulations of Risky Events?
Does the utility of an outcome influence people's assessment of risk and uncertainty? Prominent theories propose that people rely on mental simulation to evaluate probabilities and risky events, yet prior empirical findings is mixed as to whether and how utility biases this process. Across four experiments (total N=206, with Experiment 4 pre-registered), we tested this question using a random generation paradigm, in which participants mentally simulated gamble outcomes and said them out loud. Then we compared these responses with probability judgments and predictions. While we identified individual differences, the majority of participants exhibited neutrality, with no systematic impact of utility on their sampling distributions. Nevertheless, an optimism subgroup emerged, with a larger proportion of optimistic participants when the monetary context was more salient. Additionally, outcome utilities have similar effects on probability judgments, predictions, and random generation tasks, consistent with the proposal that these tasks are related to each other and may all rely on mental simulation. These findings indicate that utility does not uniformly distort mental simulation, but can do so for a stable subgroup under particular motivational contexts, and they motivate cognitive models that capture both unbiased and optimistic forms of mental sampling.
- Open Access
- 4 March 2025
- Published by SAGE Publications in Perspectives on Psychological Science
- Vol. 20 (3) , 572-589
Noise in Cognition: Bug or Feature?
Noise in behavior is often considered a nuisance: Although the mind aims for the best possible action, it is let down by unreliability in the sensory and response systems. Researchers often represent noise as additive, Gaussian, and independent. Yet a careful look at behavioral noise reveals a rich structure that defies easy explanation. First, in both perceptual and preferential judgments sensory and response noise may potentially play only minor roles, with most noise arising in the cognitive computations. Second, the functional form of the noise is both non-Gaussian and nonindependent, with the distribution of noise being better characterized as heavy-tailed and as having substantial long-range autocorrelations. It is possible that this structure results from brains that are, for some reason, bedeviled by a fundamental design flaw, albeit one with intriguingly distinctive characteristics. Alternatively, noise might not be a bug but a feature. Specifically, we propose that the brain approximates probabilistic inference with a local sampling algorithm, one using randomness to drive its exploration of alternative hypotheses. Reframing cognition in this way explains the rich structure of noise and leads to the surprising conclusion that noise is not a symptom of cognitive malfunction but plays a central role in underpinning human intelligence.
- 4 March 2025
- Published by SAGE Publications in Perspectives on Psychological Science
- Vol. 20 (3) , 572-589
Open AccessNoise in Cognition: Bug or Feature?
Noise in behavior is often considered a nuisance: Although the mind aims for the best possible action, it is let down by unreliability in the sensory and response systems. Researchers often represent noise as additive, Gaussian, and independent. Yet a careful look at behavioral noise reveals a rich structure that defies easy explanation. First, in both perceptual and preferential judgments sensory and response noise may potentially play only minor roles, with most noise arising in the cognitive computations. Second, the functional form of the noise is both non-Gaussian and nonindependent, with the distribution of noise being better characterized as heavy-tailed and as having substantial long-range autocorrelations. It is possible that this structure results from brains that are, for some reason, bedeviled by a fundamental design flaw, albeit one with intriguingly distinctive characteristics. Alternatively, noise might not be a bug but a feature. Specifically, we propose that the brain approximates probabilistic inference with a local sampling algorithm, one using randomness to drive its exploration of alternative hypotheses. Reframing cognition in this way explains the rich structure of noise and leads to the surprising conclusion that noise is not a symptom of cognitive malfunction but plays a central role in underpinning human intelligence.
- Open Access
- 1 August 2024
- Published by The R Foundation
samplr: Compare Human Performance to Sampling Algorithms
- 1 August 2024
- Published by The R Foundation
Open Accesssamplr: Compare Human Performance to Sampling Algorithms
- 13 June 2024
- Published by The R Foundation
Open AccesssamplrData: Datasets from the SAMPLING Project
- Open Access
- 5 January 2024
- Published by Public Library of Science (PLoS) in PLOS Computational Biology
- Vol. 20 (1) , e1011739
Explaining the flaws in human random generation as local sampling with momentum
In many tasks, human behavior is far noisier than is optimal. Yet when asked to behave randomly, people are typically too predictable. We argue that these apparently contrasting observations have the same origin: the operation of a general-purpose local sampling algorithm for probabilistic inference. This account makes distinctive predictions regarding random sequence generation, not predicted by previous accounts—which suggests that randomness is produced by inhibition of habitual behavior, striving for unpredictability. We verify these predictions in two experiments: people show the same deviations from randomness when randomly generating from non-uniform or recently-learned distributions. In addition, our data show a novel signature behavior, that people’s sequences have too few changes of trajectory, which argues against the specific local sampling algorithms that have been proposed in past work with other tasks. Using computational modeling, we show that local sampling where direction is maintained across trials best explains our data, which suggests it may be used in other tasks too. While local sampling has previously explained why people are unpredictable in standard cognitive tasks, here it also explains why human random sequences are not unpredictable enough.
- 5 January 2024
- Published by Public Library of Science (PLoS) in PLOS Computational Biology
- Vol. 20 (1) , e1011739
Open AccessExplaining the flaws in human random generation as local sampling with momentum
In many tasks, human behavior is far noisier than is optimal. Yet when asked to behave randomly, people are typically too predictable. We argue that these apparently contrasting observations have the same origin: the operation of a general-purpose local sampling algorithm for probabilistic inference. This account makes distinctive predictions regarding random sequence generation, not predicted by previous accounts—which suggests that randomness is produced by inhibition of habitual behavior, striving for unpredictability. We verify these predictions in two experiments: people show the same deviations from randomness when randomly generating from non-uniform or recently-learned distributions. In addition, our data show a novel signature behavior, that people’s sequences have too few changes of trajectory, which argues against the specific local sampling algorithms that have been proposed in past work with other tasks. Using computational modeling, we show that local sampling where direction is maintained across trials best explains our data, which suggests it may be used in other tasks too. While local sampling has previously explained why people are unpredictable in standard cognitive tasks, here it also explains why human random sequences are not unpredictable enough.