Skip to content

Trying to get around R

8 messages · Epselon, Charles C. Berry, Julian Burgos +2 more

#
I have three problems I am trying to simulate, that I am having difficulty
getting around with.

Problem 1. 
I want to determine the 85 percentile (the x value for which the sum of
probabilities becomes 0.85) of the following distributions (two binomials
and a Poisson with rate Lmbda= np of the two binomials): X ~B(10, 0.3),
Y~P(3) , 
Z~B(30, 0.1). I want to show that  that Y is a good approximation for Z but
not for X...(by examining these distributions for few
different percentiles)

Problem 2:
For a binomial distribution X ~ B(20, 0.4), I want to use R to calculate
P{|X ? ?| < 2} and verify that it is near or larger than 0.95. (Hint from
the text book: Since ? = 8 and   2.3 then you may want to read the
weights, or probabilities, of the values 6:10, into a vector v and then use
the command sum(v) to
calculate the sum.) Repeat this for another set of parameters of your
choice.

Problem 3:
Draw a sample of size 10, from a Poisson with Lambda= 5, and calculate the
mean and the standard deviation of this sample, Repeat this calculation with
size 20 and 30 and demonstrate
that ?X gets closer to ? as the sample size increases.

Thanks.

I would appreciate it if someone accompanied the codes with a brief
explanation so I can be able to replicate it myself.
#
Hello Epselon (if that is your name),

This sounds like homework questions.  From the R-help posting guide: 
"Basic statistics and classroom homework:  R-help is not intended for 
these."

If you have a specific question on R coding, do ask it (and provide 
reproducible code).  But you should not expect for people on the list to 
do your homework for you.  That is a big no-no.

Cheers,

Julian
Epselon wrote:
#
I am a newbie to R and Bio emails and

It is clear that newbies make "mistakes", I made several which were pointed
out and I am trying to fix them, and as I fix one I make another, in time
perhaps I will "know it all", but if it is like surgery, I will make
mistakes until I retire

But the response of the "old-timers" to these mistakes seems arrogant and
cruel and "off putting" and does NOT encourage more participation. In fact
it takes "real stuff" to continue after this putdown and that putdown.

There are 3,783 links to posting guidelines, which took 1.5 hours to find
and read and understand.

Why not a link on how the mistakes of the newbies will be dealt with?

Or a kindly response from the moderator personal to the newbie rather than
to the entire world?

Or a kindly general response as from Ben Bolker to my last infraction which
was "You might have better luck with this on the Bioconductor mailing list
..."

Rather than to the universe...
"Using the wrong list: this is for R-sig-mac, and the topic occcurred
there recently."

All in an effort to encourage promote useful and increasing exchange
participation

Or not....

Loren Engrav, MD
Univ Washington
This sounds like homework questions.
"Basic statistics and classroom homework:
these."

If you have a specific question on R
reproducible code).  But you should not expect
do your homework for you.  That is a big
Cheers,

Julian
______________________________________________
R-help at r-project.org
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the
and provide
#
Loren,

There's a good reason for replying to the list, rather than just to you 
personally: to let other readers of the list see the response, so that 
they don't duplicate it. Your original posting certainly looked like 
homework questions to me. This impression was reinforced by the fact 
that the posting was anonymous: this is surely a breach of general 
netiquette, rather than an R newbie error?

Students do attempt to get people on this list to do their homework for 
them. It is important, for the integrity of their degrees, that we 
minimise the occurrence of this. Regular contributors to this list (and 
I am not one) perform a huge public service. we should all be grateful 
for this.

Ted Catchpole.

 Visiting Fellow
 Univ of New South Wales at ADFA, Canberra, Australia
    _	  and University of Kent, Canterbury, England
   'v'	  - www.pems.adfa.edu.au/~ecatchpole          
  /   \	  - fax: +61 2 6268 8786		   
   m m    - ph:  +61 2 6268 8895             




Loren Engrav wrote on 11/20/2007 04:43 PM:
#
Good morning and thank you

One correction please

I was not the poster
I am engrav at u.washington.edu
Poster was Epselon <jazzyazza at hotmail.com>

What you say is most certainly true. But then the newbie corrections might
have the style displayed by Mr. Bolker to both educate and further promote
participation.

Loren Engrav
Univ Wash
Seattle
#
Hi Loren,

It wasn't my intention to sound arrogant, cruel or "off putting".
English is not my first language, and perhaps my message had a tone I
did not intended.  The person posting the message I responded was
literally asking for somebody on the list to do his/hers homework (there
are even references to "hints from the textbook").  This is not only
academically non-kosher, is also not the purpose of the R-help list.  I
pointed this to this person and invited him/her to come back with
specific questions on R coding.

The posting guidelines are easily accessible.  The first line in the
"Mailing Lists" section of the R website
(http://www.r-project.org/mail.html) states "Please read the
instructions below and the posting guide before sending anything to any
mailing list!", and displays a link to the guide.  There also a link to
the guide at the bottom of every message send through this list.  The
posting guide is not hard to find, and (in my opinion) it isn't long or
difficult to understand (in particular for anyone taking college level
statistics).

Julian
Loren Engrav wrote:
#
Hi and thank you

Discussion is surely tough via the web
And I have trouble with "tone" also, and English

My only point was that Epselon <jazzyazza at hotmail.com> received education
but not much encouragement IMO and

With the method of Bolker, it might be possible to achieve both for newbies,
ie both education and encouragement

But some might say "and why is that your problem?" which has some validity

And some might say "can't stand the heat? Then perhaps try leaving the
kitchen", which has some truth also

Probably best now return to makeGOGraph and postscript output as at this
point I either have a decorum point or I don't

Thank you for discussing/listening

Loren Engrav
Univ Wash
Seattle