We can use minitab to find values of the probability density function, of the cumulative distribution function and of the quantiles of several discrete and continuous random variables. We use the commands cdf for cumulative distribution function pdf for probability density function invcdf for quantile random to find a random sample The argument of these commands could be either a constant or a column. For the command invcdf, the values of the argument have to be in the interval (0,1). To specify the distribution we want, we use a subcommand. If we do not specify the distribution, minitab uses the standard normal distribution. We can either ask minitab to find the values or to store those values. For example, to store the values in the column c3 MTB > cdf c1 c3; SUBC> bino 5 .5. MTB > print c1 c3 ROW C1 C3 1 1 0.1875 2 3 0.8125 3 5 1.0000 To find the values of the cdf at the values in c1: MTB > cdf c1; SUBC> bino 5 .5. K P( X LESS OR = K) 1.00 0.1875 3.00 0.8125 5.00 1.0000 Instead of columns, we can use constants. Possible subcommands for distributions and their parameters are BERNOULLItrials p = K BETA a = K b = K BINOMIAL n = K, p = K CAUCHY[a = K [b = K]] CHISQUAREv = K DISCRETEdist. with values in C and probabilites in C EXPONENTIAL[b = K] F df numerator = K, df denominator = K GAMMA a = K b = K INTEGER discrete uniform on integers K to K LAPLACE [a = K [b =K]] LOGISTIC [a = K [b = K]] LOGNORMAL [mu = K [sigma =K]] POISSONmu = K NORMAL[mu = K [sigma = K]] T degrees of freedom = K UNIFORM [continuous on the interval K to K] WEIBULL a = K b = K We also can use the windows menu; going to calc>probability distributions> To find the pdf and cdf of a binominal with n=30 and p=.6, we do: MTB > set c1 DATA> 0:30 DATA> end MTB > pdf c1 c2; SUBC> bino 30 .6. MTB > cdf c1 c3; SUBC> bino 30 .6. MTB > print c1 c2 c3 We get the table in page 105 of the book. To get the distribution of the negative binomial, we could use the following relation P(Bin(n,p)=
n-k+1) To get a table with the pdf and cdf of the hypergeometric, we use the program (hyperg.exe) which comes with the cd-rom in the textbook. Using the cd-rom coming with the book, we can install several files in the path c:\istat. You need to install this folder precisely in the drive c. Now, the program we are looking for is in the subfolder chap4. To use the program you have to double click in the icon of the program hyperg.exe. You will be asked for the values of N, M and n. If you enter 75 [enter], 15 [enter] and 10 [enter], you will the get the table 4.2 in page 106 of the textbook. You also will get this table in a .DAT file in the your folder c:\istat\data. You can open this file using a word processor, such as Windows Word or Notepack. Usually, the .DAT files in Windows do not open. You may want to set your operating system so that the .DAT files open. If you do not know how to do this, you always can use minitab to import .DAT files to your worksheet. If you cannot tun the hypergeometric macro you can run the following alternative macro: ****************** # k3=N is the total number of elements # k1=M is the number of elements of the 1st type # k2=N-M is the number of elements of the 2nd type # k4=n is the number of elements in the sample # you must run this macro n+1 times # # # pdf k5 k6; binom k1 .5. let k6=k6*(2**k1) let k10=k4-k5 pdf k10 k7; binom k2 .5. let k7=k7*(2**k2) pdf k4 k8; binom k3 .5. let k8=k8*(2**k3) let k5=k5+1 let c101(k5)=k6*k7/k8 end **************************** Probably, you can do a better macro than the previous one. You can find values of the gamma function by following the minitab commands in the page 123 of the textbook. We can graph densities of several distributions. For example, running the commands (or the macro): *************** set c1 0.:6/.01 end pdf c1 c2; gamma .5 1. pdf c1 c3; gamma 1 1. pdf c1 c4; gamma 2 1. plot c2*c1 c3*c1 c4*c1; overlay; conne; Minimum 2 0; Maximum 2 1. End *************** we get the graph in the page 123 of the textbook.