[Distr-commits] r352 - pkg/distrTeach/R
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Tue Nov 25 06:25:29 CET 2008
Author: stamats
Date: 2008-11-25 06:25:29 +0100 (Tue, 25 Nov 2008)
New Revision: 352
Modified:
pkg/distrTeach/R/illustCLT.R
Log:
small buglet ...
Modified: pkg/distrTeach/R/illustCLT.R
===================================================================
--- pkg/distrTeach/R/illustCLT.R 2008-11-25 05:09:12 UTC (rev 351)
+++ pkg/distrTeach/R/illustCLT.R 2008-11-25 05:25:29 UTC (rev 352)
@@ -20,16 +20,16 @@
if(is.na(E(Distr)) || is.na(var(Distr)))
stop(gettextf("Distribution %s does not have a variance/expectation.",
Distrname ))
- if(is(Distr,"LatticeDistribution")||is(Distr,"AbscontDistribution"))
+ if(is(Distr,"LatticeDistribution")||is(Distr,"AbscontDistribution"))
Sn <- convpow(Distr,k)
else {
Sn <- 0
o.warn <- getOption("warn"); options(warn = -1)
on.exit(options(warn=o.warn))
for(j in 1:k)
- Sn <- Sn + Distr
- }
- options(warn=o.warn)
+ Sn <- Sn + Distr
+ options(warn=o.warn)
+ }
Tn <- make01(Sn)
plotCLT(Tn,k, summands = Distrname)
}
More information about the Distr-commits
mailing list