Introduction
Introduction Statistics Contact Development Disclaimer Help
tadd histpdf - numtools - perform numerical operations on vectors and matrices …
git clone git://src.adamsgaard.dk/numtools
Log
Files
Refs
README
LICENSE
---
commit 28866edd3b5db9c04759e3ffa034d698ba2022fd
parent 73826473ebdf93c722546afd28b60b783ae38abf
Author: Anders Damsgaard <[email protected]>
Date: Thu, 25 Mar 2021 21:03:42 +0100
add histpdf
Diffstat:
M Makefile | 8 +++++++-
A histpdf | 11 +++++++++++
A histpdf.1 | 21 +++++++++++++++++++++
3 files changed, 39 insertions(+), 1 deletion(-)
---
diff --git a/Makefile b/Makefile
t@@ -8,7 +8,13 @@ PREFIX = /usr/local
MANPREFIX = ${PREFIX}/man
DOCPREFIX = ${PREFIX}/share/doc/${NAME}
-SCRIPTS = mean max min sum rangetest
+SCRIPTS = \
+ histpdf\
+ max\
+ mean\
+ min\
+ rangetest\
+ sum
MAN1 = ${SCRIPTS:=.1}
DOC = \
diff --git a/histpdf b/histpdf
t@@ -0,0 +1,11 @@
+#!/bin/sh
+f="$(mktemp)"
+cat > "$f"
+gnuplot -e "set term unknown;\
+ plot '${f}' using 0:1;\
+ set term pdf;\
+ nbins=10;\
+ binwidth=(GPVAL_DATA_Y_MAX - GPVAL_DATA_Y_MIN) / nbins;\
+ bin(x,width)=width * floor(x / width);\
+ plot '${f}' using (bin(\$1, binwidth)):(1.0) smooth freq with boxe…
+rm -f "$f"
diff --git a/histpdf.1 b/histpdf.1
t@@ -0,0 +1,21 @@
+.Dd $Mdocdate$
+.Dt HISTPDF 1
+.Os
+.Sh NAME
+.Nm histpdf
+.Nd plots a histogram of values in the first column
+.Sh SYNOPSIS
+.Nm
+.Sh DESCRIPTION
+The
+.Nm
+outputs a PDF plot, so make sure to redirect the standard output to
+another program or to a file.
+.Sh SEE ALSO
+.Xr gnuplot 1 ,
+.Xr max 1 ,
+.Xr mean 1 ,
+.Xr min 1 ,
+.Xr sum 1
+.Sh AUTHORS
+.An Anders Damsgaard Aq Mt [email protected]
You are viewing proxied material from mx1.adamsgaard.dk. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.