Main Content

wpviewcf

Plot wavelet packets colored coefficients

    Description

    wpviewcf(T,cmode) plots the colored coefficients for the terminal nodes of the wavelet packet tree T using the color mode cmode.

    example

    wpviewcf(T,cmode,nbcol) uses nbcol colors.

    Examples

    collapse all

    Create a wavelet packet tree using the Haar wavelet.

    Fs = 200;
    x = 0:1/Fs:1;
    y = sin(8*pi*x);
    t = wpdec(y,3,"haar");

    Use plot, the plot tree GUI, to plot the tree.

    plot(t)

    Figure contains 2 axes objects and other objects of type uimenu. Axes object 1 with title Tree Decomposition contains 29 objects of type line, text. Axes object 2 with title data for node: 0 or (0,0). contains an object of type line.

    Click the node (3,0) to get this figure:

    Plot the colored wavelet packet coefficients.

    wpviewcf(t,1)

    Figure contains an axes object. The axes object with title Frequency Order : Global + abs, xlabel Time or space values, ylabel Indices of terminal nodes contains 9 objects of type image, line.

    Input Arguments

    collapse all

    Wavelet packet tree, specified as a wptree object.

    Color mode to use to plot the coefficients, specified by one of the values listed here.

    Color ModeDescription
    1Frequency order – Global coloration – Absolute values
    2Frequency order – By level – Absolute values
    3Frequency order – Global coloration – Values
    4Frequency order – By level coloration – Values
    5Natural order – Global coloration – Absolute values
    6Natural order – By level – Absolute values
    7Natural order – Global coloration – Values
    8Natural order – By level coloration – Values

    Number of colors to use to plot the coefficients, specified as a positive integer.

    Version History

    Introduced before R2006a

    See Also