1234567891011121314151617181920212223
function f = pweib(x,k,a) %PWEIB The Weibull distribution function % % f = pweib(x,k,a) % % If the scale parameter a is left out it is assumed % to be 1. if nargin < 3 a = 1; end if any(any(a<=0)) error('Parameter a is wrong') end if any(any(k<=0)) error('Parameter k is wrong') end neg = find(x <= 0); [n1,n2] = size(neg); x(neg) = ones(n1,n2); f = 1-exp(-(x./a).^k); f(neg) = zeros(n1,n2);
About Koders | Resources | Downloads | Support | Black Duck | Submit Project | Terms of Service | DMCA | Privacy Policy | Site Map| Contact Us
©2010 Koders is a trademark of Black Duck Software, Inc. Black Duck, Know Your Code and the Black Duck logo are registered trademarks of Black Duck Software, Inc. in the United States and other jurisdictions. All other trademarks are the property of their respective holders.