smpl.doc
Simplified python code documentation.
|
Append doc string of |
|
Append a plot to a function. |
|
|
|
Inserts the docstring from passed function |
Inserts the function and its parameters and an equal sign. |
|
Inserts latexed code of a oneline function. |
|
Inserts latexed code of a oneline function with parameters. |
|
|
|
|
Add dict= {'key': [values...]} to a simple reST table. |
Functions
- smpl.doc.append_doc(original)[source]
Append doc string of
originaltotargetobject.- Parameters
- original
classorfunction orignal.__doc__is appended to the__doc__of thetarget
- original
Examples
>>> def ho(): ... '''Ho''' ... print(ho.__doc__) >>> @append_doc(ho) ... def hi(): ... '''Hi''' ... print(hi.__doc__) >>> hi() HiHo
- smpl.doc.insert_doc(original)[source]
Inserts the docstring from passed function
originalin thetargetfunction docstring.- Parameters
- original
classorfunction orignal.__doc__is inserted to the__doc__of thetarget
- original
Examples
>>> def ho(): ... '''Ho''' ... print(ho.__doc__) >>> @insert_doc(ho) ... def hi(): ... '''Hi''' ... print(hi.__doc__) >>> hi() HoHi