diff --git a/docs/environment.yml b/docs/environment.yml
index 4c446addbd..04c5561e15 100644
--- a/docs/environment.yml
+++ b/docs/environment.yml
@@ -3,23 +3,22 @@ channels:
- conda-forge
- defaults
dependencies:
- - python=3.5
+ - python=3.6
- mock # needed for local python 2.7 builds
- - numpy=1.11.2
+ - numpy=1.14.2
- scipy
- - tables
- - pandas=0.19.1
+ - pytables
+ - pandas=0.22.0
- pytz
- ephem
- numba
- - ipython=5.2.2
+ - ipython=6.3
- ipywidgets
- numpydoc
- - matplotlib=2.0.0
- - seaborn=0.7.1
- - siphon=0.4.0
- - sphinx=1.5
- - netCDF4=1.2.5
+ - matplotlib=2.2.2
+ - siphon=0.7.0
+ - sphinx=1.7.2
+ - netCDF4=1.3.1
- hdf4=4.2.12
- sphinx_rtd_theme
- docutils
diff --git a/docs/sphinx/source/clearsky.rst b/docs/sphinx/source/clearsky.rst
index c84cc857b6..e89b3c9d0e 100644
--- a/docs/sphinx/source/clearsky.rst
+++ b/docs/sphinx/source/clearsky.rst
@@ -40,11 +40,6 @@ We'll need these imports for the examples below.
In [1]: import pandas as pd
- # seaborn makes the plots look nicer
- In [1]: import seaborn as sns
-
- In [1]: sns.set_color_codes()
-
In [1]: import pvlib
In [1]: from pvlib import clearsky, atmosphere
@@ -142,18 +137,16 @@ the year. You could run it in a loop to create plots for all months.
In [1]: filepath = os.path.join(pvlib_path, 'data', 'LinkeTurbidities.h5')
- # data is in units of 20 x turbidity
- In [1]: lt_h5_file = tables.open_file(filepath)
-
In [1]: def plot_turbidity_map(month, vmin=1, vmax=100):
...: plt.figure();
- ...: plt.imshow(lt_h5_file.root.LinkeTurbidity[:, :, month-1], vmin=vmin, vmax=vmax);
+ ...: with tables.open_file(filepath) as lt_h5_file:
+ ...: ltdata = lt_h5_file.root.LinkeTurbidity[:, :, month-1]
+ ...: plt.imshow(ltdata, vmin=vmin, vmax=vmax);
+ ...: # data is in units of 20 x turbidity
...: plt.title('Linke turbidity x 20, ' + calendar.month_name[month]);
...: plt.colorbar(shrink=0.5);
...: plt.tight_layout();
- In [1]: lt_h5_file.close()
-
@savefig turbidity-1.png width=10in
In [1]: plot_turbidity_map(1)
@@ -228,7 +221,7 @@ A clear sky time series using only basic pvlib functions.
In [1]: linke_turbidity = pvlib.clearsky.lookup_linke_turbidity(times, latitude, longitude)
- In [1]: dni_extra = pvlib.irradiance.extraradiation(times.dayofyear)
+ In [1]: dni_extra = pvlib.irradiance.extraradiation(times)
# an input is a pandas Series, so solis is a DataFrame
In [1]: ineichen = clearsky.ineichen(apparent_zenith, airmass, linke_turbidity, altitude, dni_extra)
@@ -270,7 +263,7 @@ Grid with a clear sky irradiance for a few turbidity values.
In [1]: print('climatological linke_turbidity = {}'.format(linke_turbidity.mean()))
- In [1]: dni_extra = pvlib.irradiance.extraradiation(times.dayofyear)
+ In [1]: dni_extra = pvlib.irradiance.extraradiation(times)
In [1]: linke_turbidities = [linke_turbidity.mean(), 2, 4]
@@ -357,7 +350,7 @@ A clear sky time series using only basic pvlib functions.
In [1]: pressure = pvlib.atmosphere.alt2pres(altitude)
- In [1]: dni_extra = pvlib.irradiance.extraradiation(times.dayofyear)
+ In [1]: dni_extra = pvlib.irradiance.extraradiation(times)
# an input is a Series, so solis is a DataFrame
In [1]: solis = clearsky.simplified_solis(apparent_elevation, aod700, precipitable_water,
@@ -419,7 +412,7 @@ Grid with a clear sky irradiance for a few PW and AOD values.
In [1]: pressure = pvlib.atmosphere.alt2pres(altitude)
- In [1]: dni_extra = pvlib.irradiance.extraradiation(times.dayofyear)
+ In [1]: dni_extra = pvlib.irradiance.extraradiation(times)
In [1]: aod700 = [0.01, 0.1]
@@ -457,8 +450,6 @@ Contour plots of irradiance as a function of both PW and AOD.
...: precipitable_water, pressure,
...: dni_extra)
- In [1]: cmap = plt.get_cmap('viridis')
-
In [1]: n = 15
In [1]: vmin = None
@@ -468,8 +459,8 @@ Contour plots of irradiance as a function of both PW and AOD.
In [1]: def plot_solis(key):
...: irrad = solis[key]
...: fig, ax = plt.subplots()
- ...: im = ax.contour(aod700, precipitable_water, irrad[:, :], n, cmap=cmap, vmin=vmin, vmax=vmax)
- ...: imf = ax.contourf(aod700, precipitable_water, irrad[:, :], n, cmap=cmap, vmin=vmin, vmax=vmax)
+ ...: im = ax.contour(aod700, precipitable_water, irrad[:, :], n, vmin=vmin, vmax=vmax)
+ ...: imf = ax.contourf(aod700, precipitable_water, irrad[:, :], n, vmin=vmin, vmax=vmax)
...: ax.set_xlabel('AOD')
...: ax.set_ylabel('Precipitable water (cm)')
...: ax.clabel(im, colors='k', fmt='%.0f')
@@ -566,7 +557,7 @@ Now we run the synthetic data and clear sky estimate through the
fig, ax = plt.subplots()
- clear_samples.plot();
+ clear_samples.astype(int).plot();
@savefig detect-clear-detected.png width=10in
ax.set_ylabel('Clear (1) or Cloudy (0)');
diff --git a/docs/sphinx/source/forecasts.rst b/docs/sphinx/source/forecasts.rst
index f227328f02..a07dbb8bac 100644
--- a/docs/sphinx/source/forecasts.rst
+++ b/docs/sphinx/source/forecasts.rst
@@ -16,12 +16,14 @@ state-of-the-art of solar power forecasting.
pvlib-python uses Unidata's `Siphon
`_ library to simplify access
-to forecast data hosted on the Unidata `THREDDS catalog
+to real-time forecast data hosted on the Unidata `THREDDS catalog
`_. Siphon is great for
programatic access of THREDDS data, but we also recommend using tools
such as `Panoply `_
to easily browse the catalog and become more familiar with its contents.
+We do not know of a similarly easy way to access archives of forecast data.
+
This document demonstrates how to use pvlib-python to create a PV power
forecast using these tools. The `forecast
`_ for more information. Use the
HRRR, among others, if you want forecasts for less than 24 hours.
The HRRR model covers the continental United States.
@@ -354,8 +352,7 @@ RAP
The Rapid Refresh (RAP) model is the parent model for the HRRR. It is
updated every hour and runs at 40, 20, and 13 km resolutions. Only the
20 and 40 km resolutions are currently available in pvlib. It is also
-excels in severe weather situations. A major upgrade to the RAP model is
-expected in Spring, 2016. See the `NOAA ESRL HRRR page
+excels in severe weather situations. See the `NOAA ESRL HRRR page
`_ for more information. Use the
RAP, among others, if you want forecasts for less than 24 hours.
The RAP model covers most of North America.
@@ -471,7 +468,7 @@ Here's the forecast plane of array irradiance...
.. ipython:: python
- mc.ac.plot();
+ mc.ac.fillna(0).plot();
plt.ylim(0, None);
@savefig ac_power.png width=6in
plt.ylabel('AC Power (W)');
diff --git a/docs/sphinx/source/package_overview.rst b/docs/sphinx/source/package_overview.rst
index 78738125b2..3a245e368d 100644
--- a/docs/sphinx/source/package_overview.rst
+++ b/docs/sphinx/source/package_overview.rst
@@ -39,10 +39,6 @@ configuration at a handful of sites listed below.
import pandas as pd
import matplotlib.pyplot as plt
- # seaborn makes the plots look nicer
- import seaborn as sns
- sns.set_color_codes()
-
naive_times = pd.DatetimeIndex(start='2015', end='2016', freq='1h')
# very approximate
@@ -298,7 +294,7 @@ The pvlib-python community thanks Sandia National Lab
for developing PVLIB Matlab and for supporting
Rob Andrews of Calama Consulting to port the library to Python.
Will Holmgren thanks the DOE EERE Postdoctoral Fellowship program
-for support.
+for support from 2014-2016.
The pvlib-python maintainers thank all of pvlib's contributors of issues
and especially pull requests.
The pvlib-python community thanks all of the
diff --git a/docs/sphinx/source/timetimezones.rst b/docs/sphinx/source/timetimezones.rst
index b609220683..a28867cce6 100644
--- a/docs/sphinx/source/timetimezones.rst
+++ b/docs/sphinx/source/timetimezones.rst
@@ -297,12 +297,6 @@ Solar position
The correct solar position can be immediately calculated from the
DataFrame's index since the index has been localized.
-.. ipython:: python
- :suppress:
-
- import seaborn as sns
- sns.set_color_codes()
-
.. ipython:: python
solar_position = pvlib.solarposition.get_solarposition(tmy3_data.index,