MATLAB: How can ı creat poisson random variables

MATLAB

lambda = 75;
N = 0:200; %Number of people
P = poisspdf(N,lambda);
E=lambda;%expected value
V=lambda; %variance
bar(N,P,1);
xlabel('Observation');
ylabel('Probability');
I have a poisson distribution but I need to create poisson random numbers intead of N.CAn someone help me?
Thanks!

Best Answer

You can generate random number by using poissonrnd function, like;
lambda = 75;
r = poissrnd(lambda);
Or, if you want to generate 1000-by-1 random number array, you can do it by:
r = poissrnd(lambda,1000,1);