Plots a signal spectrogram in frequency domain. Parameters (default), (type): ----------------------------- * sigObjs (), (list): a list with SignalObjs. * winType (), (str): window type for the time slicing, defaults to 'hann'. * winS
(sigObjs, winType, winSize,
overlap, xLabel, yLabel, xLim, yLim,
title, decimalSep)
| 803 | |
| 804 | |
| 805 | def spectrogram(sigObjs, winType, winSize, |
| 806 | overlap, xLabel, yLabel, xLim, yLim, |
| 807 | title, decimalSep): |
| 808 | """ |
| 809 | Plots a signal spectrogram in frequency domain. |
| 810 | |
| 811 | Parameters (default), (type): |
| 812 | ----------------------------- |
| 813 | |
| 814 | * sigObjs (), (list): |
| 815 | a list with SignalObjs. |
| 816 | |
| 817 | * winType (), (str): |
| 818 | window type for the time slicing, defaults to 'hann'. |
| 819 | |
| 820 | * winSize (), (int): |
| 821 | window size in samples |
| 822 | |
| 823 | * overlap (), (float): |
| 824 | window overlap in % |
| 825 | |
| 826 | * xLabel ('Time [s]'), (str): |
| 827 | x axis label. |
| 828 | |
| 829 | * yLabel ('Frequency [Hz]'), (str): |
| 830 | y axis label. |
| 831 | |
| 832 | * yLim (), (list): |
| 833 | inferior and superior frequency limits. |
| 834 | |
| 835 | >>> yLim = [20, 1000] |
| 836 | |
| 837 | * xLim (), (list): |
| 838 | left and right time limits |
| 839 | |
| 840 | >>> xLim = [1, 3] |
| 841 | |
| 842 | * title (), (str): |
| 843 | plot title |
| 844 | |
| 845 | * decimalSep (','), (str): |
| 846 | may be dot or comma. |
| 847 | |
| 848 | >>> decimalSep = ',' # in Brazil |
| 849 | |
| 850 | Return: |
| 851 | -------- |
| 852 | |
| 853 | List of matplotlib.figure.Figure objects for each item in curveData. |
| 854 | """ |
| 855 | |
| 856 | if xLabel is None: |
| 857 | xLabel = 'Time [s]' |
| 858 | if yLabel is None: |
| 859 | yLabel = 'Frequency [Hz]' |
| 860 | |
| 861 | figs = [] |
| 862 | curveData = _curve_data_extractor_spectrogram(sigObjs) |
nothing calls this directly
no test coverage detected