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

Proposal: Median option #54

Open
yuonoda opened this issue Jun 26, 2024 · 2 comments
Open

Proposal: Median option #54

yuonoda opened this issue Jun 26, 2024 · 2 comments

Comments

@yuonoda
Copy link

yuonoda commented Jun 26, 2024

Hey, thank you for your providing nice tool !
I would like you to add new option to show median of cyclomatic complexity.

I often meet occasions that a distribution of cyclomatic complexity in my code is highly skewed.
For example, a complexity of almost all functions in my repo is around 1.
But, a little functions marks 10 to 100 complexity.
In such case, average complexity tend to be higher than median or mode, so cannot capture whole trend.

I propose to inplement median option to this command like this,

    -med, -med-short      show the median complexity over all functions;
                          the short option prints the value without a label

This should be helpful for those who meet same issue with me.

Thanks,

@fzipp
Copy link
Owner

fzipp commented Jun 26, 2024

I agree that the median is useful. Would you like to implement it and create a pull request?

@fzipp
Copy link
Owner

fzipp commented Jul 7, 2024

Someone created a pull request for a percentile option: #55
This would cover the median as the 50th percentile. You may want to provide your input there as well.

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

No branches or pull requests

2 participants