الأمثلة التفاعلية للتوزيع الثنائي

من MM*Stat Arabisch

مراجعة ١٢:٢٥، ١١ يوليو ٢٠٢٠ بواسطة H0130wij (نقاش | مساهمات) (Die Seite wurde neu angelegt: „المتغير العشوائي المنفصل الذي يحتوي عدد النجاحات A بعد n اعادة لهذه التجربة له الت…“)
(فرق) → مراجعة أقدم | المراجعة الحالية (فرق) | مراجعة أحدث ← (فرق)
اذهب إلى: تصفح, ابحث

المتغير العشوائي المنفصل الذي يحتوي عدد النجاحات A بعد n اعادة لهذه التجربة له التوزيع الثنائي مع العناصر n و P.

تابع كثافته الاحتمالية :


Mmengjavaimg1225.gif


<Rform name="binom"> n: <input name="n" type="text" size="5" maxlength="5" value="10"> prob: <input name="prob" type="text" size="5" maxlength="5" value="0.2"> <input type="submit" value=" Submit "> (You may need to reload the iframe below after submitting). </Rform> <R output="display" name="binom" convert="-trim" iframe="height:400px;"> if (exists("prob")) prob <- as.numeric(prob) else prob <- 0.6 if (exists("n")) n <- as.numeric(n) else n <- 30 x<- seq(0, n, 1) p <- dbinom(x, n, prob) param <- list(n, prob) main <- c("Binomialverteilung - Dichtefunktion", paste (c("Stichprobenumfang n", "Wahrscheinlichkeit p"), param, sep="=")) pdf(rpdf, width=5, height=5) plot(x,p, type="h", main=main) </R>


<Rform name="cdfbinom"> p: <input name="prob" type="text" size="5" maxlength="5" value="0.5"><input type="submit" value=" Absenden "> </Rform> <R output="html" name="cdfbinom" iframe="height:600px;"> if (exists("prob")) prob<-as.numeric(prob) else prob<-0.5 nmin=1; nmax=15; x=15 m <-pbinom(rep(0:x, each = nmax-nmin+1), nmin:nmax, prob) dim(m) <- c(nmax-nmin+1,x+1) m <- t(m) colnames(m) <- format(nmin:nmax) rownames(m) <- format(0:x) txt = paste("p=", prob, "
x\n") outHTML(rhtml, m, title=txt, format="f", digits=4) nmin=16; nmax=30; x=30 m <-pbinom(rep(0:x, each = nmax-nmin+1), rep(nmin:nmax,x), prob) dim(m) <- c(nmax-nmin+1,x+1) m <- t(m) colnames(m) <- format(nmin:nmax) rownames(m) <- format(0:x) outHTML(rhtml, m, title=txt, format="f", digits=4) </R>