Unable to run code due to an error in 'Fadeeva_m' function

조회 수: 2 (최근 30일)
Kanan Yagublu
Kanan Yagublu 2022년 8월 7일
댓글: Walter Roberson 2022년 8월 7일
Hi guys, I have some data for my project and I wanted to fit the Voigt function to the data, since I am so new to matlab and fitting I wanted to use an example: Voigt fitting
When I wanted to run this code with my data with the following way:
data = readmatrix("labdatacopy.csv");
data = data(9:end,:);
y = data(:,4);
x = data(:,1);
initGuess1 = [46, 0.5, 0.5];
[estimates1, model1] = voigtfit(x, y, initGuess1, [40, 50]);
disp('Single peak fit results [peak1, gamma1, sigma1]');
disp(estimates1);
I get following error:
I tried download other packages which contain Fadeeva_w function, however error still there.
Do you have any recomendations?

답변 (1개)

Walter Roberson
Walter Roberson 2022년 8월 7일
you need to run the build script to compile faddeeva_w
https://www.mathworks.com/matlabcentral/fileexchange/38787-faddeeva-package-complex-error-functions
  댓글 수: 2
Kanan Yagublu
Kanan Yagublu 2022년 8월 7일
Thank you for your answer , however it didn't work as well.
Execution of script Faddeeva_w as a function is not supported:
Walter Roberson
Walter Roberson 2022년 8월 7일
You need to have configured a c++ compiler and executed
Faddeeva_build
That will compile the c++ source code into something that will take precedence over the .m file

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Probability Distributions에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by