Last active
April 7, 2016 23:02
-
-
Save whophil/878a38b4aa2201e2325e88abe99a645e to your computer and use it in GitHub Desktop.
Docstring for Python method (NumPy-style, for Sphinx compatibility)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""One line description of a module level function. | |
The longer, optionally multi-line description goes here. This may have multiple | |
sentences and multiple lines. | |
Parameters | |
---------- | |
param1 : int | |
The first parameter. | |
param2 : Optional[str] | |
The second parameter. | |
*args | |
Variable length argument list. | |
**kwargs | |
Arbitrary keyword arguments. | |
Returns | |
------- | |
return_var1 : bool | |
True if successful, False otherwise. | |
return_var2 : float | |
The area of a square. | |
Raises | |
------ | |
AttributeError | |
The ``Raises`` section is a list of all exceptions | |
that are relevant to the interface. | |
ValueError | |
If `param2` is equal to `param1`. | |
""" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment