Cant get my code to work
1 回表示 (過去 30 日間)
古いコメントを表示
Hi, ive written the following function
function Guass_t=Gaussian_t(x)
n = length(x);
mean = sum(x)/n;
std = sqrt(sum((x-mean).^2/n));
A=sqrt(2*pi*((std).^2));
B=1/A;
C=(x-mean).^2;
D=2*std*std;
Gauss_t= B*exp(-C/D)
end
It doesnt seem to work. It keeps saying Guass_t is undefined. Please can someone explain where I have gone wrong.
0 件のコメント
採用された回答
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Startup and Shutdown についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!