How can I fix this error?
Mostrar comentarios más antiguos
I followed the written code literally but it still says there is an error in line 4 y = finitepmf(s,p,x);
Therefore, I could not have the answer
>> shipweightpmf( [2 2.5 6] )'
ans = 0.1500 0 0.1000
that is written in the second box of the example picture that it has been attached.
Any hints or details explaination are highly appreciated.

function y = shipweightpmf(x)
s = (1:8)';
p = [0.15*ones(4,1); 0.1*ones(4,1)];
y = finitepmf(s,p,x);
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Programming en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!