WubingZhang / MAGeCKFlute

Integrative analysis pipeline for pooled CRISPR functional genetic screens
https://github.com/WubingZhang/MAGeCKFlute
24 stars 10 forks source link

Bug in MAView when needing to transform gene names + solution #24

Open StrawHattM opened 2 months ago

StrawHattM commented 2 months ago

Hi,

Found a bug that prevents FluteMLE from running correctly, specifically when running MAView. When there are genes (~mouse genes) with no human equivalent, MAView tries to replace the NAs in dd by 0s: dd[is.na(dd)] = 0 but as this normally happens in character columns, we get a class asignment error, stating that it can't assign class='double' values to a class='character' column.

My guess is that R updated assignment class requirements to make the more strict

This is easily solved by changing the line to dd[is.na(dd)] = 0, thus coercing it into character.

Hope this helps, M