Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 3ed0430

Browse files
committed
modifications to examples/docs to get them to build for the website
svn path=/trunk/matplotlib/; revision=7196
1 parent 9f84f4f commit 3ed0430

4 files changed

Lines changed: 5 additions & 33 deletions

File tree

doc/pyplots/matplotlibrc

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@
2727
# the default backend; one of GTK GTKAgg GTKCairo FltkAgg QtAgg TkAgg
2828
# WX WXAgg Agg Cairo GD GDK Paint PS PDF SVG Template
2929
backend : Agg
30-
numerix : numpy # numpy, Numeric or numarray
3130
#maskedarray : False # True to use external maskedarray module
3231
# instead of numpy.ma; this is a temporary
3332
# setting for testing maskedarray.

doc/pyplots/tex_demo.png

62 Bytes
Loading

examples/pylab_examples/finance_work2.py

Lines changed: 4 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,5 @@
1-
## Plot the stock price with some technical indicators
2-
## Example usage::
3-
## python stocks2.py --ticker=GE --startdate=2003
4-
##
5-
import datetime, os, urllib, optparse
1+
import datetime
62
import numpy as np
7-
import dateutil.parser
83
import matplotlib.colors as colors
94
import matplotlib.finance as finance
105
import matplotlib.dates as mdates
@@ -13,32 +8,10 @@
138
import matplotlib.pyplot as plt
149
import matplotlib.font_manager as font_manager
1510

16-
today = datetime.date.today()
1711

18-
optionparser = optparse.OptionParser()
19-
20-
optionparser.add_option('-t', '--ticker',
21-
dest='ticker',
22-
help='a stock market ticker',
23-
default='SPY')
24-
25-
optionparser.add_option('-s', '--startdate',
26-
dest='startdate',
27-
help='the start date',
28-
default=(today-datetime.timedelta(days=365*2)).strftime('%Y-%m-%d'))
29-
30-
optionparser.add_option('-e', '--enddate',
31-
dest='enddate',
32-
help='the end date',
33-
default=today.strftime('%Y-%m-%d'))
34-
35-
36-
(commandoptions, commandargs) = optionparser.parse_args()
37-
38-
39-
startdate = dateutil.parser.parse(commandoptions.startdate)
40-
enddate = dateutil.parser.parse(commandoptions.enddate)
41-
ticker = commandoptions.ticker
12+
startdate = datetime.date(2006,1,1)
13+
today = enddate = datetime.date.today()
14+
ticker = 'SPY'
4215

4316

4417
fh = finance.fetch_historical_yahoo(ticker, startdate, enddate)

lib/matplotlib/axes.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6019,7 +6019,7 @@ def fill_between(self, x, y1, y2=0, where=None, **kwargs):
60196019
60206020
%(PolyCollection)s
60216021
6022-
.. plot:: mpl_examples/pylab_examples/fill_between_demo.py.py
6022+
.. plot:: mpl_examples/pylab_examples/fill_between_demo.py
60236023
60246024
.. seealso::
60256025

0 commit comments

Comments
 (0)