diff options
author | Sergey Grebenshchikov <sgreben@users.noreply.github.com> | 2018-03-30 16:22:25 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-03-30 16:22:25 +0200 |
commit | 5201bf26a3268a0cad21dcbf24f1b88158e0c5ad (patch) | |
tree | 6c8f28ddc21d4ad61b9e1a67acc51bf71728af0f | |
parent | 83d1d2f0a10ea93250746512992998418fe41479 (diff) | |
parent | faee861f58fca9e052126e698d275e107b575b2a (diff) |
Merge branch 'master' into patch-1
44 files changed, 13847 insertions, 580 deletions
diff --git a/.travis.yml b/.travis.yml index 676ebb1..73109e1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,12 +1,13 @@ language: go go: - "1.10" -script: make zip +script: make zip README.md deploy: provider: releases - api_key: "GITHUB OAUTH TOKEN" + api_key: + secure: "ZFj9EipPgHU5RLyzgOXx+dI4P3UOgwHb//dplU5YIQaSoaYutdakhmzqxVjwHl5UxyNGnUiUaaPS1TG+rfW3fV2ENA7+WTxGZCxPidLC2XQgMKfQyabGxA460A7VPdY8X1nVz2mZnbGa8VRNaI2Z8838Imivo1biKo07bySU850JsU0OFezZqDpC3I0TLsvBnLWszFjJxCUIPvrlQTZsAmtBtNPqmTuJB5HxPKKFaB1ScKmZT91MxBrdkn+s2jmv+ucSe4gz+ktnS2htfzDkbXBbFGVTA1FVXgIHyq/ErVLjC5RFOPXn4bv6HOSqfQ5X78ICQ3BdIPoq7XJt4goH1fBDe2xBLG/HKGZRe8nS7AuJb+DAlcl3qJp1miUldVNF9o0sjvYaw0rrhcRwXm6bR4HVQ34/9zGU4OxQMMRIMOGEIi5dnE9bcC0gyeqBkyI+zCwAGhZt5GfXpSzxSUfhSW3GkiuVVoZctpwRo+snbf+RzThDxuXe1ipHj7djkGs6YdLgEHXOnVF0lVrDH6sciiN+i4CDlHZqypERLVfcSAwOgz6Ulie54dW0CHj6y9IAz75LsphlSa2SUN8YLPeKPptvFhEiMGEC/KRWIws+h3o2lv1ff8DpK3sgf1IIKwPduZnCu5YNDc60qGiGtCc0v/MT+ykYV5aAJtbuWYG0+Ng=" file_glob: true file: release/* skip_cleanup: true on: - tags: true + tags: true
\ No newline at end of file @@ -1,27 +1,34 @@ -VERSION = 1.0.1 +VERSION = 1.1.5 APP := jp PACKAGES := $(shell go list -f {{.Dir}} ./...) GOFILES := $(addsuffix /*.go,$(PACKAGES)) GOFILES := $(wildcard $(GOFILES)) -.PHONY: clean release docker docker-latest - -# go get -u github.com/github/hub - -docker-latest: docker - docker tag quay.io/sergey_grebenshchikov/$(APP):v$(VERSION) quay.io/sergey_grebenshchikov/$(APP):latest - docker push quay.io/sergey_grebenshchikov/$(APP):latest +.PHONY: clean release release-ci release-manual docker docker-latest README.md clean: rm -rf binaries/ rm -rf release/ -release: zip +release-ci: README.md zip + +release: + git tag "$(VERSION)" + git push origin "$(VERSION)" + +# go get -u github.com/github/hub +release-manual: README.md zip git push - hub release delete $(VERSION) || true hub release create $(VERSION) -m "$(VERSION)" -a release/$(APP)_$(VERSION)_osx_x86_64.zip -a release/$(APP)_$(VERSION)_windows_x86_64.zip -a release/$(APP)_$(VERSION)_linux_x86_64.zip -a release/$(APP)_$(VERSION)_osx_x86_32.zip -a release/$(APP)_$(VERSION)_windows_x86_32.zip -a release/$(APP)_$(VERSION)_linux_x86_32.zip -a release/$(APP)_$(VERSION)_linux_arm64.zip +README.md: + sed "s/\$${VERSION}/$(VERSION)/g" README.template.md > README.md + +docker-latest: docker + docker tag quay.io/sergey_grebenshchikov/$(APP):v$(VERSION) quay.io/sergey_grebenshchikov/$(APP):latest + docker push quay.io/sergey_grebenshchikov/$(APP):latest + docker: binaries/linux_x86_64/$(APP) docker build -t quay.io/sergey_grebenshchikov/$(APP):v$(VERSION) . docker push quay.io/sergey_grebenshchikov/$(APP):v$(VERSION) @@ -1,22 +1,29 @@ # jp -Dead simple terminal plots from JSON data. Bar charts and line charts are supported. +Dead simple terminal plots from JSON (or CSV) data. Bar charts, line charts, and scatter plots are supported. + +[![Build Status](https://travis-ci.org/sgreben/jp.svg?branch=master)](https://travis-ci.org/sgreben/jp) <!-- TOC --> - [Get it](#get-it) - [Use it](#use-it) - [Examples](#examples) - - [Screenshots](#screenshots) - [Bar chart](#bar-chart) - [Separate X and Y values](#separate-x-and-y-values) - [XY pairs](#xy-pairs) - [Y values only (X=index)](#y-values-only-xindex) - [Array data](#array-data) - [Line chart](#line-chart) - - [Y values only (X=index)](#y-values-only-xindex-1) - [Array data, separate X and Y values](#array-data-separate-x-and-y-values) - [Array data, XY pairs](#array-data-xy-pairs) + - [Y values only (X=index)](#y-values-only-xindex-1) + - [Scatter plot](#scatter-plot) + - [Histogram](#histogram) + - [Auto bin number](#auto-bin-number) + - [Fixed bin number](#fixed-bin-number) + - [CSV input](#csv-input) +- [Screenshots](#screenshots) <!-- /TOC --> @@ -30,16 +37,16 @@ Or [download the binary](https://github.com/sgreben/jp/releases/latest) from the ```bash # Linux -curl -LO https://github.com/sgreben/jp/releases/download/1.0.1/jp_1.0.1_linux_x86_64.zip -unzip jp_1.0.1_linux_x86_64.zip +curl -LO https://github.com/sgreben/jp/releases/download/1.1.5/jp_1.1.5_linux_x86_64.zip +unzip jp_1.1.5_linux_x86_64.zip # OS X -curl -LO https://github.com/sgreben/jp/releases/download/1.0.1/jp_1.0.1_osx_x86_64.zip -unzip jp_1.0.1_osx_x86_64.zip +curl -LO https://github.com/sgreben/jp/releases/download/1.1.5/jp_1.1.5_osx_x86_64.zip +unzip jp_1.1.5_osx_x86_64.zip # Windows -curl -LO https://github.com/sgreben/jp/releases/download/1.0.1/jp_1.0.1_windows_x86_64.zip -unzip jp_1.0.1_windows_x86_64.zip +curl -LO https://github.com/sgreben/jp/releases/download/1.1.5/jp_1.1.5_windows_x86_64.zip +unzip jp_1.1.5_windows_x86_64.zip ``` ## Use it @@ -49,7 +56,7 @@ unzip jp_1.0.1_windows_x86_64.zip ```text Usage of jp: -type value - Plot type. One of [line bar] (default line) + Plot type. One of [line bar scatter hist] (default line) -x string x values (JSONPath expression) -y string @@ -60,33 +67,34 @@ Usage of jp: Plot height (default 0 (auto)) -width int Plot width (default 0 (auto)) + -canvas value + Canvas type. One of [full quarter braille auto] (default auto) + -bins uint + Number of histogram bins (default 0 (auto)) + -input value + Input type. One of [json csv] (default json) ``` ## Examples -### Screenshots - -In case you're on mobile, here's some PNGs of what `jp` output looks like: - -- ![Bar chart](docs/bar_chart.png) -- ![Line chart](docs/line_chart.png) - ### Bar chart #### Separate X and Y values ```bash $ cat examples/tcp-time.json | jp -x ..Label -y ..Count -type bar - 69.0 - █████████████ - █████████████ - █████████████ - █████████████ - █████████████ 21.0 - █████████████ █████████████ 7.0 2.0 1.0 - █████████████ █████████████ ▁▁▁▁▁▁▁▁▁▁▁▁▁ ▁▁▁▁▁▁▁▁▁▁▁▁▁ ▁▁▁▁▁▁▁▁▁▁▁▁▁ - 46.85267ms 48.38578ms 49.91889ms 51.452ms 52.98511ms + 69 + █████████████ + █████████████ + █████████████ + █████████████ + █████████████ + █████████████ 21 + █████████████ █████████████ 7 2 1 + █████████████ █████████████ ▄▄▄▄▄▄▄▄▄▄▄▄▄ ▁▁▁▁▁▁▁▁▁▁▁▁▁ ▁▁▁▁▁▁▁▁▁▁▁▁▁ + + 46.85267ms 48.38578ms 49.91889ms 51.452ms 52.98511ms ``` @@ -94,16 +102,18 @@ $ cat examples/tcp-time.json | jp -x ..Label -y ..Count -type bar ```bash $ cat examples/tcp-time.json | jp -xy "..[Label,Count]" -type bar - 69.0 - █████████████ - █████████████ - █████████████ - █████████████ - █████████████ 21.0 - █████████████ █████████████ 7.0 2.0 1.0 - █████████████ █████████████ ▁▁▁▁▁▁▁▁▁▁▁▁▁ ▁▁▁▁▁▁▁▁▁▁▁▁▁ ▁▁▁▁▁▁▁▁▁▁▁▁▁ - 46.85267ms 48.38578ms 49.91889ms 51.452ms 52.98511ms + 69 + █████████████ + █████████████ + █████████████ + █████████████ + █████████████ + █████████████ 21 + █████████████ █████████████ 7 2 1 + █████████████ █████████████ ▄▄▄▄▄▄▄▄▄▄▄▄▄ ▁▁▁▁▁▁▁▁▁▁▁▁▁ ▁▁▁▁▁▁▁▁▁▁▁▁▁ + + 46.85267ms 48.38578ms 49.91889ms 51.452ms 52.98511ms ``` #### Y values only (X=index) @@ -111,16 +121,17 @@ $ cat examples/tcp-time.json | jp -xy "..[Label,Count]" -type bar ```bash $ cat examples/tcp-time.json | jp -y ..Count -type bar - 69.0 - █████████████ - █████████████ - █████████████ - █████████████ - █████████████ 21.0 - █████████████ █████████████ 7.0 2.0 1.0 - █████████████ █████████████ ▁▁▁▁▁▁▁▁▁▁▁▁▁ ▁▁▁▁▁▁▁▁▁▁▁▁▁ ▁▁▁▁▁▁▁▁▁▁▁▁▁ - - 0 1 2 3 4 + 69 + █████████████ + █████████████ + █████████████ + █████████████ + █████████████ + █████████████ 21 + █████████████ █████████████ 7 2 1 + █████████████ █████████████ ▄▄▄▄▄▄▄▄▄▄▄▄▄ ▁▁▁▁▁▁▁▁▁▁▁▁▁ ▁▁▁▁▁▁▁▁▁▁▁▁▁ + + 0 1 2 3 4 ``` #### Array data @@ -128,83 +139,235 @@ $ cat examples/tcp-time.json | jp -y ..Count -type bar ```bash $ echo '[[-3, 5], [-2, 0], [-1, 0.1], [0, 1], [1, 2], [2, 3]]' | jp -xy '[*][0, 1]' -type bar - 5.0 - ███████████ - ███████████ - ███████████ 3.0 - ███████████ ███████████ - ███████████ 2.0 ███████████ - ███████████ 0.0 0.1 1.0 ███████████ ███████████ - ███████████ ▁▁▁▁▁▁▁▁▁▁▁ ███████████ ███████████ ███████████ - - -3 -2 -1 0 1 2 + 5 + ███████████ + ███████████ + ███████████ 3 + ███████████ ▄▄▄▄▄▄▄▄▄▄▄ + ███████████ 2 ███████████ + ███████████ 1 ███████████ ███████████ + ███████████ 0.1 ▄▄▄▄▄▄▄▄▄▄▄ ███████████ ███████████ + ███████████ 0 ▁▁▁▁▁▁▁▁▁▁▁ ███████████ ███████████ ███████████ + + -3 -2 -1 0 1 2 ``` ### Line chart +#### Array data, separate X and Y values + +```bash +$ jq -n '[range(200)/20 | [., sin]]' | jp -x '[*][0]' -y '[*][1]' + 1.059955│ ▄▄▄▖ ▗▄▄▄▖ + │ ▄▀▘ ▝▜▖ ▗▞▘ ▝▚ + │ ▟ ▝▄ ▗▀ ▜ + │ ▟ ▝▄ ▗▀ ▜ + │ ▐ ▝▖ ▗▞ ▚▖ + │ ▗▘ ▝▖ ▞ ▚ + │ ▗▘ ▚ ▞ ▌ + │ ▌ ▌ ▗▘ ▝▖ + │ ▞ ▝▖ ▌ ▚ + │▗▘ ▚ ▞ ▌ + │▌ ▌ ▗▘ ▝▖ + │ ▝▖ ▗▘ ▐ + │ ▐ ▞ ▚ + │ ▚ ▐ ▝▖ + │ ▝▖ ▗▘ ▐ + │ ▐ ▞ ▚ + │ ▀▖ ▐ + │ ▚ ▄▘ + │ ▙ ▗▘ + │ ▚ ▄▘ + │ ▚▄ ▗▞▘ + │ ▝▀▀▀▘ + -1.059955└───────────────────────────────────────────────────────────────────── + 0 9.95 +``` + +#### Array data, XY pairs + +```bash +$ jq -n '[range(200)/20 | [., sin]]' | jp -xy '[*][0, 1]' + 1.059955│ ▄▄▄▖ ▗▄▄▄▖ + │ ▄▀▘ ▝▜▖ ▗▞▘ ▝▚ + │ ▟ ▝▄ ▗▀ ▜ + │ ▟ ▝▄ ▗▀ ▜ + │ ▐ ▝▖ ▗▞ ▚▖ + │ ▗▘ ▝▖ ▞ ▚ + │ ▗▘ ▚ ▞ ▌ + │ ▌ ▌ ▗▘ ▝▖ + │ ▞ ▝▖ ▌ ▚ + │▗▘ ▚ ▞ ▌ + │▌ ▌ ▗▘ ▝▖ + │ ▝▖ ▗▘ ▐ + │ ▐ ▞ ▚ + │ ▚ ▐ ▝▖ + │ ▝▖ ▗▘ ▐ + │ ▐ ▞ ▚ + │ ▀▖ ▐ + │ ▚ ▄▘ + │ ▙ ▗▘ + │ ▚ ▄▘ + │ ▚▄ ▗▞▘ + │ ▝▀▀▀▘ + -1.059955└───────────────────────────────────────────────────────────────────── + 0 9.95 +``` + #### Y values only (X=index) ```bash $ cat examples/tcp-time.json | jp -y ..Duration + 5.726165e+07│ + │ + │ + │ + │ ▗ + │ ▟ + │ █ + │▐▝▖ + │▐ ▌ ▌ + │▐ ▌ ▌ + │▌ ▌ ▐▚ + │▌ ▌ ▗ ▗ ▐▐ ▌ + │▘ ▌ ▖ ▐ ▞▀▖ ▐▐ ▌ + │ ▚ ▐▚ ▗▀▖ ▗▚ ▌▌ ▗▘ ▌ ▖▗▀▌ ▌▐ █ + │ ▐ ▛▌ ▚▖▞ ▚▐▖ ▞▐ ▌▌ ▗ ▐ ▐▟▐▞ ▚ ▗ ▌▝▖ ▐▐ ▐ + │ ▐ ▐ ▝ ▝▌▝▀ ▝▟ ▚▗▜ ▞ ▘ ▐▖█▗▘ ▌ ▐▐ ▗ ▄▖ ▄▖ ▌▌ + │ ▝▚▐ ▘ ▘ ▐▘▝▖▄▌ ▝▝▟ ▀▀▚▟ ▌ ▖▞▘▌▐ ▚ ▗▄ ▐ ▚▄▖ ▄ ▄▘▌▞▄▄▀▚ ▄ ▄▗▞▖▞▄▄▚ + │ ▝▌ ▛ ▌ ▝ ▙▞▝ ▝▘ ▝▚▘ ▀▘ ▝▀ ▀ ▐▘ ▚▞▀ ▀ ▘ ▚▘ + │ + │ + │ + │ + 4.446018e+07└────────────────────────────────────────────────────────────────────────────────────── + 0 99 +``` -59970040.9│ - │ - │ - │ █ - │██ - │██ █ - │█ █ █ █ - y█ █ ██ ██ █ █ ███ ███ █ █ █ - │ ██ ██ ███ ████ ███ ██ █ ██ █ ███ █ ██ █ █ ██ ██ ██ ██ █ ██ █ █ █ █ - │ █ █ ██ █ ██ ████ ██ █████ ██████ █ ██ ████████ █ ██ █ - │ - │ - │ -42167403.0└───────────────────────────────────────x───────────────────────────────────────────────── - 0.0 99.0 +### Scatter plot +```bash +$ cat examples/mvrnorm.json | jp -xy '..[x,y]' -type scatter + + 3.535344│ ⠄ ⠄ + │ ⠈⠂ ⠂ ⡀ ⠂ + │ ⠐⡀⡀⡂ ⠁ ⢄ ⠁ ⠠ + │ ⡀ ⠆ ⠈ ⠄⡀ ⠂ + │ ⡀ ⠠ ⡀ ⡀ ⠄ ⡀⠐⠄⠁⠐ ⠠⢆⠠⠂⠂⠄⣀⢈ ⡀⠈ ⡀ + │ ⡀⠂⠂⠄ ⡀⠂⢔⠠ ⢤⢀⠌⣡⠁⠦⠄⠐⡐⠂⣀⠅⠁⠈ ⠂ ⠈⠁⠁ ⡀ ⠄ + │ ⡀ ⢀ ⠄ ⠈⠠ ⠡⠑⠈⠈⢢⡁⡄⢈⠂⢡⠈⡄⡀⠈⠰⢉⡠⠘⢄⢃⠉⢀⣄⠢⠠⠄ ⠠ ⡀⠁ ⡀ ⠂ + │ ⠈ ⡂⠈⡁⠈⠄⢂⡹⡐⡡⡆⡥⣙⡶⡼⠱⣅⣅⣼⢗⡱⢐⣈⠑⢁⠂ ⢐⢁⠭⠘⡀ ⠈ + │ ⠁ ⢀⠄⢈⠈⡰⢀⡥⠋⣧⣓⣚⡛⢲⣽⣝⣭⢙⣟⢲⡽⣋⡠⣿⣜⣵⠙⡦⠗ ⣡⠁⠁⠁⠄⠠ ⠄⡂ + │ ⠄⠌⠌⠡⠉⡐⢯⣵⡏⢵⡞⠂⢰⣽⣷⢛⣯⡣⣷⢭⣞⣏⠤⣾⢡⡻⠢⢊⢠⡠⠸⢄⣃⡀⢁⠐ ⠐⡀ ⠂ ⠄ + │ ⠨ ⡈⠂ ⢀⢑⠄⣜⡾⣴⢨⠶⣪⣧⢿⣷⣷⡱⣿⣞⣲⣮⣮⣯⢾⡷⡬⡷⣺⠤⢏⡼⣨⢌⡬⠠⢂⢠⠒⠱⠆⡈ + │ ⠈ ⠃ ⠄⡐⠂⠐⢀⢈⣂⡈⣳⣷⣜⢺⣿⣹⣷⣼⣯⡿⣃⣽⣿⢾⣟⣾⢵⣻⠯⡼⡃⣼⣗⢲⠪⠇⣉⠺ ⢱⠠⠙⡀⢐⠌ + │ ⠄ ⠈⠊⠐⠑⠨⠚⢁⡊⢾⡶⢩⢿⣏⣽⢞⣼⣇⣵⣿⣿⣽⣿⢽⣭⠺⣿⣽⣳⢚⣾⣻⣾⣜⠩⡒⣃⠈⢢⠕⢂⢰⡀ ⡔⢀⢀ ⡀ + │ ⢀⠂⠁⠂⠇ ⠂⠊⢀⠐⡘⡍⡇⣚⢸⢟⣯⢿⣳⡪⣫⣵⣿⣯⣿⢿⣷⣻⣖⣗⣻⣚⢥⡷⣕⣏⠶⠊⠄⣠⠰⠂⡄⠂ ⠄⠁ + │ ⠠⢂ ⠘⠐⣀ ⣀⢡⢐⠔⢫⠯⢕⠫⠿⣹⢶⣾⡻⣭⣽⢗⠿⣹⣛⣺⣿⠯⢲⡼⣵⢉⣭⢐⣟⡍⠄⠈⠥⠄ ⠁ ⠄ + │ ⠈⠂ ⠊⡀⡈⠢⡌⡠⠖⢤⠥⡑⣯⣾⣴⣯⡿⣯⣝⣯⣿⠧⣽⣒⢾⣼⣻⣛⣗⡹⡽⢪⠯⠒⡨⠈ ⠈⡐⢄ ⠂⠘⠠ ⠂ + │ ⠰ ⡀⠃⠁⠠ ⠉⡈⡨⡱⢍⠌⠷⣯⠫⠬⡙⣴⣯⡣⡟⡮⠩⣫⠿⢞⢵⡰⠞⡂⠴ ⠕⢀⡂⠁ ⢀ ⠤ ⠈ + │ ⢩⠂ ⠁⡄ ⢀⠲⢂⠑⢁⡘⠄⠵⣣⢑⢻⠨⡩⣌⠕⢮⣮⣋⢹⡁⣊⡃⠈⡕⡘⡠⠨⠄⡘⠨ ⠊⠁ ⠂ + │ ⠐ ⢀ ⠈⠐⠔⠈ ⠁⢀⣀⡃⣊⢁⡘⠁⠛⠨ ⠒⡑⡀⠵⢙⠄⠡⠢⠃⠄⠋⠅ ⠥⠁⠠⢀ ⠄ + │ ⢀⢁ ⠆ ⠉⠁⠐ ⠄⠁⢑⡀⢀⠠⠑⢡⢊⠂⠑⠌⡅⠊⠄⠉⢈⡐ ⡀ ⠠ ⠂ + │ ⢀ ⠑ ⠂ ⡁ ⠌⢠⠈⠂⠄⠉⡃⠈⠄ ⠂⠠⠁ ⠄ ⢀ ⠠ + │ ⠐ ⠐ ⢁⠂⠂⠢⠠⠄⠔⠐ ⠁ + │ ⠢ ⠁ ⠂⠐ ⠐ ⠐ ⠈ + │ ⢀ ⠄⠈ ⠈ + │ ⠐ + │ + │ + │ ⠈ +-4.271874└───────────────────────────────────────────────────────────────────── + -4.08815 3.79083 ``` -#### Array data, separate X and Y values +### Histogram -```bash -$ jq -n '[range(200)/20 | [., sin]]' | jp -x '[*][0]' -y '[*][1]' +#### Auto bin number -1.1 │ ███████ ██████ - │ ███ ███ ███ ███ - │ ███ ██ ██ ███ - │ ██ ███ ██ ██ - │ █ ██ ██ ███ - │██ ██ ██ ██ - │█ █ ██ ██ - y █ ██ █ - │ ██ ██ ██ - │ ██ ██ ██ - │ ██ ██ - │ ██ ████ - │ ██████ --1.1└───────────────────────────────────x─────────────────────────────────────── - 0.0 9.9 +``` +$ cat examples/mvrnorm.json | jp -x ..x -type hist + 684 1 [-3.27033,-2.69856) + █████▌ 2 [-2.69856,-2.12679) + █████▌ 624 3 [-2.12679,-1.55502) + ███████████ 4 [-1.55502,-0.983254) + 557 ███████████ 5 [-0.983254,-0.411485) + ▐████████████████ 6 [-0.411485,0.160285) + ▐████████████████ 7 [0.160285,0.732054) + ▐████████████████ 8 [0.732054,1.30382) + ▐████████████████ 9 [1.30382,1.87559) + ▐████████████████ 404 10 [1.87559,2.44736) + ▐█████████████████████▌ 11 [2.44736,3.01913) + 314 ▐█████████████████████▌ 12 [3.01913,3.5909] + ▄▄▄▄▄▟█████████████████████▌ + ███████████████████████████▌ + ███████████████████████████▌ + ███████████████████████████▌ + ███████████████████████████▌ 176 + █████████████████████████████████ + 98 █████████████████████████████████ + ▐██████████████████████████████████████ 79 + 1 4 41 ▐███████████████████████████████████████████ 14 4 + ▁▁▁▁▁▁▁▁▁▁▁█████████████████████████████████████████████████▁▁▁▁▁▁▁▁▁▁▁ + + 0 1 2 3 4 5 6 7 8 9 10 11 12 ``` -#### Array data, XY pairs +#### Fixed bin number -```bash -$ jq -n '[range(200)/20 | [., sin]]' | jp -xy '[*][0, 1]' +``` +$ cat examples/mvrnorm.json | jp -x ..x -type hist -bins 5 + 1652 + █████████████████ + █████████████████ + █████████████████ + █████████████████ + █████████████████ + █████████████████ + █████████████████ + |