For 2a, what people need to write is dbinom, not
rbinom...
So I wrote my function for dbinom and drew the pmf. Didn't need to
write rbinom...
So can I just use rbinom for 2c?
On Sunday, February 23, 2003, at 08:41 PM, Kosuke Imai wrote:
Here are some clarification as to what built-in
functions you can and
cannot use. basically, you shouldn't use rbinom and rt.
2a. write your own function. don't use rbinom
2b. don't use dbeta.
2c. you can use rbeta and the function you wrote in 2a. don't use
rbinom
3a. write your own function. don't use rt
3b. you can use the function you wrote in 2a. don't use rbinom
Kosuke
On Sun, 23 Feb 2003, Phillip Y. Lipscy wrote:
We're running into trouble with taking draws
from the beta
distribution on 2c.
Our function for 2b gives us nice looking curves, but when alpha &
beta < 1,
the curve goes to infinity at the extremes. So when we take draws
from the
beta distribution, how are we to weigh the probability of those
infinite
extremes? rbeta() seems to give a result consistent with the shape
of the
curves - i.e.
for (alpha & beta = really small) --> returns 0 and 1s
for (alpha & beta = really big) --> returns values very close to 0.5
Or, basically, is there a forumla for the probability mass function
for a beta
distribution?
Thanks,
Phillip
-------------------------------------------------
Phillip Y. Lipscy
Perkins Hall Room #129
35 Oxford Street
Cambridge, MA 02138
(617)493-4893 DORM
(617)851-8220 CELL
lipscy(a)fas.harvard.edu
http://www.people.fas.harvard.edu/~lipscy/
First Year Student, Ph.D. Program
Harvard University, FAS, Department of Government
-------------------------------------------------
_______________________________________________
gov2001-l mailing list
gov2001-l(a)fas.harvard.edu
http://www.fas.harvard.edu/mailman/listinfo/gov2001-l
_______________________________________________
gov2001-l mailing list
gov2001-l(a)fas.harvard.edu
http://www.fas.harvard.edu/mailman/listinfo/gov2001-l