MATLAB normalize function shadowed by DSP toolbox normalize function
2 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Kaveen Liyanage
le 29 Oct 2019
Commenté : Kaveen Liyanage
le 29 Oct 2019
Hi,
When I am trying to use in MATLAB R2019a,
normalize(X,'range');
The following error occurs,
Error using sum
Invalid option. Option must be 'all', 'double', 'native', 'default', 'omitnan', or 'includenan'.
Error in normalize (line 10)
It seems the matlab is using the normalize function in DSP toolbox. How can I use the MATLAB default normalize function?.
Currently using : https://www.mathworks.com/help/dsp/ref/normalize.html
Thanking in advance for your help
0 commentaires
Réponse acceptée
Steven Lord
le 29 Oct 2019
Can you confirm that MATLAB is using the version from DSP System Toolbox and not the one from MATLAB or that you've created or downloaded? Run this command with the X on which you're trying to operate in the workspace:
which -all normalize(X, 'range')
I don't think the version of normalize in DSP System Toolbox even calls sum, and line 10 of the one included in MATLAB is a help text comment. I think you have a different normalize.m that's shadowing the one in MATLAB. Rename that normalize.m, remove it, or move it lower on the MATLAB path than the one in MATLAB.
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Array and Matrix Mathematics dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!