Skip to content

Commit 7acbb88

Browse files
authored
minor documentation updates (#312)
* update python, ipython, matplotlib, sphinx * add notes about recommended solarposition methods * fix long table of contents on front page * mention marks new atmosphere functions in clearsky.rst * add notes about stackoverflow and google groups
1 parent 9b4af46 commit 7acbb88

File tree

6 files changed

+45
-18
lines changed

6 files changed

+45
-18
lines changed

docs/environment.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -3,22 +3,22 @@ channels:
33
- conda-forge
44
- defaults
55
dependencies:
6-
- python=2.7
6+
- python=3.5
77
- mock # needed for local python 2.7 builds
88
- numpy=1.11.2
99
- scipy
1010
- pandas=0.19.1
1111
- pytz
1212
- ephem
1313
- numba
14-
- ipython=4.0.1
14+
- ipython=5.2.2
1515
- ipywidgets
1616
- numpydoc
17-
- matplotlib=1.5.3
17+
- matplotlib=2.0.0
1818
- seaborn=0.7.1
1919
- siphon=0.4.0
20-
- sphinx=1.4.8
21-
- netCDF4=1.2.4
20+
- sphinx=1.5
21+
- netCDF4=1.2.5
2222
- hdf4=4.2.12
2323
- sphinx_rtd_theme
2424
- docutils

docs/sphinx/source/api.rst

+5
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,11 @@ Solar Position
3131

3232
Functions and methods for calculating solar position.
3333

34+
The :py:meth:`location.Location.get_solarposition` method and the
35+
:py:func:`solarposition.get_solarposition` function with default
36+
parameters are fast and accurate. We recommend using these functions
37+
unless you know that you need a different function.
38+
3439
.. autosummary::
3540
:toctree: generated/
3641

docs/sphinx/source/clearsky.rst

+4-1
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@ time series of clear sky data for a location. The :ref:`ineichen` and
2626
input data. The :ref:`detect_clearsky` subsection demonstrates the use
2727
of the clear sky detection algorithm.
2828

29+
The :py:func:`~pvlib.atmosphere.bird_hulstrom80_aod_bb`, and
30+
:py:func:`~pvlib.atmosphere.kasten96_lt` functions are useful for
31+
calculating inputs to the clear sky functions.
32+
2933
We'll need these imports for the examples below.
3034

3135
.. ipython::
@@ -498,7 +502,6 @@ See [Ine16]_.
498502
We encourage users to compare the pvlib implementation to Ineichen's
499503
`Excel tool <http://www.unige.ch/energie/fr/equipe/ineichen/solis-tool/>`_.
500504

501-
502505
.. _detect_clearsky:
503506

504507
Detect Clearsky

docs/sphinx/source/index.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ Contents
6868
========
6969

7070
.. toctree::
71-
:maxdepth: 5
71+
:maxdepth: 1
7272

7373
package_overview
7474
whatsnew

docs/sphinx/source/package_overview.rst

+11-1
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,17 @@ community via issues and pull requests.
272272

273273
Getting support
274274
---------------
275-
The best way to get support is to make an issue on our
275+
276+
pvlib usage questions can be asked on
277+
`Stack Overflow <http://stackoverflow.com>`_ and tagged with
278+
the `pvlib <http://stackoverflow.com/questions/tagged/pvlib>`_ tag.
279+
280+
The `pvlib-python google group <https://groups.google.com/forum/#!forum/pvlib-python>`_
281+
is used for discussing various topics of interest to the pvlib-python
282+
community. We also make new version announcements on the google group.
283+
284+
If you suspect that you may have discovered a bug or if you'd like to
285+
change something about pvlib, then please make an issue on our
276286
`GitHub issues page <https://github.com/pvlib/pvlib-python/issues>`_ .
277287

278288

pvlib/solarposition.py

+19-10
Original file line numberDiff line numberDiff line change
@@ -38,26 +38,33 @@ def get_solarposition(time, latitude, longitude,
3838
Parameters
3939
----------
4040
time : pandas.DatetimeIndex
41+
4142
latitude : float
43+
4244
longitude : float
45+
4346
altitude : None or float
4447
If None, computed from pressure. Assumed to be 0 m
4548
if pressure is also None.
49+
4650
pressure : None or float
4751
If None, computed from altitude. Assumed to be 101325 Pa
4852
if altitude is also None.
49-
method : string
50-
'pyephem' uses the PyEphem package: :func:`pyephem`
51-
52-
'nrel_c' uses the NREL SPA C code [3]: :func:`spa_c`
5353
54+
method : string
5455
'nrel_numpy' uses an implementation of the NREL SPA algorithm
55-
described in [1] (default): :func:`spa_python`
56+
described in [1] (default, recommended): :py:func:`spa_python`
5657
5758
'nrel_numba' uses an implementation of the NREL SPA algorithm
58-
described in [1], but also compiles the code first: :func:`spa_python`
59+
described in [1], but also compiles the code first:
60+
:py:func:`spa_python`
61+
62+
'pyephem' uses the PyEphem package: :py:func:`pyephem`
63+
64+
'ephemeris' uses the pvlib ephemeris code: :py:func:`ephemeris`
65+
66+
'nrel_c' uses the NREL SPA C code [3]: :py:func:`spa_c`
5967
60-
'ephemeris' uses the pvlib ephemeris code: :func:`ephemeris`
6168
temperature : float
6269
Degrees C.
6370
@@ -114,13 +121,15 @@ def spa_c(time, latitude, longitude, pressure=101325, altitude=0,
114121
raw_spa_output=False):
115122
"""
116123
Calculate the solar position using the C implementation of the NREL
117-
SPA code
124+
SPA code.
118125
119126
The source files for this code are located in './spa_c_files/', along with
120127
a README file which describes how the C code is wrapped in Python.
121128
Due to license restrictions, the C code must be downloaded seperately
122129
and used in accordance with it's license.
123130
131+
This function is slower and no more accurate than :py:func:`spa_python`.
132+
124133
Parameters
125134
----------
126135
time : pandas.DatetimeIndex
@@ -266,7 +275,7 @@ def spa_python(time, latitude, longitude,
266275
For most simulations specifing delta_t is sufficient.
267276
Difference between terrestrial time and UT1.
268277
*Note: delta_t = None will break code using nrel_numba,
269-
this will be fixed in a future version.
278+
this will be fixed in a future version.*
270279
The USNO has historical and forecasted delta_t [3].
271280
atmos_refrac : float, optional
272281
The approximate atmospheric refraction (in degrees)
@@ -807,7 +816,7 @@ def nrel_earthsun_distance(time, how='numpy', delta_t=67.0, numthreads=4):
807816
For most simulations specifing delta_t is sufficient.
808817
Difference between terrestrial time and UT1.
809818
*Note: delta_t = None will break code using nrel_numba,
810-
this will be fixed in a future version.
819+
this will be fixed in a future version.*
811820
By default, use USNO historical data and predictions
812821
813822
numthreads : int, optional

0 commit comments

Comments
 (0)