Skip to content

Conversation

@ryanmjacobs
Copy link

Fixes #406.

I have been running a similar patch for a few months now. Having the y-axis start at zero is fairly important :) 1 I have been using the -0 flag pretty much all of the time.

Finally got around to cleaning up my code. I'm not super familiar with Rust, so let me know it there are any changes needed to make the code more idiomatic.


  • Add options --ymin and --ymax for setting vertical scale
  • Option -0 is an alias for --ymin=0
  • Ensures at least 1 ms of y-axis when using --ymin=0
    • (Relevant for sub-ms hosts, e.g. gping -0 127.0.0.1)
# gping --help
.
  --ymin <YMIN> Set vertical axis min (ms)
  --ymax <YMAX> Set vertical axis max (ms)
  -0            Equivalent to --ymin=0
.

Comparison (before=bottom, after=top) gping -b10 --ymin 0 --ymax 500 3.80.0.0
comparison

Footnotes

  1. https://xkcd.com/2023/

Option `-0` is an alias for `--ymin=0`
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.

[Feature Request] Add command line options to for a fixed Y axis scale

1 participant