Transcript
[2026-05-29] Solving an elusive bug: process and lessons learned
From Leonardo Collado Torres · Episode page · Watch on YouTube
· 25 min · 4,661 words · 56 timestamped sections
This is the full, timestamped transcript of "[2026-05-29] Solving an elusive bug: process and lessons learned", an episode of Leonardo Collado Torres published September 23, 2026 (25 min, about 4,661 words). It mentions 23 people, works and ideas, including Spatial transcriptomics, duckplyr, Spatial registration, Batch effect, Left join.
What this episode is about
In this concise session, the host walks through a stubborn bug encountered while analyzing spatial transcriptomics data, detailing how they noticed surprising transcriptional differences between nearby extracellular clusters and cells. They recount their debugging approach, including cross-checking bin-to-cell mappings, performing joins, and validating plotting logic, with a focus on what signals raised red flags (unexpected correlations and registration expectations). The episode emphasizes practical lessons on bug detection, collaboration, and validating data pipelines before drawing conclusions. Valuable for listeners who want a real-world, methodical walkthrough of diagnosing elusive data bugs and improving analytical reliability.
Key takeaways
- Spot the outliers early: red dots flagged unexpected neighbor-transcription hints a bug, not biology.
- Trust intuition but verify: a gut check from Leo nudged a bug hunt, not data bias.
- Registration quirks can fool you: correlations near but not at one often signal issues.
- Isolate where it matters: separate bin vs cell vs cluster files to spot mismatches.
- Always sanity-check with a different angle: shuffle plots and stats to validate findings.
Who speaks in this episode?
- Leonardo Collado Torres (Host)
What is discussed, and when
- – 5:00: Spatial registration, Leonardo Collado Torres, Google Sheets
- – 10:00: Spatial registration, Batch effect, Spatial transcriptomics, Principal component analysis
- – 15:00: Left join, Batch effect, SBE object, duckplyr
- – 20:00: Left join, Batch effect, dplyr
Notable quotes from "[2026-05-29] Solving an elusive bug: process and lessons learned"
Some basic knowledge of data today in describing like what the bug was and stuff. But basically with is spatial data where it's very it's HD, so it's you have really high resolution.
about Spatial transcriptomics · atMaybe we do have some transcription that's different than what's the cells that are nearby. I talked with Leo about this and Leo had sort of a little I think he had better…
about Leonardo Collado Torres · atSo definitely something very weird is happening here. This is a extremely severe batch effect by sample. So Leo asked me, okay, well what happens if you just like out of curiosity, what happens if you regress out that batch effect?
about Batch effect · atAnd yeah, so the spatial registration stats might be messed up because there's this weird batch effect by sample.
about Spatial registration · atI have the bin level data in the spatial experiment object which is basically like the barcode and the sample ID combined.
about SBE object · atAnd what happens is that when you do the left join, when you load in duck player, it overrides the method for left join with its own method. Generally the package itself is are supposed to provide functional equivalents to the.
about duckplyr · atData frame. If I had used D player directly with the left join, this always works. So D player guarantees when you do a left join that the order of the row stays the same and I've relied on that heavily before.
about dplyr · atSo when it does this join it's just shuffling the order. So I guess there are performance benefits to being able to not guarantee the output order. Is there their argument but I'm not sure.
about DuckDB · at
Who and what is mentioned in this episode?
People
- Leonardo Collado Torres — Person · Host / organizer · 1 mention · first at
Host of the show; introduced the session and context. Mentioned in relation to discussing the bug and group activities (LIBD rstats club).
Companies & orgs
- Team Data Science — Company · Affiliated team · 3 mentions · first at
Mentioned in show description as the Team Data Science group (R/Bioconductor-powered) led by Leonardo Collado Torres.The R/Bioconductor-powered Team Data Science team.
- Posit — Company · Tool vendor (owner of dplyr) · 4 mentions · first at
Mentioned indirectly as dplyr's owner (dplyr contrasted with duckplyr).Data frame. If I had used D player directly with the left join, this always works. So D player guarantees when you do a left join that the order of the row stays the same and I've relied on that heavily before.
- Bluesky — Company · Platform referenced · 3 mentions · first at
Bluesky (bsky.app) is used as the hosting platform for linked profiles in the episode metadata.
Products & tech
- duckplyr — Product · Case study / source of bug · 1 mention · first at
Central to the debugging story: its left_join behavior (non-guaranteed row-order stability) caused misaligned cluster labels and downstream incorrect analyses. - dplyr — Product · Reference tool / comparator · 1 mention · first at
Used as the expected behavior reference for joins; duckplyr's deviation from dplyr's guaranteed row-order preservation caused the bug. - DuckDB — Product · Underlying engine referenced · 1 mention · first at
DuckDB (referred to as duck DB) is mentioned as the underlying engine powering duckplyr and is noted to not guarantee output order stability for performance reasons. - R — Product · Tooling ecosystem / language · 1 mention · first at
R is the programming language used for the analyses referenced throughout the episode (dplyr, duckplyr, Bioconductor tools).Data frame. If I had used D player directly with the left join, this always works. So D player guarantees when you do a left join that the order of the row stays the same and I've relied on that heavily before.
- SBE object — Product · Analysis object / data container · 3 mentions · first at
SBE (spatial experiment) object is referenced as the container holding bin-level expression data used in spatial registration analysis. - Google Sheets — Product · Material location · 1 mention · first at
Referenced as where slides/materials were placed (mentioned in transcript intro).I investigated, and then sort of some lessons. So yeah. I put the slides in the Google sheet, but you probably I'll be sharing my slides, so there are probably some really need to follow directly [clears throat] along, but yeah, let me.
- FICTURE — Product · Mentioned tag / context · 3 mentions · first at
Appears in the episode summary tags (no discussion in transcript body).
Concepts & topics
- Spatial transcriptomics — Concept · Core topic · 1 mention · first at
The biological data domain for the episode: high-resolution spatial transcriptomics data are being analyzed and were the context in which the bug appeared. - Spatial registration — Concept · Analysis method / diagnostic metric · 7 mentions · first at
Spatial registration correlations were unexpectedly low and were a key signal that something in the data pipeline was wrong. - Batch effect — Concept · Observed artifact / diagnostic · 7 mentions · first at
An extreme per-sample batch effect appeared in pseudo-bulk PCA, which was a clue that labels had been misaligned and biological signal was lost. - Left join — Concept · Operation central to bug · 6 mentions · first at
The left join operation's differing guarantees between duckplyr and dplyr (row order preservation) led to scrambled labels when combined with pull().And what happens is that when you do the left join, when you load in duck player, it overrides the method for left join with its own method. Generally the package itself is are supposed to.
- Pseudo-bulking — Concept · Data processing step · 2 mentions · first at
Pseudo-bulking (aggregating expression by cluster/sample) was part of the pipeline; after misaligned labels this yielded no cluster signal.Yeah. So basically like there's that. And then so in the spatial registration process, you pseudo-bulk the data before doing your one versus all markers. So Leo had asked me to do a PCA of.
- Principal component analysis — Concept · Diagnostic technique · 1 mention · first at
Used on pseudo-bulked data to reveal the extreme sample-specific batch effect and to test the effect of regressing out sample.Registration process, you pseudo-bulk the data before doing your one versus all markers. So Leo had asked me to do a PCA of the pseudo-bulk data. So we did that on the left here.
- Data Science — Concept · Context / domain · 4 mentions · first at
General domain of the show and episode; provides context for the debugging and analysis workflow described. - R programming language — Concept · Tooling context · 4 mentions · first at
Explicitly referenced as the programming language used in the analyses and videos; part of the show's focus.I investigated, and then sort of some lessons. So yeah. I put the slides in the Google sheet, but you probably I'll be sharing my slides, so there are probably some really need to follow directly [clears throat] along, but yeah, let me.
- Bioinformatics — Concept · Field context · 3 mentions · first at
Part of the episode's topical scope; the analysis and methods discussed are bioinformatics-oriented. - Spatial -omics — Concept · Broader domain · 3 mentions · first at
Mentioned in episode summary to situate spatial transcriptomics within spatial -omics research.
Places & events
- LIBD rstats club — Event · Series / community · 4 mentions · first at
The episode is part of LIBD rstats club content; referenced as the group hosting related videos. - Medial habenula — Place · Biological example region · 1 mention · first at
Used as an example brain region (medial habenula) to check that cluster 0 belonged to the expected anatomy as part of alignment checks.See like is this factor zero, which we know from I guess I didn't show it here, but we know that it should belong in the medial habenula. The medial habenula is indeed this…
Full transcript with timestamps
Today I basically just have sort of like a pretty short It'll be a short session. I have some I recently ran into like a bug that was pretty difficult to figure out and so I basically just have like a little presentation on just like how I first noticed what was wrong, what I investigated, and then sort of some lessons. So yeah. I put the slides in the Google sheet, but you probably I'll be sharing my slides, so there are probably some really need to follow directly [clears throat] along, but yeah, let me Yeah, so some backgrounds. So I've talked about a little bit about we had I think we had a presentation like a couple weeks back about data, so I'll assume maybe some some basic knowledge of data today in describing like what the bug was and stuff. But basically with is spatial data where it's very it's HD, so it's you have really high resolution.
You're able to You have these bins that are smaller than cells and then basically you have the resolution to be able to check transcription both inside and outside of a cell cell. So there are a lot of like questions that we had like analysis questions that sort of opened up to answer some of those questions. And basically what I was doing is I was I had this plot on the right where the purpose of this plot was really to investigate if transcription inside of cells disagreed with the transcription outside of cells essentially. And so I guess just to go over like this plot, we had a bunch of We had the cells labeled with with cell types already annotated.
Um and then we had some clusters that were on at the bin level. So these are sort of smaller than cells and there could be multiple bins per cell. We were just We were just doing this on things. I should probably should little diagram for this, but we were doing this on just extra the extra cellular space. So these are extra cellular clusters on the x-axis. And what I was trying to visualize here was for a given cell type we have this proportion which is in the size of these points. That they all add to one. So basically for a given cell type we're asking what what clusters are nearby and sort of outside of the these these cells.
And then we also have the color is the transcriptional correlation. So if cluster zero for example is correlated with the transcription for this medial one cluster we would it would be blue. So we were we were seeing red and red dots were particularly suspicious because or kind of surprising really. It wasn't necessarily suspicious to me at first, but it's surprising because it's saying that like among clusters that are nearby those clusters tend to be transcriptionally very different than the the cells that they they are nearby.
So really on these these plots you would expect at least we were expecting a lot of large blue dots indicating that things were very similar to things that they were nearby. So first I was ready to just say like okay well maybe this is what the data is saying. Maybe it's surprising but it looks like maybe we do have some transcription that's different than what's the cells that are nearby. I talked with Leo about this and Leo had sort of a little I think he had better intuition on this where he was saying like okay well wait this kind of seems unexpected. Are you sure there's not something wrong here?
So yeah I think Leo Leo had a little bit of a better intuition on as so like maybe there's a problem actually here rather than this is what the data is actually saying. So there's that and then another thing that I didn't mention is that like these typically with these correlations are from spatial registration. Um spatial registration correlations like in my experience are typically a lot higher than what is shown on the scale. And we get things that are closer to not one, but not as large as one, but like closer to one for sure.
So those were like two signs that like we're getting at least unexpected results. So Leo had asked me to look into some of this, like make sure there's not some sort of bug or other things. So one of the bug checks I did was I noticed that there is like a lot of We have stuff at the bin level, we have stuff at the cell level, and we have clusters associated with each. And typically those were in separate files, the way I was handling it. So one of the things I checked was like, okay, is there a mismatch between like some of these which cells are annotated to be to belong to or sorry, which bins are annotated to belong to each cell. And so I have some code as an example of like loading in the cell level clusters.
Actually, I think yeah, these are the cell level clusters. The bin level clusters, doing some joins, and then we'll have some plotting code. So basically the plotting code showed that like, okay, it's not This is like a section where basically my my tests in the plotting code was to see like is this factor zero, which we know from I guess I didn't show it here, but we know that it should belong in the medial habenula. The medial habenula is indeed this region that is red. So visually we this alignment check worked. It didn't come up with any issues. So it didn't appear to be an issue with aligning bins and cells and the separate files that were involved for each. So next I wanted to try to ask the same biological question sort of in a different way. So again, we're trying to find a different way to compare thing transcription inside of cells versus outside of cells.
So I won't get into like the details of the I guess how I framed this question, but we get this Basically I guess on the bottom left I have some code for running the generating the spatial registration stats for the extracellular data. So I load in the SBE object, the spatial experiment object, the bin level clusters. I those into the spatial experiment, and then I do my registration wrapper to get those registration statistics. And then on the right here, I'm basically doing the the next step of that, which is to correlate the registration statistics to a separate data set.
In this case, I had I had framed it in a way where I was I sort of had an extracellular and intracellular data set. So I won't go into details of that, but like basically one of these accesses axes is extracellular and the other is intracellular. They the factors should agree in number. So zero should be correlated with zero, one should be correlated with one, and so on. And that is not really what we were seeing here. We did get coincidentally zero was correlated with zero, but among the other ones, there was sort of random noise. And if you look at the scale of these correlations, it was absolutely tiny. So again, we're getting some sort of weird results here.
Like why are these correlations so small? So something seems to be going on with the spatial registration statistics that is not typical of spatial registration. And that seems to be contributing to something already something definitely seems to be wrong here. So yeah, the the next step I had was to like, okay, well, what's contributing to these poor spatial registration results? And poor in the sense of like we're getting small correlations. That was the only thing I knew so far. But next I checked that there were what were the P that like the T stats and P values for these statistics. And basically we were getting no significant markers for for the the clusters, the bin-level clusters, which was pretty weird. Like typically if there are clusters are supposed to be obviously different enough and consistently different enough that you should get significant markers, many of the clusters had absolutely no markers.
Is that for the extracellular data? Yeah. Yeah. So basically like there's that. And then so in the spatial registration process, you pseudo-bulk the data before doing your one versus all markers. So Leo had asked me to do a PCA of the pseudo-bulk data. So we did that on the left here. So I'm coloring so each point is a I pseudo-bulk by bin level cluster and by sample. So each of these points is a sample and fit in cluster combination. And it very cleanly just separates purely by sample. All the clusters for one sample are all together with almost no space difference. And these PCs explain a lot of the variance.
So definitely something very weird is happening here. This is a extremely severe batch effect by sample. So Leo asked me, okay, well what happens if you just like out of curiosity, what happens if you regress out that batch effect? Like what what's left? So if we regress out the signal from from sample ID using something like Cleaning Y from Jaffy Lab, you get this plot on the right. And this time it's colored by the the bin level cluster. And we have PCs that explain almost no variance and we get a very random distribution across clusters. So it looks like there's almost no cluster differentiating signal.
I did look at further PCs like up to 10 and we had something similar where basically this was there was no signal pretty much in the data. And yeah, so the spatial registration stats might be messed up because there's this weird batch effect by sample. So that's what we know so far. What was suspicious about all of this is that we clustered with this the same data, right? We we got these bin level clusters. The bin level clusters look excellent. They pulled out some biological regions that we were expecting. So we had some neuronal regions and some white matter in in purple here among other features that we were expecting. So we were getting great clustering results visually at least from the bin level tool. So that was that was weird. We we had this disconnect between the the quality of the transcriptional data when we pseudo-bulked versus when we actually put it directly into this clustering algorithm.
[clears throat] Another interesting thing was I sort of compared the the sample composition of each cluster. So across our 10 we had 10 sample or sorry, 10 clusters in this case and five donors. And so, we have the data set that was problematic on the top and then we had a reference data set where we applied basically the same method, but we weren't seeing any of these problems with the spatial registration stats or any anything else. And they were [clears throat] pretty similar. They were both I mean, obviously there are differences in which samples which clusters were present in each sample, but it wasn't something severe that you might expect from such a bad batch effect by sample.
So, already getting some really weird inconsistent results. So, these were the hints I had so far and I I was kind of lost as to what was happening and basically I checked so I was a little stuck, but then I was like, okay, I'll try one more thing. Have I actually lined up the clusters directly with the transcriptional data? So, actually going back here to get these plots on the left, I never actually lined up the data with the transcriptional data. I had the data in an external file that already had the spatial coordinates. So so there was no need to line it up with the spatial experiment object which had the the gene expression data itself. So, this [clears throat] was more of a direct directly reading a file and not doing any anything crazy.
But so I did try to line it up with the spatial experiment object. So, on the on the top here I have my bin level clusters. So, I'm just really just reading it in. I'm using this dot plier library which I've talked about a couple of times and I'm really just I'm reading in the identifier for the bin and then the the cluster assignment for that bin. I have the bin level data in the spatial experiment object which is basically like the the barcode and the sample ID combined. And so all I do is I just left join that in by the bin the bin key and then I take out the the cluster and that's assigned to the spatial experiment object there. In some cases the the clustering data did its own filtering so there are some tiny amount of NAs and then I plotted my code and that resulted in this completely random.
So, I was really happy when I found this because it's like, okay, well, here's here's the bug. The alignment is not obviously doing something jumbling up the the cluster labels. So this code right here is problematic, which I'll talk about next slide. Um I did a variation of this code where everything is the same except I have this index here and then I arrange by the index. So that might seem strange, but actually it's a little I guess here I'm joining by sample ID and barcode. So there's a couple small differences. But this code works, right? So this join worked and gave us the clustering results we were expecting. So at this point I was like, okay, I had done very similar code to stuff on the top left before and it had worked.
So yeah, what was what exactly was wrong? So I'll explain what happened. So it did have to do with this duck player library, which I've been making a lot of positive statements about. And what happens is that when you do the left join, when you load in duck player, it overrides the method for left join with its own method. Generally the the package itself is are supposed to provide functional equivalents to the deep libraries, but there are some known incompatibilities. On this on the right here, I had missed this documentation saying that duck DB, which is the like underlying engine powering duck player, does not guaranteed output or order stability. I mean, for performance reasons, it doesn't enable output order stability, which in this case means when you do the left join, it's not guaranteed to preserve preserve the row order of the the resulting data frame. So what happens is when I do a a
simple poll afterward, the poll is aligned with this jumbled up data frame. If I had used D player directly with the left join, this always works. So D player guarantees when you do a left join that the the order of the row stays the same and I've relied on that heavily before. Um but yeah, when you override the method duck player, you get this misalignment and then when you poll now the the order of these cluster assignments are jumbled, randomly, like we saw before, where we get this completely meaningless pattern.
So, when I was pseudo-bulking by the actual transcriptional data with these labels, these completely messed up labels, we were that's why there was no signal. It's kind of interesting that we were getting a batch effect by sample, actually.
I was just thinking about that that's with like the the revelation that it's a complete random noise. I think it's super cool that you're getting the per-sample batch effect. Cuz I mean, I think what that implies is if if you're just clustering on random transcriptional noise and, you know, looking at similarities of of clusters across, the the batch effect is like truly like random noise across samples. Um like the the I think I'll I'll have to like like maybe look at that plot for half an hour to like internalize like what's going on.
But I don't know, like when when you cluster on random noise and you get complete like per-sample like signal, I don't know, I think that says something about the the actual like nature of the noise of the batch effect. The random transcriptional signal that each sample is sampling is different. It's also like independent from one another, potentially.
Yeah, it's like there's only like once you randomize the biological signal, it's like the technical signal is what's left, and that does consistently look like something across the sample. Yeah, so it's kind of interesting. But yeah, I was like at first I was I was writing variations of So, I showed you the simplified a very simplified version of what I actually investigated. But at first I was like this must just be a bug. Like this is giving me different behavior than Dplyr when I do these join. Something is I'm using the same logic and it 's giving me different results. But it was because there was I had just not read the documentation closely enough, and there are inconsistencies that they have been documented. So, that that was kind of my fault.
So, yeah, that that's that was basically it for today. I did like so I'll sort of end with some lessons. So, at the beginning of this so if we go back and we go to like this event this one plot where we saw like just minor issues, I was ready to just say like maybe this is just biologically what's happening. Like I was just ready for the data to tell like if this was the story the data was telling, I was maybe too eager to accept that as the the story, whereas Leo had better maybe judgment on on this and had an instinct that like basically I guess I have these bullets here. So like I was too eager to let the data tell a story even if the story is different than what we hypothesized. Sometimes that's a valuable thing. Sometimes we don't want to introduce our own biases into into the results we get, but at the same time our intuition does serve a really valuable purpose, and that is to detect
mistakes. So I would basically I would not don't disregard intuition too early, even if you're eager to try to examine the data in an unbiased way. Sometimes the what we call bias is part of things that help us identify mistakes. That's one lesson. Also the second lesson is just like be really careful about what you're assuming. I think this I mean a lot of people have said this before, right? Like this is a pretty common lesson maybe. Like as I guess I've noticed as gaining experience as a data scientist, I I've noticed I I do make a lot less mistakes in terms of implementing logic in C Darex if you're given correct assumptions. A lot of the mistakes I tend to I've noticed I I make are when I make faulty assumptions. Um so just to be really careful about what you're assuming is true, and when something goes wrong, you might want directly question what your assumptions were with when you're running this code. Like in
my case the assumption was when I use duck plier it's going to return exactly the same thing as D plier every time, and that assumption was false because they had this documented exception. So yeah, and that's all. I know we had a kind of short session, but this was something that was driving me crazy for like more than a week. And yeah, it was good to finally catch this bug. But yeah, that's all I have to say.
Isn't Like why why is the row order not preserved? Cuz isn't a join like [clears throat] it you have two different tables and you're matching on like a column
Yeah. and then it like returns the matching data. So I I'm assuming you were matching on the
the bin so the identifier for the two micron bin. And then theoretic so the for the the bin level data the like bin ID plus the cluster ID like should be a single like data entry a single row. [clears throat] But that's what was getting like jumbled up.
So it was confusing cuz so we have like this we have the bin key at the How would I like say this? Like the left join is is jumbling the entire data frame that I this input data frame which just had the the bin identifier. So when it does this join it's just shuffling the order. So I guess there are performance benefits to being able to not guarantee the output order. Is there their argument but I I'm not sure. It is sort of it's counterintuitive to me at least like I would like why rearrange the order?
People I guess I'm I'm more concerned with So if the join itself is like working as expected where like I have a bin key column in table one and a bin key column in table two and it's like matching [clears throat] those.
Yeah. At some level the the bin key on one of those tables is uh getting jumbled up with the rest of the data in that table and that that's like causing the the mismatch. If if I if I have that right.
It's not well it's not a mismatch cuz it is aligning them correctly. It's just It's aligning the bin keys correctly. But there's I guess the the data on on one half of the join is getting jumbled with respect to the bin key.
No. So it should be everything is consistent. But it's just the the only thing that ends up different is the actual order of the final correct rows at the end.
So like bin key one on the left table doesn't necessarily equal like bin key one on
No, they they I guess I guess so the bin key is going to be exactly the same, right? But like bin key one on the right table is like the incorrect bin key one.
So I mean it's not doing anything incorrect necessarily. Like it is definitely aligning the same bins, bin key one with bin key one. You can think of it like it's pulling bin key one on the on the right table to the one on the left and then just randomly rearranging the resulting data frame. It's almost like that.
The most important of the join. Right? Cuz it's correctly like joining on bin key, but the point of the join is to like match up like all the data.
Yeah, and it is doing that. It's just the rows themselves are So it's a every single row has the correct alignment between bin each combination of bins and the cluster. So that all that data is completely correct. It's just the rows themselves are rearranged.
Oh, but I guess once it's correctly joined, like if I have bin one is associated with cluster one and bin two is associated with cluster two and then like that simple framework, as soon as it's correctly joined, I could shuffle those rows and that same information is preserved, correct?
Yeah. So I guess how does that translate to like the random Um I might need to like draw. Let me see if I can like Do I have like an empty slide? Maybe I'll try and draw. Can I do an example of this? So I have like bin key A. On the left table we have bin key A and bin key B. On the right table let's say we have B and that's cluster one. And then we have A. So let's just say for the order the rows are in different orders, but A has cluster two. And then after the join you get something like A2, which is correct, right? That makes sense. Like, so it's matching
Yeah. instead of having A2 B1, we have B1 A2. So it's still correct. It's just the rows are jumbled.
I guess I mean we we can chat offline I guess. I don't know. I'm still not seeing kind of like where the random mismatch is coming from.
Cuz like why it caused a problem in my code? Yeah. Yeah. Okay. So the problem was I was doing this pull where I was saying take the values one and two and then assign them to A and B.
Ah, okay. Okay. From the original like uh Yeah, cuz okay. So it came from Certainly. That makes sense.
So the matching was correct, but yeah, I guess the assumption was that the matched output would have the exact same ordering as the input.
The error in my script was doing a pull here. So the pull is taking like let's just take the values from that column ignoring what the the values were in this table that I used as input. Because the join distorted it. Like the pull is isolating this column which has a different caching kind of
Okay. Okay. So input a different order than output, but even though the matching was correct and the assumption was that they should be the same order.
Yeah, exactly. So I this was sort of Arguably this is sort of a sloppy way to do it because I made assumptions that were probably not necessary to make. I could have maybe done this in a cleaner way. But yeah, that's what happens if you assume something and then don't check. But yeah.
I mean it it is just a subtle difference, right? From the the previous like standard. So
Mhm. [clears throat] I don't know. If anything it's like Duck Plyer's fault for not being more explicit with uh like expected differences. I would I would like to blame them as well.
Yeah. I think I mean I didn't they did have the To be fair on their part like they did have the doc they did document this explicitly. It's yeah, it's counterintuitive, but I don't know. I guess it improves performance. And to be fair, like this package has been great with performance. So I've been pretty happy with that, but
Yeah. Cool. Yeah, that's that's pretty much it. There's some questions in the chat.
Oh, there there's a chat. Okay, sorry. I missed I always miss the chat. It can be more efficient to not preserve row order, but it's weird. Yeah, exactly. Most applications you wouldn't think about the row order mattering unless you do things like what I did. But yeah, you can sometimes constraints were were some performance just unnecessary constraints, I guess. But yeah, if you assume that if this is this package is just a more performant version of exactly the same logic, then that's you can run into issues, I guess.
So be careful about that. Um it goes Oh, yep. Cool. All right. Thanks everyone. I will see you guys next week.
Questions about this episode
Who speaks in "[2026-05-29] Solving an elusive bug: process and lessons learned"?
Leonardo Collado Torres (Host).
What is "[2026-05-29] Solving an elusive bug: process and lessons learned" about?
In this concise session, the host walks through a stubborn bug encountered while analyzing spatial transcriptomics data, detailing how they noticed surprising transcriptional differences between nearby extracellular clusters and cells. They recount their debugging approach, including cross-checking bin-to-cell mappings, performing joins, and validating plotting logic, with a focus on what…
What is mentioned in this Leonardo Collado Torres episode?
23 people, works and ideas are mentioned, including Spatial transcriptomics, duckplyr, Spatial registration, Batch effect, Left join, dplyr. Each one on this page links to its own page with every episode that mentions it.
How long is "[2026-05-29] Solving an elusive bug: process and lessons learned"?
The episode runs 25 min; the transcript is about 4,661 words in 56 timestamped sections.
More from Leonardo Collado Torres
About this transcript: The transcript is the YouTube captions for an episode that is already public on YouTube. It is split into timestamped sections. Reclip.Me locates every person, work and idea in the text, keeps the time it is first named, and quotes the words around it verbatim. Last updated December 4, 2026.