Skip to content

Conversation

CSBVision
Copy link

I would like to fix a rather tricky bug (I run into it because the plot was not showing the correct connection lines):
The statement 'till <- which(ss[i,i:mx])' (line 282 in the original file) causes a bug because it does the following: First, it takes the i-th line of the matrix and removes the first (i-1) columns from it. Next, it computes (which-call) the indices of all TRUE-values in the remaining vector. However, actually required are the indices in the original i-th row (respecting the removed i-1 columns), i.e. the result from which() is too small by (i-1). By adding (i-1) after the which-call, the result was correct. Additionally, I added the 'till > i' condition because it might happen otherwise that there is a bar only "connecting" one workflow (e.g. if all pairwise differences are significant)
Finally my other changes are just removing the unused variable 'from' as well as fixing the code to avoid warnings (only the first element returned by which() is actually used).
Thanks
Björn

I would like to fix a rather tricky bug (I run into it because the plot was not showing the correct connection lines):
The statement 'till <- which(ss[i,i:mx])' (line 282 in the original file) causes a bug because it does the following: First, it takes the i-th line of the matrix and removes the first (i-1) columns from it. Next, it computes (which-call) the indices of all TRUE-values in the _remaining_ vector. However, actually required are the indices in the _original_ i-th row (respecting the removed i-1 columns), i.e. the result from which() is too small by (i-1). By adding (i-1) after the which-call, the result was correct. Additionally, I added the 'till > i' condition because it might happen otherwise that there is a bar only "connecting" one workflow (e.g. if all pairwise differences are significant)
Finally my other changes are just removing the unused variable 'from' as well as fixing the code to avoid warnings (only the first element returned by which() is actually used).
Thanks
Björn
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant