|
From: <jd...@us...> - 2008-05-16 20:10:00
|
Revision: 5156
http://matplotlib.svn.sourceforge.net/matplotlib/?rev=5156&view=rev
Author: jdh2358
Date: 2008-05-16 13:09:54 -0700 (Fri, 16 May 2008)
Log Message:
-----------
moved new hist examples to pylab
Added Paths:
-----------
trunk/matplotlib/examples/pylab/histogram_demo_cumulative.py
trunk/matplotlib/examples/pylab/histogram_demo_step.py
Removed Paths:
-------------
trunk/matplotlib/examples/histogram_demo_cumulative.py
trunk/matplotlib/examples/histogram_demo_step.py
Deleted: trunk/matplotlib/examples/histogram_demo_cumulative.py
===================================================================
--- trunk/matplotlib/examples/histogram_demo_cumulative.py 2008-05-16 20:09:09 UTC (rev 5155)
+++ trunk/matplotlib/examples/histogram_demo_cumulative.py 2008-05-16 20:09:54 UTC (rev 5156)
@@ -1,33 +0,0 @@
-#!/usr/bin/env python
-from pylab import *
-
-mu, sigma = 100, 25
-x = mu + sigma*randn(10000)
-
-# the histogram of the data
-n, bins, patches = hist(x, 50, normed=1, histtype='step', cumulative=True)
-setp(patches, 'facecolor', 'g', 'alpha', 0.75)
-
-# add a 'best fit' line
-y = normpdf( bins, mu, sigma).cumsum()
-y /= y[-1]
-l = plot(bins, y, 'k--', linewidth=1.5)
-
-# overlay the first histogram with a second one
-# were the data has a smaller standard deviation
-mu, sigma = 100, 10
-x = mu + sigma*randn(10000)
-
-n, bins, patches = hist(x, bins=bins, normed=1, histtype='step', cumulative=True)
-setp(patches, 'facecolor', 'r', 'alpha', 0.25)
-
-# add a 'best fit' line
-y = normpdf( bins, mu, sigma).cumsum()
-y /= y[-1]
-l = plot(bins, y, 'k--', linewidth=1.5)
-
-grid(True)
-ylim(0, 1.1)
-
-#savefig('histogram_demo',dpi=72)
-show()
\ No newline at end of file
Deleted: trunk/matplotlib/examples/histogram_demo_step.py
===================================================================
--- trunk/matplotlib/examples/histogram_demo_step.py 2008-05-16 20:09:09 UTC (rev 5155)
+++ trunk/matplotlib/examples/histogram_demo_step.py 2008-05-16 20:09:54 UTC (rev 5156)
@@ -1,31 +0,0 @@
-#!/usr/bin/env python
-from pylab import *
-
-mu, sigma = 100, 15
-x = mu + sigma*randn(10000)
-
-# the histogram of the data
-n, bins, patches = hist(x, 50, normed=1, histtype='step')
-setp(patches, 'facecolor', 'g', 'alpha', 0.75)
-
-# add a 'best fit' line
-y = normpdf( bins, mu, sigma)
-l = plot(bins, y, 'k--', linewidth=1)
-
-
-# overlay the first histogram with a second one
-# were the data has a smaller standard deviation
-mu, sigma = 100, 5
-x = mu + sigma*randn(10000)
-
-n, bins, patches = hist(x, 50, normed=1, histtype='step')
-setp(patches, 'facecolor', 'r', 'alpha', 0.25)
-
-y = normpdf( bins, mu, sigma)
-l = plot(bins, y, 'k--', linewidth=1)
-
-axis([40, 160, 0, 0.09])
-grid(True)
-
-#savefig('histogram_demo',dpi=72)
-show()
Copied: trunk/matplotlib/examples/pylab/histogram_demo_cumulative.py (from rev 5154, trunk/matplotlib/examples/histogram_demo_cumulative.py)
===================================================================
--- trunk/matplotlib/examples/pylab/histogram_demo_cumulative.py (rev 0)
+++ trunk/matplotlib/examples/pylab/histogram_demo_cumulative.py 2008-05-16 20:09:54 UTC (rev 5156)
@@ -0,0 +1,33 @@
+#!/usr/bin/env python
+from pylab import *
+
+mu, sigma = 100, 25
+x = mu + sigma*randn(10000)
+
+# the histogram of the data
+n, bins, patches = hist(x, 50, normed=1, histtype='step', cumulative=True)
+setp(patches, 'facecolor', 'g', 'alpha', 0.75)
+
+# add a 'best fit' line
+y = normpdf( bins, mu, sigma).cumsum()
+y /= y[-1]
+l = plot(bins, y, 'k--', linewidth=1.5)
+
+# overlay the first histogram with a second one
+# were the data has a smaller standard deviation
+mu, sigma = 100, 10
+x = mu + sigma*randn(10000)
+
+n, bins, patches = hist(x, bins=bins, normed=1, histtype='step', cumulative=True)
+setp(patches, 'facecolor', 'r', 'alpha', 0.25)
+
+# add a 'best fit' line
+y = normpdf( bins, mu, sigma).cumsum()
+y /= y[-1]
+l = plot(bins, y, 'k--', linewidth=1.5)
+
+grid(True)
+ylim(0, 1.1)
+
+#savefig('histogram_demo',dpi=72)
+show()
\ No newline at end of file
Copied: trunk/matplotlib/examples/pylab/histogram_demo_step.py (from rev 5154, trunk/matplotlib/examples/histogram_demo_step.py)
===================================================================
--- trunk/matplotlib/examples/pylab/histogram_demo_step.py (rev 0)
+++ trunk/matplotlib/examples/pylab/histogram_demo_step.py 2008-05-16 20:09:54 UTC (rev 5156)
@@ -0,0 +1,31 @@
+#!/usr/bin/env python
+from pylab import *
+
+mu, sigma = 100, 15
+x = mu + sigma*randn(10000)
+
+# the histogram of the data
+n, bins, patches = hist(x, 50, normed=1, histtype='step')
+setp(patches, 'facecolor', 'g', 'alpha', 0.75)
+
+# add a 'best fit' line
+y = normpdf( bins, mu, sigma)
+l = plot(bins, y, 'k--', linewidth=1)
+
+
+# overlay the first histogram with a second one
+# were the data has a smaller standard deviation
+mu, sigma = 100, 5
+x = mu + sigma*randn(10000)
+
+n, bins, patches = hist(x, 50, normed=1, histtype='step')
+setp(patches, 'facecolor', 'r', 'alpha', 0.25)
+
+y = normpdf( bins, mu, sigma)
+l = plot(bins, y, 'k--', linewidth=1)
+
+axis([40, 160, 0, 0.09])
+grid(True)
+
+#savefig('histogram_demo',dpi=72)
+show()
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|