Please Help! Problem in using normcdf!

2 views (last 30 days)
Jeffrey Don
Jeffrey Don on 11 Mar 2015
Edited: dpb on 11 Mar 2015
hi everyone, got some problem using function normcdf here is the code,
function p_choice1 = Fechnerd(g1a1, g1a2, g1p1, g1p2, ...
g2a1, g2a2, g2p1, g2p2, gamma, sigma)
mu = (g1p1.* utility(g1a1, gamma) + g1p2.* utility(g1a2, gamma)) - ...
(g2p1.* utility(g2a1, gamma) + g2p2.* utility(g2a2, gamma));
p_choice2 = normcdf(0, mu, sigma);
p_choice1 = 1 - p_choice2;
function u = utility(value, gamma)
u = abs(value).^gamma;
g*p* are for probabilities, g*a* are for outcomes. While all I got was just a vector of 1. I don't know how to solve the problem... Thank you!

Answers (0)

Community Treasure Hunt

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

Start Hunting!