There are existing topics on this matter.
https://ask.cvxr.com/search?q=narginchk
In particular, see the posts by CVX developer @mcg in this this somewhat old topic MATLAB nargchk deprecated
There are existing topics on this matter.
https://ask.cvxr.com/search?q=narginchk
In particular, see the posts by CVX developer @mcg in this this somewhat old topic MATLAB nargchk deprecated