Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix issue 11712 "Function _plot_connectivity_circle connects nodes with score zero" #12210

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

aweinstein
Copy link
Contributor

@aweinstein aweinstein commented Nov 15, 2023

Reference issue

Fixes #11712 .

What does this implement/fix?

Now function _plot_connectivity_circle only shows links between nodes when the score between nodes is larger than zero.

@drammock
Copy link
Member

just a note that I'm about to head on holiday for a week and wasn't able to review this beforehand. My apologies; hopefully another dev has time to look at it sooner. Otherwise I'll take a look sometime early in December.

@larsoner
Copy link
Member

larsoner commented Dec 1, 2023

My only reservation with this is that I'm not sure we can guarantee a connectivity score of zero is meaningless, even if it is for most/many measures. For example if you had a measure that gave you the phase shift (in rad or deg) or group delay (in ms or whatever) between regions, zero is a reasonable value and you'd want to know the connection was instantaneous.

@aweinstein
Copy link
Contributor Author

My only reservation with this is that I'm not sure we can guarantee a connectivity score of zero is meaningless.

You have the same issue if you use this function with the default parameter values: The black lines, corresponding to zero values, cannot be seen because they have the same color as the background.

We could add a threshold parameter (default value to zero) such that lines are plotted only if values are larger than this threshold.

@drammock
Copy link
Member

drammock commented Dec 4, 2023

You have the same issue if you use this function with the default parameter values: The black lines, corresponding to zero values, cannot be seen because they have the same color as the background.

Changing the colormap can address this. That said, I like the idea of having a threshold parameter. It's going to interact with the n_lines parameter, so we'd need to decide how to handle that (probably threshold should trump n_lines when they disagree, i.e., if n_lines is 20 but there are only 18 suprathreshold, we show 18. Also need to decide how to handle threshold when the connectivity measure can be positive/negative.

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.

Function _plot_connectivity_circle connects nodes with score zero
3 participants