translationalneuromodeling / tapas

TAPAS - Translational Algorithms for Psychiatry-Advancing Science
https://translationalneuromodeling.github.io/tapas/
GNU General Public License v3.0
217 stars 90 forks source link

Error using taps_Cov2Corr #93

Closed cmill22 closed 3 years ago

cmill22 commented 4 years ago

Dear Dr Mathys,

I'm a beginner with computational modelling and the HGF and am currently trying to estimate subject-specific Bayes Optimal parameters to use as priors (as subjects each see a unique order of binary inputs) with the following code:

BayesOpt_params = tapas_fitModel([],...
u,...
'tapas_hgf_binary_config_BayesOptModel1',...
'tapas_bayes_optimal_binary_config',...
'tapas_quasinewton_optim_config');

  1. During this procedure I keep encountering the error 'Error using tapas_Cov2Corr (line 14) Input matrix is not symmetric.' for all or at least some subjects. Would you be able to advise me on how to counteract this error?

  2. I am confused why om values must be negative- I understood this parameter to represent tonic volatility at each level (so therefore should be positive?)

My tapas_hgf_binary_config is:

c.mu_0mu = [NaN, 1, 0]; c.mu_0sa = [NaN, 0.5, 1];

c.logsa_0mu = [NaN, log(10), log(10)]; c.logsa_0sa = [NaN, 10, 10];

c.rhomu = [NaN, 0, 0]; c.rhosa = [NaN, 0, 0];

c.logkamu = [NaN, log(1)]; c.logkasa = [NaN, 5];

c.ommu = [NaN, -10, -10]; c.omsa = [NaN, 4^2, 4^2];

Thank you so much for your kind help and very best wishes, Chantal

chmathys commented 4 years ago

Dear Chantal,

  1. The error you keep encountering is the result of some internal changes in Matlab. We’re aware of this and are working to fix it. If you have access to an older version of Matlab, that might help in the meantime.

  2. The omegas are tonic log-volatilities, that’s why they can and often do take negative values. They can also be positive, though.

Best wishes, Christoph On 26 Apr 2020, 2:19 PM +0200, cmill22 notifications@github.com, wrote:

Dear Dr Mathys, I'm a beginner with computational modelling and the HGF and am currently trying to estimate subject-specific Bayes Optimal parameters to use as priors (as subjects each see a unique order of binary inputs) with the following code: BayesOpt_params = tapas_fitModel([],... u,... 'tapas_hgf_binary_config_BayesOptModel1',... 'tapas_bayes_optimal_binary_config',... 'tapas_quasinewton_optim_config');

  1. During this procedure I keep encountering the error 'Error using tapas_Cov2Corr (line 14) Input matrix is not symmetric.' for all or at least some subjects. Would you be able to advise me on how to counteract this error?

  2. I am confused why om values must be negative- I understood this parameter to represent tonic volatility at each level (so therefore should be positive?)

My tapas_hgf_binary_config is: c.mu_0mu = [NaN, 1, 0]; c.mu_0sa = [NaN, 0.5, 1]; c.logsa_0mu = [NaN, log(10), log(10)]; c.logsa_0sa = [NaN, 10, 10]; c.rhomu = [NaN, 0, 0]; c.rhosa = [NaN, 0, 0]; c.logkamu = [NaN, log(1)]; c.logkasa = [NaN, 5]; c.ommu = [NaN, -10, -10]; c.omsa = [NaN, 4^2, 4^2]; Thank you so much for your kind help and very best wishes, Chantal — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.