Skip to content

Instantly share code, notes, and snippets.

@ckhung
Last active October 15, 2017 09:41
Show Gist options
  • Save ckhung/0aae431675084fb537e8cc4cd078ac7f to your computer and use it in GitHub Desktop.
Save ckhung/0aae431675084fb537e8cc4cd078ac7f to your computer and use it in GitHub Desktop.
draw a few similar gaussian distributions
#!/usr/bin/gnuplot
# http://gnuplot.sourceforge.net/demo/transparent.html
Gauss(x,mu,sigma) = 1./(sigma*sqrt(2*pi)) * exp( -(x-mu)**2 / (2*sigma**2) )
set xrange [-4:4]
plot \
Gauss(x,0.03,1.02) title '', \
Gauss(x,-0.05,1.03) title '', \
Gauss(x,0.05,0.98) title '', \
Gauss(x,0.02,0.97) title '', \
Gauss(x,-0.02,0.96) title ''
set term svg ; set output "similar-distro.svg" ; replot
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment