If we refer to the sample mean as xbar, the population mean as mu, the population standard deviation as sigma, and the sample size as n, these statements are equivalent to:
gskew(n,mu,sd,skew)
n
,
where the mean, standard deviation, and skewness coefficient
of the unimodal skewed population
are mu
, sd
, and skew
respectively.
gbimod(n,mu,sd,d)
n
,
where the population mean and standard deviation
for a bimodal symmetric population
are mu
and sd
respectively.
The argument d
is the distance from mu
to each mode.
Note that d
cannot be greater than sd
.
gbinom(n,p,low,high,scale)
S-PLUS help is available in this on-line guide.
clt.ssc
by following these steps.
clt.ssc
link above.
clt.ssc
.
You may need to change the box ``Look in'' to Desktop
and the box ``File type'' to either all files or *.ssc files.
This opens up a Script Window.
gnorm
into S-PLUS.
> gskew(1,100,10,0.5)This code will draw graphs for several values simultaneously.
> for(skew in seq(-4,4,0.5)){gskew(1,100,10,skew)}
> for(n in c(1,2,5,10,15,20,25,30,50,100)){gskew(n,100,10,1)}
In the previous graphs, how do the center (mean), spread (standard deviation), and skewness change as sample size increases?
> for(n in c(1,2,5,10,15,20,25,30,50,100)){gskew(n,100,10,-5)}In the previous graphs, how do the center (mean), spread (standard deviation), and skewness change as sample size increases?
> gbimod(1,100,10,8)This code will draw graphs for several values simultaneously.
> for(d in seq(8.1,9.9,0.2)){gbimod(1,100,10,d)}
> for(n in c(1,2,5,10,15,20,25,30,50,100)){gbimod(n,100,10,9.2)}
In the previous graphs, how do the center (mean), spread (standard deviation), and skewness change as sample size increases?
clt.ssc
into S-PLUS
and answer the questions below.
You should write your answers on
this form
and turn it in to your lab instructor by the due date.
Further S-PLUS help is available in this on-line guide.
> for(n in c(1,4)){gskew(n,100,10,3)}
Find the mean and the standard deviation of the sampling distribution of xbar.
Find the probability that xbar exceeds 110
assuming that the sampling distribution is normal
by finding an area under the appropriate normal curve using pnorm
or the normal table in your book.
The area to the right of 110 under the green curve is the actual probability
that the sample mean exceeds 110 when the population is skewed.
The area to the right of 110 under the red curve is the calculation
of the probability assuming the population is normal.
Based on the graph, is the area under the normal curve too small, too large, or just about right?
> for(n in c(1,400)){gskew(n,100,10,3)}
Find the mean and the standard deviation of the sampling distribution of xbar.
Find the probability that xbar exceeds 101
assuming that the sampling distribution is normal
by finding an area under the appropriate normal curve using pnorm
or the normal table in your book.
The area to the right of 101 under the green curve is the true probability
that the sample mean exceeds 101 when the population is skewed.
The area to the right of 101 under the red curve is the calculation
of the probability assuming the population is normal.
Based on the graph, is the area under the normal curve too small, too large, or just about right?
np
> 5 and n(1-p)
> 5.
If p = 0.01
,
at least how large should the sample be according to the rule?
If p = 0.2
,
at least how large should the sample be according to the rule?
If p = 0.5
,
at least how large should the sample be according to the rule?
n
equal to 30
and p
equal to 0.01, 0.2, 0.5 and 0.9.
> for(p in c(0.01,0.2,0.5,0.9)){gbinom(30,p)}
Which statement is more correct?
A. As long as n
is at least 30,
the binomial distribution is well approximated by a normal curve.
B. When p
is close to 0 or 1,
n
must be larger for the normal approximation to be good
than when p
is close to 0.5.
Bret Larget, larget@mathcs.duq.edu