Info

この質問は閉じられています。 編集または回答するには再度開いてください。

help on this code error

1 回表示 (過去 30 日間)
mutah
mutah 2013 年 11 月 7 日
閉鎖済み: MATLAB Answer Bot 2021 年 8 月 20 日
Hi all
I have this code but it still has error
can any one solve it ?
clear mixture;
mixtrue.dist='Exponential';
mixtrue.K=2;
mixtrue.weight=[0.1 0.9];
mixtrue.par=[1 10];
data=simulate(mixtrue,100);
data.Strue=data.S;
data=rmfield(data,'S');
dataplot(data)
clear mix;
mix.dist='Exponential';
mix.K=2;
prior=priordefine(data,mix);
[data,mix,mcmc]=mcmcstart(data,mix);
mcmcout=mixturemcmc(data,mix,prior,mcmc);
mcmcplot(mcmcout,2);
[est,mcmcout]=mcmcestimate(mcmcout);
[marlik,mcmcout]=mcmcbf(data,mcmcout)
mcmcout.name= 'store_mix_exponential_K2';
mcmcstore(mcmcout);
  2 件のコメント
Walter Roberson
Walter Roberson 2013 年 11 月 7 日
What difficulty do you see when you try?
mutah
mutah 2013 年 11 月 7 日
when i execute this code i found error

回答 (1 件)

John Mahoney
John Mahoney 2013 年 11 月 7 日
Are you mixing up "mixture" and "mixtrue"?
  1 件のコメント
mutah
mutah 2013 年 11 月 7 日
yes .

Community Treasure Hunt

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

Start Hunting!

Translated by