(example-wavelet)= # `analyze.wavelet` The function [`analyze.wavelet`](#digger.analyze.wavelet.wavelet) analyzes a numerical gauge trace using a continuous wavelet transform (the Ricker wavelet is used). ```{literalinclude} ../../../../../examples/post-run/barry_arm/setpostprocess.py :language: python :start-after: Block 6 Start :end-before: Block 6 End ``` :::{attention} This code snippet is not fully self-sufficient. This snippet relies on simulation output files. To reproduce the example, execute the file `digger/examples/post-run/barry_arm/setpostprocess.py` from within the directory in which it is located. **Before** the script is executed either the example simulation must be run or the file `digger/data/barry_arm_output.zip` must be unzipped and the resulting directory (`_output`) must be placed within `digger/examples/post-run/barry_arm/`. ::: Running this code snippet generates two diagnostic figures that depict the detrended gauge and the wavelet analysis scalogram. ```{figure} ../../../../_static/from_examples/wavelet-BA_timeseries.png :alt: Example digger.analyze.wavelet gauge figure. An example of the diagnostic output provided by digger.analyze.wavelet showing the detrended gauge trace. ``` ```{figure} ../../../../_static/from_examples/wavelet-BA_scalogram.png :alt: Example digger.analyze.wavelet scalogram figure. An example of the diagnostic output provided by digger.analyze.wavelet showing the wavelet scalogram. ```