Hi Team MATLAB,
I created a code in MATLAB 2018b, but when I run in MATLAB 2012a, showns the follow error:
function [S,m,d2,qui2] = normalidade(F)[n,p] = size(F);m = mean(F);S = cov(F);for i = 1:n d2(i)= (F(i,:)-m)*inv(S)*(F(i,:)-m).';endd2 = sort(d2);for j=1:n qui2(j)=chi2inv((j-0.5)/n,p);endplot(d2,qui2,'*k')xlabel ('d2')ylabel ('qui2')gridendError: File: depuracao_1.m Line: 68 Column: 1Function definitions are not permitted in this context.
Could help me?
Thank you,
Guilherme
Best Answer