Tomi Capretto
Blog
Reading
About me
Blog - cause it’s better when it’s shared
I’m starting a reading list!
I never considered myself a bookworm. I didn’t grow up in a place where reading was encouraged nor am I talking about books with people all the time, at least not to the…
Feb 1, 2024
How to create a custom family in Bambi?
Bambi is the project I dedicate the vast majority of my open-source development time. My goal is to make it a little better every time I push to the main branch. Lately I’ve…
Jan 14, 2023
Let’s use tidypolars more
In this blogpost I’m going to show how to perform the same task with pandas, the most popular library for data analysis in Python, and tidypolars, a new library to do data…
Jun 26, 2022
Hierarchical modeling with the LKJ prior in PyMC
I describe how to use the
LKJCholeskyCov
and
LKJCorr
distributions to include correlated priors in Bayesian hierarchical modeling using PyMC.
Throughout this blogpost, I will be working with the famous
sleepstudy
dataset. I’m going to estimate a
hierarchical linear regression
with both
varying intercepts
and
varyin…
Jun 12, 2022
GSOC 2021: Final evaluation
Final post about Google Summer of Code 2021. This post sums up my contributions to the Bambi library during the ten weeks of this program.
In this short blogpost, I’m going to summarize my contributions to the Bambi library during this Google Summer of Code.
Aug 17, 2021
Binomial family in Bambi
My fourth post describing work done during GSoC 2021. On this occasion, I’m introducing the Binomial family. This new family is very useful to build models for binary data when each row in the data set contains the number of successes and the number of trials instead of the results of Bernoulli trials.
Although GSoC 2021 is close to come to an end, there’s still a lot of exciting things going on around Bambi. Today I’m going to talk about another new family that’s about to…
Aug 3, 2021
New families in Bambi
In this third post about my work during this Google Summer of Code I describe two families of models recently added. The first one, is the Student T family, used to make linear regressions more robust. The second, is the Beta family which can be used to model ratings and proportions.
I’m very happy I could contribute with many exciting changes to Bambi. Some changes, such as the reorganization of the default priors and built-in families, are not visible…
Jul 14, 2021
Robust linear regression in Bambi
Second post about this Google Summer of Code season. Today I show some of the problems associated with outliers in linear regression and demonstrate how one can implement a robust linear regression in Bambi.
The next thing in my TODO list for this Google Summer of Code season with NumFOCUS is to add new families of models to Bambi. This is still a WIP but I wanted to show you…
Jul 5, 2021
First weeks of GSoC
First post of a series about my contributions to Bambi in this Google Summer of Code season. This post highlights new features related to default priors and priors for group-specific effects.
I am really happy to participate in this Google Summer of Code season with NumFOCUS to contribute to the Bambi library. The coding period ranges from June 7 to August 16…
Jun 28, 2021
Design matrices for group-specific effects in formulae and lme4
Bambi uses the library formulae to automatically construct design matrices for both common and group-specific effects. This post compares design matrices for group-specific effects obtained with formulae for a variety of scenarios involving categorical variables with the ones obtained with the R package lme4.
A linear mixed model can be written as
Jun 8, 2021
Why Bambi?
An example comparing how to fit a GLM with Bambi and PyMC3. Here I attempt to highlight how Bambi can help us to write a Bayesian GLM in a concise manner, saving us from having to realize error-prone tasks that are sometimes necessary when directly working with PyMC3.
I’ve been thinking about writing a new blog post for a while now but honestly, there was nothing coming to my mind that made me think “Oh, yeah, this is interesting, it can…
May 24, 2021
How to generate bingo cards in R
A walkthrough the process of understanding how bingo cards are composed and a set of R functions that let us generate random bingo cards and print them in a nice looking .pdf output.
Hello wor… Well, my first hello world post appeared about a year ago, but this site had the same fate as many of my othe side-projects… abandonment.
Nov 3, 2020
No matching items