To decompose a signal using the Meyer wavelet, you should use "dmey" as the wavelet name. Here's an example which include 8-level wavelet decomposition and plotting the coefficients:
load kobe.mat
A=kobe;
n=4;
% Perform wavelet decomposition
[C,S]=wavedec(A,n,"dmey");
%Extract and plot approximation Coefficients
approx = appcoef(C,S,"dmey");
subplot(n+1,1,1)
plot(approx)
title('Approximation Coefficients')
for i = 1:n
% Extract detail coefficients for each level
D = detcoef(C, S, i);
% Plot the detail coefficients
subplot(n+1, 1, i+1);
plot(D);
title(['Detail Coefficients at Level ', num2str(i)]);
end
Additionally, you can use the Wavelet Signal Analyzer app to decompose any 1-D signal. You can launch the app with the following command:
>>waveletSignalAnalyzer
For more information on using the app, please refer to the
To learn more about wavelet decomposition, you can consult the following resources
2-D Transform - https://www.mathworks.com/help/wavelet/ref/wavedec2.html