natcap.invest.nearshore_wave_and_erosion package

Submodules

natcap.invest.nearshore_wave_and_erosion.CPf_SignalSmooth module

natcap.invest.nearshore_wave_and_erosion.CPf_SignalSmooth.smooth(x, window_len=11, window='hanning')

smooth the data using a window with requested size.

This method is based on the convolution of a scaled window with the signal. The signal is prepared by introducing reflected copies of the signal (with the window size) in both ends so that transient parts are minimized in the begining and end part of the output signal.

input:

x: the input signal window_len: the dimension of the smoothing window; should be an odd integer window: the type of window from ‘flat’, ‘hanning’, ‘hamming’, ‘bartlett’, ‘blackman’

System Message: ERROR/3 (/home/docs/checkouts/readthedocs.org/user_builds/invest/envs/3.3.1/local/lib/python2.7/site-packages/natcap/invest/nearshore_wave_and_erosion/CPf_SignalSmooth.py:docstring of natcap.invest.nearshore_wave_and_erosion.CPf_SignalSmooth.smooth, line 12)

Unexpected indentation.
flat window will produce a moving average smoothing.
output:
the smoothed signal

example:

t=linspace(-2,2,0.1) x=sin(t)+randn(len(t))*0.1 y=smooth(x)

see also:

numpy.hanning, numpy.hamming, numpy.bartlett, numpy.blackman, numpy.convolve scipy.signal.lfilter

TODO: the window parameter could be the window itself if an array instead of a string

natcap.invest.nearshore_wave_and_erosion.NearshoreWaveFunctions_3p0 module

System Message: WARNING/2 (/home/docs/checkouts/readthedocs.org/user_builds/invest/checkouts/3.3.1/doc/api-docs/api/natcap.invest.nearshore_wave_and_erosion.rst, line 18)

autodoc: failed to import module u’natcap.invest.nearshore_wave_and_erosion.NearshoreWaveFunctions_3p0’; the following exception was raised: Traceback (most recent call last): File “/home/docs/checkouts/readthedocs.org/user_builds/invest/envs/3.3.1/local/lib/python2.7/site-packages/sphinx/ext/autodoc.py”, line 385, in import_object __import__(self.modname) File “/home/docs/checkouts/readthedocs.org/user_builds/invest/envs/3.3.1/local/lib/python2.7/site-packages/natcap/invest/nearshore_wave_and_erosion/NearshoreWaveFunctions_3p0.py”, line 10, in <module> from pylab import * TypeError: ‘type’ object does not support indexing

natcap.invest.nearshore_wave_and_erosion.WaveModel module

System Message: WARNING/2 (/home/docs/checkouts/readthedocs.org/user_builds/invest/checkouts/3.3.1/doc/api-docs/api/natcap.invest.nearshore_wave_and_erosion.rst, line 26)

autodoc: failed to import module u’natcap.invest.nearshore_wave_and_erosion.WaveModel’; the following exception was raised: Traceback (most recent call last): File “/home/docs/checkouts/readthedocs.org/user_builds/invest/envs/3.3.1/local/lib/python2.7/site-packages/sphinx/ext/autodoc.py”, line 385, in import_object __import__(self.modname) File “/home/docs/checkouts/readthedocs.org/user_builds/invest/envs/3.3.1/local/lib/python2.7/site-packages/natcap/invest/nearshore_wave_and_erosion/WaveModel.py”, line 5, in <module> from pylab import * TypeError: ‘type’ object does not support indexing

natcap.invest.nearshore_wave_and_erosion.nearshore_wave_and_erosion module

System Message: WARNING/2 (/home/docs/checkouts/readthedocs.org/user_builds/invest/checkouts/3.3.1/doc/api-docs/api/natcap.invest.nearshore_wave_and_erosion.rst, line 34)

autodoc: failed to import module u’natcap.invest.nearshore_wave_and_erosion.nearshore_wave_and_erosion’; the following exception was raised: Traceback (most recent call last): File “/home/docs/checkouts/readthedocs.org/user_builds/invest/envs/3.3.1/local/lib/python2.7/site-packages/sphinx/ext/autodoc.py”, line 385, in import_object __import__(self.modname) File “/home/docs/checkouts/readthedocs.org/user_builds/invest/envs/3.3.1/local/lib/python2.7/site-packages/natcap/invest/nearshore_wave_and_erosion/nearshore_wave_and_erosion.py”, line 19, in <module> import nearshore_wave_and_erosion_core File “/home/docs/checkouts/readthedocs.org/user_builds/invest/envs/3.3.1/local/lib/python2.7/site-packages/natcap/invest/nearshore_wave_and_erosion/nearshore_wave_and_erosion_core.py”, line 25, in <module> from NearshoreWaveFunctions_3p0 import* File “/home/docs/checkouts/readthedocs.org/user_builds/invest/envs/3.3.1/local/lib/python2.7/site-packages/natcap/invest/nearshore_wave_and_erosion/NearshoreWaveFunctions_3p0.py”, line 10, in <module> from pylab import * TypeError: ‘type’ object does not support indexing

natcap.invest.nearshore_wave_and_erosion.nearshore_wave_and_erosion_core module

System Message: WARNING/2 (/home/docs/checkouts/readthedocs.org/user_builds/invest/checkouts/3.3.1/doc/api-docs/api/natcap.invest.nearshore_wave_and_erosion.rst, line 42)

autodoc: failed to import module u’natcap.invest.nearshore_wave_and_erosion.nearshore_wave_and_erosion_core’; the following exception was raised: Traceback (most recent call last): File “/home/docs/checkouts/readthedocs.org/user_builds/invest/envs/3.3.1/local/lib/python2.7/site-packages/sphinx/ext/autodoc.py”, line 385, in import_object __import__(self.modname) File “/home/docs/checkouts/readthedocs.org/user_builds/invest/envs/3.3.1/local/lib/python2.7/site-packages/natcap/invest/nearshore_wave_and_erosion/nearshore_wave_and_erosion_core.py”, line 25, in <module> from NearshoreWaveFunctions_3p0 import* File “/home/docs/checkouts/readthedocs.org/user_builds/invest/envs/3.3.1/local/lib/python2.7/site-packages/natcap/invest/nearshore_wave_and_erosion/NearshoreWaveFunctions_3p0.py”, line 10, in <module> from pylab import * TypeError: ‘type’ object does not support indexing

Module contents