| Filter Design Toolbox | ![]() |
To Export Quantized Filters
To save your filter design, FDATool lets you export the quantized filter to your MATLAB workspace (or you can save the current session in FDATool). When you choose to save the quantized filter by exporting it, you select one of these options:
To save your quantized filter to your workspace, follow these steps:
Workspace under Export to.To overwrite variables that you have in your workspace, select Overwrite existing variables. Clear the check box to ensure that FDATool does not overwrite existing variables when you export the filter.
If you try to export the filter to a variable name that exists in your workspace, and you did not select Overwrite existing variables, FDATool stops the export operation and returns a warning that the variable you specified as the quantized filter name already exists in the workspace. To continue to export the filter to the existing variable, click OK to dismiss the warning dialog, select the Overwrite existing variables check box and click OK or Apply.
Getting Filter Coefficients after Exporting
To extract the filter coefficients from your quantized filter after you export the quantized filter to MATLAB, use the celldisp function in MATLAB. For example, create a quantized filter in FDATool and export the filter as Hq. To extract the filter coefficients for Hq, use
celldisp(Hq.referencecoefficients)
which returns the cell array containing the filter reference coefficients, or
celldisp(Hq.quantizedcoefficients)
to return the quantized coefficients.
To save your quantized filter as a text file, follow these steps:
Text-file under Export to.The Export Filter Coefficients to Text-file dialog appears. This is the standard Microsoft Windows save file dialog.
FDATool exports your quantized filter as a text file with the name you provided, and the MATLAB editor opens, displaying the file for editing.
To save your quantized filter as a MAT-file, follow these steps:
MAT-file under Export to.The Export Filter Coefficients to MAT-file dialog appears. This is the standard Microsoft Windows save file dialog.
| To Import Quantized Filters | Transforming Filters | ![]() |