dsp.DynamicFilterVisualizer
Display time-varying magnitude and phase response of digital filters
Description
The dsp.DynamicFilterVisualizer
object displays the magnitude
response and phase response of time-varying digital filters or time-varying filter
coefficients. The input to this object can be a filter coefficients vector or a filter
System object™.
Using the dynamic filter visualizer, you can configure the plot settings, find the peak values, enable cursor measurements, and even generate script to recreate the plot with the current settings from the visualizer interface. For details, see Configure Filter Visualizer.
Creation
Syntax
Description
returns a
dynamic filter visualizer object, dfv
= dsp.DynamicFilterVisualizerdfv
, that displays the magnitude
response of digital filters or filter coefficients.
returns a dynamic filter visualizer with the dfv
= dsp.DynamicFilterVisualizer(nfft
)FFTLength
property set
to nfft
.
returns a dynamic filter visualizer with the dfv
= dsp.DynamicFilterVisualizer(nfft
,Fs
)FFTLength
property set
to nfft
and the SampleRate
property set to
Fs
.
returns a dynamic filter visualizer with the dfv
= dsp.DynamicFilterVisualizer(nfft
,Fs
,range
)FFTLength
property set
to nfft
, the SampleRate
property set to
Fs
, and the FrequencyRange
property set to
range
.
returns a dynamic filter visualizer with each specified property set to the specified
value. Unspecified properties have default values. You can use this syntax with any of the
previous syntaxes.dfv
= dsp.DynamicFilterVisualizer(Name=Value
)
Properties
Frequently Used
FFTLength
— FFT length
2048
(default) | positive integer
FFT length that the dynamic filter visualizer uses to compute spectral estimates, specified as a positive integer.
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and set FFT Length to a positive integer.
Data Types: single
| double
| int8
| int16
| int32
| int64
| uint8
| uint16
| uint32
| uint64
NormalizedFrequency
— Flag to display normalized frequency
false
(default) | true
Since R2023a
Flag to display normalized frequency, specified as one of these values:
true
–– The filter visualizer displays the frequency response in normalized frequency units (0 to 1).false
–– The filter visualizer displays the frequency response in Hz. You can specify the input sample rate through theSampleRate
property.
Scope Window Use
On the Scope tab, click Settings, and select Normalized Frequency.
Data Types: logical
SampleRate
— Sampling rate of input
44100
(default) | positive scalar
Sampling rate of the input signal, specified as a real positive scalar in Hz.
Tunable: Yes
Dependency
To enable this property, set
NormalizedFrequency
to false
. (since R2023a)
Scope Window Use
On the Scope tab, click Settings, and set Sample Rate (Hz) to a positive scalar.
Data Types: single
| double
| int8
| int16
| int32
| int64
| uint8
| uint16
| uint32
| uint64
FrequencyRange
— Range of frequency axis
[0
22050
] (default) | two-element numeric vector
Range of the frequency axis, specified as a two-element numeric vector that is monotonically increasing and of the form [fmin, fmax].
When you set the
NormalizedFrequency
property totrue
, fmax is in normalized frequency units and must be a positive scalar that is less than or equal to 1. (since R2023a)When you set the
NormalizedFrequency
property tofalse
, fmax is in Hz and must be less than or equal to Fs/2, where Fs is the value you specify in theSampleRate
property. (since R2023a)
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and set Range to a two-element numeric vector.
Data Types: single
| double
| int8
| int16
| int32
| int64
| uint8
| uint16
| uint32
| uint64
XScale
— x-axis scale
'Log'
(default) | 'Linear'
X-axis scale, specified as either 'Linear'
or
'Log'
.
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and set X-Scale.
MagnitudeDisplay
— y-axis units
'Magnitude (dB)'
(default) | 'Magnitude'
|'Magnitude squared'
Y-axis units, specified as one of the following:
'Magnitude'
'Magnitude (dB)'
'Magnitude squared'
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and set Display Unit.
PlotAsMagnitudePhase
— Plot magnitude and phase response of filter
false
(default) | true
true
– The filter visualizer plots the magnitude and phase responses of the filter on two separate axes.false
– The filter visualizer plots only the magnitude response of the filter.
Tunable: Yes
Scope Window Use
On the Scope tab, click the Magnitude Phase button.
PlotType
— Option to control type of plot
"Line"
(default) | "Stairs"
| "Stem"
Specify the type of plot to use in the filter visualizer window as one of these:
"Line"
– The filter visualizer connects each point on the magnitude and phase response plot with a line."Stairs"
– The filter visualizer displays the filter response (magnitude, phase, or both) as a stair-step graph. A stair-step graph is made up of only horizontal lines and vertical lines. Each horizontal line represents the filter response over a frequency value and is connected to two vertical lines. Each vertical line represents a change in values occurring at a frequency."Stem"
– The filter visualizer displays the frequency response as circles with vertical lines extending down to the x-axis at each of the frequency values.
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and set Plot Type.
AxesScaling
— Axes scaling mode
"OnceAtStop"
(default) | "Auto"
| "Manual"
| "Updates"
Specify the scaling mode for the axes as one of these:
"Auto"
— The filter visualizer scales the axes as needed to fit the data, both during and after simulation."Manual"
— The filter visualizer does not scale the axes automatically."OnceAtStop"
— The filter visualizer scales the axes when the simulation stops."Updates"
— The filter visualizer scales the axes limits once after a set number of visual updates. The number of updates is determined by the value of theAxesScalingNumUpdates
property.
Tunable: Yes
Scope Window Use
Hover over the filter visualizer to see the maximize , pan , zoom , and autoscale buttons. You can also zoom and pan using your mouse.
Data Types: char
| string
AxesScalingNumUpdates
— Number of updates before scaling
100 (default) | real positive integer
Specify the number of updates before scaling as a real, positive scalar integer.
Tunable: Yes
Dependency
To enable this property, set AxesScaling
to
"Updates"
.
Data Types: double
Measurements
MeasurementChannel
— Channel for which to obtain measurements
1
(default) | positive integer
Channel for which to obtain measurements, specified as a positive integer in the range [1 N], where N is the number of input channels.
Tunable: Yes
Scope Window Use
Click the Measurements tab on the Dynamic Filter Visualizer toolstrip. In the Channel section, select a Channel.
Data Types: double
CursorMeasurements
— Cursor measurements
CursorMeasurementsConfiguration
object
Cursor measurements to display waveform cursors, specified as a CursorMeasurementsConfiguration
object.
All CursorMeasurementsConfiguration
properties are
tunable.
Tunable: Yes
Scope Window Use
Click the Measurements tab on the Dynamic Filter Visualizer toolstrip and modify the cursor measurements in the Cursors section.
PeakFinder
— Peak finder measurements
PeakFinderConfiguration
object
Peak finder measurements to compute and display the largest calculated peak
values, specified as a PeakFinderConfiguration
object.
All PeakFinderConfiguration
properties are tunable.
Tunable: Yes
Scope Window Use
Click the Measurements tab on the Dynamic Filter Visualizer toolstrip and modify the peak finder measurements in the Peaks section.
Visualization
Name
— Caption to display on Dynamic Filter Visualizer window
'Dynamic Filter Visualizer'
(default) | character vector | string scalar
Caption to display on the Dynamic Filter Visualizer window, specified as a character vector or a string scalar.
Example: 'Dynamic Filter Visualizer'
Example: "Dynamic Filter Visualizer"
Tunable: Yes
Position
— Scope window position in pixels
[left bottom 800 500]
(default) | four-element double vector
Scope window position in pixels, specified as a four-element double vector of the
form [left bottom width height]. The default value of this property is dependent on
the screen resolution, and is such that the window is positioned in the center of the
screen, with a width and height of 800
and 500
pixels, respectively.
Tunable: Yes
Data Types: single
| double
| int8
| int16
| int32
| int64
| uint8
| uint16
| uint32
| uint64
MaximizeAxes
— Maximize axes control
"Auto"
(default) | "On"
| "Off"
Specify whether to display the filter visualizer in maximized-axes mode. In this mode, the axes are expanded to fit into the entire display. To conserve space, labels do not appear in each display. Instead, tick-mark values appear on top of the plotted data. You can select one of the following options:
"Auto"
— The axes appear maximized in all displays only if theTitle
andYLabel
properties are empty for every display. If you enter any value in any display for either of these properties, the axes are not maximized."On"
— The axes appear maximized in all displays. Any values entered into theTitle
andYLabel
properties are hidden."Off"
— None of the axes appear maximized.
Tunable: Yes
Scope Window Use
Hover over the Dynamic Filter Visualizer window to see the maximize axes button .
Data Types: char
| string
Title
— Display title
''
(default) | character vector | string scalar
Display title, specified as a character vector or a string scalar.
Example: 'Magnitude Response'
Example: "Magnitude Response"
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and set Title to a character vector or a string scalar.
YLimits
— y-axis limits
[-25
25
] (default) | two-element row vector
Y-axis limits, specified as a two-element numeric row vector with the second element greater than the first element and of the form [ymin, ymax].
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and set Y-Limits to a two-element numeric vector.
Data Types: single
| double
| int8
| int16
| int32
| int64
| uint8
| uint16
| uint32
| uint64
ShowLegend
— Show or hide legend
false
(default) | true
When this property is set to false
, no legend is displayed.
When this property is set to true
, a legend with automatic string
labels for each input filter is displayed.
Tunable: Yes
Scope Window Use
On the Scope tab, click Legend.
Data Types: logical
FilterNames
— Names for input filters
{''}
(default) | cell array of character vectors | array of strings
Names to label the input filters in the legend, specified as a cell array of
character vectors or an array of strings. The default is an empty cell array. When
this property is set to an empty cell array, the filters are named by default names,
such as Filter 1
, Filter 2
, and so on.
Tunable: Yes
Scope Window Use
On the Scope tab, click Legend. In the legend that appears on the plot, click the filter name.
ShowGrid
— Display grid
true
(default) | false
Set this property to true
to show grid lines on the
plot.
Scope Window Use
On the Scope tab, click Settings, and select Show Grid.
UpperMask
— Upper limit mask
Inf
(default) | two-column matrix
Upper limit spectral mask, specified as a two-column matrix. The first column represents the frequency values (Hz), and the second column represents the magnitude spectrum of the upper limit mask.
Tunable: Yes
Data Types: single
| double
| int8
| int16
| int32
| int64
| uint8
| uint16
| uint32
| uint64
LowerMask
— Lower limit mask
-Inf
(default) | two-column matrix
Lower limit spectral mask, specified as a two-column matrix. The first column represents the frequency values (Hz), and the second column represents the magnitude spectrum of the lower limit mask.
Tunable: Yes
Data Types: single
| double
| int8
| int16
| int32
| int64
| uint8
| uint16
| uint32
| uint64
Color and Styling
BackgroundColor
— Background color in scope
[33 33 33
]/255
(default) | RGB triplet | hexadecimal color code | "r"
| "g"
| "b"
| ...
Since R2024b
Background color in scope, specified as an RGB triplet, a hexadecimal color code, a color name, or a short name. For more information on all the acceptable values, see Color.
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and select a Background color.
Data Types: double
| char
AxesColor
— Color of axes in scope
[18 18 18
]/255
(default) | RGB triplet | hexadecimal color code | "r"
| "g"
| "b"
| ...
Since R2024b
Color of the axes in the scope, specified as an RGB triplet, a hexadecimal color code, a color name, or a short name. For more information on all the acceptable values, see Color.
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and select an Axes color.
Data Types: double
| char
FontColor
— Color of labels in scope
[217 217 217
]/255
(default) | RGB triplet | hexadecimal color code | "r"
| "g"
| "b"
| ...
Since R2024b
Colors of the labels in the scope, specified as an RGB triplet, a hexadecimal color code, a color name, or a short name. Use this property to set the color of the scope title, x-axis and y-axis labels, and the axes ticks. For more information on all the acceptable values, see Color.
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and select a Labels color.
Data Types: double
| char
FontSize
— Scope font size
8.5
(default) | positive scalar
Since R2024b
Scope font size, specified as a positive scalar. Use this property to set the font size for the ticks, labels, title, and measurements of the scope.
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and set the Font Size to one of the available values.
Data Types: single
| double
| int8
| int16
| int32
| int64
| uint8
| uint16
| uint32
| uint64
LineVisible
— Visibility of plot lines in scope
"on"
or 1
(default) | "off"
or 0
| vector of logical values
Since R2024b
Visibility of plot lines in scope, specified as one of these:
"on"
or 1 –– The scope displays the plot line. If you are plotting multiple lines, the scope applies this value to all the lines."off"
or 0 –– The scope hides the plot line. If you are plotting multiple lines, the scope applies this value to all the lines.vector of logical values –– The scope applies the values to the lines in the plot. The length of the vector must equal the number of lines that you are plotting in the scope.
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and select the Visible property.
Data Types: logical
LineStyle
— Scope line style
"-"
(default) | "--"
| ":"
| "-."
| "none"
| cell array or array
Since R2024b
Scope line style, specified as one of these options:
"-"
–– Solid line"--"
–– Dashed line":"
–– Dotted line"-."
–– Dash-dotted line"none"
–– No line
If you provide a cell array or an array of these values, then the length of the array must equal the number of lines that you are plotting in the scope.
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and set Style.
LineWidth
— Scope line width
1.5
(default) | positive scalar | vector of positive scalar values
Since R2024b
Scope line width, specified as a positive scalar or a vector of positive scalar values in points, where 1 point = 1/72 of an inch. If you specify a scalar value and are plotting multiple lines, then the scope applies the same value to all the lines. If you provide a vector of values, the length of the vector must equal the number of lines that you are plotting.
If the line has markers, then the line width also affects the marker edges. The line width cannot be thinner than the width of a pixel. If you set the line width to a value that is less than the width of a pixel on your system, the line displays as one pixel wide.
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and set Width.
Data Types: single
| double
| int8
| int16
| int32
| int64
| uint8
| uint16
| uint32
| uint64
LineColor
— Scope line color
colororder
("default"
) (default) | matrix of RGB triplets | array of color names
Since R2024b
Scope line color, specified as a matrix of RGB triplets or an array of color names.
Tunable: Yes
Matrix of RGB Triplets
Specify an m-by-3 matrix, where each row is an RGB triplet. An RGB triplet is a three-element vector containing the intensities of the red, green, and blue components of a color. The intensities must be in the range [0,1]. For example, this matrix defines the new colors as blue, dark green, and orange.
scope.LineColor = [1.0 0.0 0.0 0.0 0.4 0.0 1.0 0.5 0.0];
Array of Color Names or Hexadecimal Color Codes
Specify any combination of color names, short names, or hexadecimal color codes.
To specify one color, set the line color to a character vector or a string scalar. For example,
scope.LineColor = 'red'
specifies red as the only color in the color order.To specify multiple colors, set
LineColor
to a cell array of character vectors or a string array. For example,scope.LineColor = {'red','green','blue'}
specifies red, green, and blue as the colors.
A hexadecimal color code starts with a hash symbol (#
) followed by
three or six hexadecimal digits, which can range from 0
to
F
. The values are not case sensitive. Thus, the color codes
'#FF8800'
, '#ff8800'
, '#F80'
, and
'#f80'
are equivalent.
This table lists the color names and short names with the equivalent RGB triplets and hexadecimal color codes.
Color Name | Short Name | RGB Triplet | Hexadecimal Color Code | Appearance |
---|---|---|---|---|
"red" | "r" | [1 0 0] | "#FF0000" | |
"green" | "g" | [0 1 0] | "#00FF00" | |
"blue" | "b" | [0 0 1] | "#0000FF" | |
"cyan"
| "c" | [0 1 1] | "#00FFFF" | |
"magenta" | "m" | [1 0 1] | "#FF00FF" | |
"yellow" | "y" | [1 1 0] | "#FFFF00" | |
"black" | "k" | [0 0 0] | "#000000" | |
"white" | "w" | [1 1 1] | "#FFFFFF" |
Scope Window Use
On the Scope tab, click Settings, and set Color.
Data Types: single
| double
| char
| string
| cell
LineMarker
— Scope line marker
"none"
| "o"
| "+"
| "*"
| "."
| ...
Since R2024b
Scope line marker symbol, specified as one of the values listed in this table. By default, the object does not display markers. Specifying a marker symbol adds markers at each data point or vertex.
Tunable: Yes
Scope Window Use
On the Scope tab, click Settings, and set Marker.
Usage
Description
dfv(
displays the time-varying
magnitude response of the object filter, filt
)filt
, in the Dynamic Filter
Visualizer figure, as long as filt
has a valid
freqz()
implementation.
Input Arguments
filt
— Input filter
filter System object
Input filter System object with a valid freqz()
implementation.
B
— Numerator polynomial coefficients
row vector
Numerator polynomial coefficients, specified as a row vector.
Data Types: single
| double
A
— Denominator polynomial coefficients
scalar | row vector
Denominator polynomial coefficients, specified as a:
scalar –– The filter is an FIR filter.
row vector –– The filter is an IIR filter.
Data Types: single
| double
Object Functions
Specific to dsp.DynamicFilterVisualizer
step | Display time-varying magnitude response |
printToFigure | Print scope window to MATLAB figure |
Specific to Scopes
show | Display scope window |
hide | Hide scope window |
isVisible | Determine visibility of scope |
generateScript | Generate MATLAB script to create scope with current settings |
Examples
Plot Time-Varying Magnitude and Phase Response of FIR Filter
Design an FIR filter with a time-varying magnitude and phase response. Plot this varying response on a dynamic filter visualizer in normalized frequency units.
Create a dsp.DynamicFilterVisualizer
object. Set the PlotAsMagnitudePhase
and the NormalizedFrequency
properties to true
.
dfv = dsp.DynamicFilterVisualizer(PlotAsMagnitudePhase=1,... NormalizedFrequency=true,ShowLegend=true,... Title='Magnitude and Phase Response',... FilterNames="FIR Filter")
dfv = dsp.DynamicFilterVisualizer handle with properties: FFTLength: 2048 NormalizedFrequency: 1 FrequencyRange: [0 1] XScale: 'Linear' MagnitudeDisplay: 'Magnitude (dB)' PlotAsMagnitudePhase: 1 PlotType: 'Line' AxesScaling: 'Auto' Show all properties
Vary the cutoff frequency of the FIR filter k from 0.1
to 0.5
in increments of 0.001
. View the varying magnitude and phase response using the dynamic filter visualizer.
for k = 0.1:0.001:0.5 b = designLowpassFIR(FilterOrder=90,CutoffFrequency=k); dfv(b,1); end
Plot Time-Varying Magnitude Response of Variable Bandwidth FIR Filter
Visualize the varying magnitude response of the variable bandwidth FIR filter using the dynamic filter visualizer.
Create a dsp.DynamicFilterVisualizer
object.
dfv = dsp.DynamicFilterVisualizer(YLimits=[-160 10],... FilterNames="Variable Bandwidth FIR Filter")
dfv = dsp.DynamicFilterVisualizer handle with properties: FFTLength: 2048 NormalizedFrequency: 0 SampleRate: 44100 FrequencyRange: [0 22050] XScale: 'Linear' MagnitudeDisplay: 'Magnitude (dB)' PlotAsMagnitudePhase: 0 PlotType: 'Line' AxesScaling: 'Manual' Show all properties
Design a bandpass variable bandwidth FIR filter with a center frequency of 5 kHz and a bandwidth of 4 kHz.
Fs = 44100; vbw = dsp.VariableBandwidthFIRFilter(FilterType='Bandpass',... FilterOrder=100,... SampleRate=Fs,... CenterFrequency=5e3,... Bandwidth=4e3);
Vary the center frequency of the filter. Visualize the varying magnitude response of the filter using the dsp.DynamicFilterVisualizer
object.
for idx = 1:100 dfv(vbw); vbw.CenterFrequency = vbw.CenterFrequency + 20; end
Customize Color and Style Settings of dsp.DynamicFilterVisualizer
Object
Since R2024b
Create a dsp.DynamicFilterVisualizer
object and set the NormalizedFrequency
property to true
. Create three bandpass FIR filters with varying center frequencies.
filtViz = dsp.DynamicFilterVisualizer(NormalizedFrequency=true); filt1 = designBandpassFIR(FilterOrder=100,CenterFrequency=0.3,... Bandwidth=0.1,SystemObject=true); filt2 = designBandpassFIR(FilterOrder=100,CenterFrequency=0.4,... Bandwidth=0.1,SystemObject=true); filt3 = designBandpassFIR(FilterOrder=100,CenterFrequency=0.5,... Bandwidth=0.1,SystemObject=true);
Visualize the filters in the filter visualizer. This plot shows the default color and style settings of the object.
filtViz(filt1,filt2,filt3) release(filtViz);
Change the background color and the axes color of the plot to "white"
. Set the font color to "black"
. Also, change the line colors to ["red" "green" "black"]
.
filtViz.BackgroundColor = "white"; filtViz.AxesColor = "white"; filtViz.FontColor = "black"; filtViz.LineColor = ["red" "green" "black"]; show(filtViz) release(filtViz)
To change the color order, set LineColor
to a different color order. This setting changes the color order palette.
filtViz.LineColor = colororder("glow");
show(filtViz)
release(filtViz)
To control the visibility of the plot lines, use the LineVisible
property. When you select "off"
, the plot line becomes invisible.
filtViz.LineVisible = ["off" "on" "on"]; show(filtViz) release(filtViz)
You can further specify a marker for each line and change the corresponding line width.
filtViz.LineMarker = ["x","o","+"]; filtViz.LineWidth = 2; show(filtViz) release(filtViz)
Print Dynamic Filter Visualizer Display to MATLAB Figure
Since R2023b
Use the printToFigure
function to print the dsp.DynamicFilterVisualizer
object display window to a new MATLAB® figure.
Create a dsp.DynamicFilterVisualizer
object.
dfv = dsp.DynamicFilterVisualizer(YLimits=[-120 10]);
Design FIR filter with varying cutoff frequencies ranging from 0.1 to 0.5. Plot the magnitude response of the filter using the Dynamic Filter Visualizer.
for k = 0.1:0.001:0.5 b = fir1(90, k); dfv(b,1); end
Change the background color and the axes color of the plot to "white"
. Set the font color to "black"
and the line color to "blue"
.
dfv.BackgroundColor = "white"; dfv.AxesColor = "white"; dfv.FontColor = "black"; dfv.LineColor = "blue"; show(dfv) release(dfv)
Print the display of the magnitude response to a new MATLAB figure. The function returns a handle to the figure.
scopeFig = printToFigure(dfv);
The handle to the figure scopeFig
lets you modify the appearance and the behavior of the figure window.
Specify a figure name and change the size of the figure to 400-by-250 pixels.
scopeFig.Name="Magnitude Response of FIR Filter"; scopeFig.NumberTitle="off"; scopeFig.Position=[1 1 400 250];
When printing to figure, you can make the figure invisible by setting the Visible
argument to false
.
scopeFig = printToFigure(dfv,Visible=false);
Limitations
Does not support C/C++ code generation using MATLAB® Coder™. To generate a standalone application, use the MATLAB Compiler™.
Supports MEX code generation by treating the calls to the object as extrinsic.
Version History
Introduced in R2018bR2024b: New color and styling properties
Using the new color and styling properties, you can customize the plot line, axes, and background settings of the scope through the MATLAB command line.
R2024b: Higher display precision in scope UI
You can now increase the display precision to 15 digits using the Display Precision property in the scope settings under Display and Labels. This precision affects all the measurements and data that the scope displays on its status bar.
R2024b: Preserve Colors is now available in scope toolstrip
The Preserve colors for copy to clipboard property has been renamed to Preserve Colors and is now available in the scope toolstrip under Copy Display.
R2024a: Plot tab has been renamed as Scope tab
The Plot tab in dynamic filter visualizer has been renamed as Scope tab.
R2023b: Support for printToFigure
function
You can print the dsp.DynamicFilterVisualizer
object display window to
a MATLAB figure using the new printToFigure
function.
R2023a: Normalized frequency in dsp.DynamicFilterVisualizer
When you set the NormalizedFrequency
property to
true
, the dynamic filter visualizer shows the frequency response of the
filter in normalized frequency units (0 to 1).
R2022b: Filter names support array of strings
Starting in R2022b, you can specify the FilterNames
property of the
dsp.DynamicFilterVisualizer
object as an array of strings.
dfv = dsp.DynamicFilterVisualizer(FilterNames=["Filter 1", "Filter 2"]);
R2022b: Enhancements to the dsp.DynamicFilterVisualizer
object and the Dynamic Filter Visualizer UI
The dsp.DynamicFilterVisualizer
object has the following new properties starting
R2022b:
PlotAsMagnitudePhase
–– Split the magnitude and phase of the input signal and plot them on two separate axes within the same windowPlotType
–– Plot typeAxesScaling
–– Axes scaling modeAxesScalingNumUpdates
–– Number of updates before scalingMaximizeAxes
–– Maximize axes controlShowGrid
–– Grid visibility
The Dynamic Filter Visualizer app that you launch using the object has these enhancements in R2022b:
Magnitude Phase button –– This button corresponds to the
PlotAsMagnitudePhase
property in the object.Generate Script button –– Generate a script to re-create your dynamic filter visualizer plot with the same settings. When you click this button, an editor window opens with the code that you can use to re-create your
dsp.DynamicFilterVisualizer
object.
R2022b: Configure dsp.DynamicFilterVisualizer
measurements programmatically
You can now configure the cursor and the peak finder measurements in the dsp.DynamicFilterVisualizer
object programmatically using these properties:
MeasurementChannel
CursorMeasurements
PeakFinder
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)