Skip to content →

Category: Blog

Stop doing sequential testing with Bayes factors

I mentioned earlier that the whole “Bayesian inference is immune to stopping rules” excitement is largely overblown, but the simulations were based on pretty idealized situations. I thought it might be interesting to use summary statistics reported by an actual … Read more

Comments closed

Tuning curves as functional data

I don’t know anything about cellular neuroscience or single cell recording, but I recently came across the problem of estimating the receptive field of a neuron from its spiking frequency in response to movement at various angles. This is directional … Read more

Comments closed

Bayesian functional linear models pt.1 – Estimating a mean

This post describes step 1 of my quest to build a fully Bayesian general linear model for functional data. I haven’t done it yet, and any solution is likely to be very computationally expensive, but so far I’ve had a … Read more

Comments closed

Towards efficient IGT model simulation/estimation in R/Stan

As part of my playing around with alternative objective functions for estimating reinforcement learning models of the Iowa Gambling Task (IGT), I needed a way to quickly simulate large numbers of participants. Since base R is slow, I implemented a … Read more

Comments closed

In which I complain about factor analysis

Factor analysis, like almost all forms of data analysis, is just matrix factorization. Let \mathbf{Y}_{n,k} be a matrix containing n observations of k variables (or indicators). We suppose that the variables in \mathbf{Y} can be written as linear combinations of p < k unobserved (or latent) factors, … Read more

Comments closed

solitaiRe encryption in R

Out of sheer boredom, I decided to try my hand at implementing the Solitaire encryption algorithm in R. Solitaire was developed by Bruce Schneier for Neil Stephenson’s Crytonomicon, and is designed to be implemented using only a deck of … Read more

Comments closed

Multiple hypothetical comparisons

You don’t actually have to do multiple comparisons to have a multiple comparisons problem — comparisons that you might hypothetically have done maybe if the data had been different perhaps will do it. I’ll show you.

Suppose that you’re conducting … Read more

Comments closed

Experimenting with IGT factorization

The Iowa Gambling Task has always been one of my favorite tasks, if only because it’s so much fun to analyze. In the standard version of the task, subjects select a card on each trial from one of four decks … Read more

Comments closed

MSMVSampEn: Multiscale Multivariate Sample Entropy in R

A while back, a friend of mine asked me to help out in a longitudinal project trying to predict cognitive decline in (otherwise healthy) older adults (Mulligan, Areshenkoff, & Smart, 2015). One of the measures we used was resting state … Read more

Comments closed

Bayes Factors and Stopping Rules

One can argue the choice of when to stop collecting data should be irrelevant to our choice of parameter estimates, since all information should be contained in the likelihood function. This principle underlies some criticisms of standard hypothesis testing, where … Read more

One Comment