You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
addGeneScoreMatrix: GeneScoreMatrix is silently all-NaN when gene widths are equal (divide by max(m)-min(m) = 0) #2334
If every gene region has the same width, max(m) - min(m) is 0, every geneWeight is Inf/NaN, and the whole GeneScoreMatrix comes out NaN, with no error or warning. The failure only shows up later, far from its cause: getMarkerFeatures(useMatrix = "GeneScoreMatrix") stops with missing value where TRUE/FALSE needed.
This bit us on a small synthetic genome with uniform gene lengths (ArchR 1.0.3 from bioconda r-archr, R 4.4, on linux-aarch64 and linux-64 alike). Varying the gene lengths makes the matrix finite.
A second, possibly related question: the expression is not a min-max scaling of m. That would be 1 + (m - min(m)) * (geneScaleFactor - 1) / (max(m) - min(m)), mapping to [1, geneScaleFactor]. As written, the weights span [1 + min(m)·k, 1 + max(m)·k], which reaches geneScaleFactor only when min(m) is close to 0. If min-max is the intent, the fix covers both issues. If it isn't, a guard is enough, e.g.
Hi @scttfrdmn! Thanks for using ArchR! Please make sure that your post belongs in the Issues section. Only bugs and error reports belong in the Issues section. Usage questions and feature requests should be posted in the Discussions section, not in Issues.
If you are getting an error, it is likely due to something specific to your dataset, usage, or computational environment, all of which are extremely challenging to troubleshoot. As such, we require reproducible examples (preferably using the tutorial dataset) from users who want assistance. If you cannot reproduce your error, we will not be able to help.
Before going through the work of making a reproducible example, search the previous Issues, Discussions, function definitions, or the ArchR manual and you will likely find the answers you are looking for.
If your post does not contain a reproducible example, it is unlikely to receive a response.
In addition to a reproducible example, you must do the following things before we help you, unless your original post already contained this information: 1. If you've encountered an error, have you already searched previous Issues to make sure that this hasn't already been solved? 2. Did you post your log file? If not, add it now. 3. Remove any screenshots that contain text and instead copy and paste the text using markdown's codeblock syntax (three consecutive backticks). You can do this by editing your original post.
Activity
immanuelazn commentedon Oct 16, 2026
Hi @scttfrdmn! Thanks for using ArchR! Please make sure that your post belongs in the Issues section. Only bugs and error reports belong in the Issues section. Usage questions and feature requests should be posted in the Discussions section, not in Issues.
If you are getting an error, it is likely due to something specific to your dataset, usage, or computational environment, all of which are extremely challenging to troubleshoot. As such, we require reproducible examples (preferably using the tutorial dataset) from users who want assistance. If you cannot reproduce your error, we will not be able to help.
Before going through the work of making a reproducible example, search the previous Issues, Discussions, function definitions, or the ArchR manual and you will likely find the answers you are looking for.
If your post does not contain a reproducible example, it is unlikely to receive a response.
In addition to a reproducible example, you must do the following things before we help you, unless your original post already contained this information:
1. If you've encountered an error, have you already searched previous Issues to make sure that this hasn't already been solved?
2. Did you post your log file? If not, add it now.
3. Remove any screenshots that contain text and instead copy and paste the text using markdown's codeblock syntax (three consecutive backticks). You can do this by editing your original post.