On 27/07/12 20:55, David Winsemius wrote:
On Jul 26, 2012, at 10:06 AM, FJ M wrote:
It would be a useful additon to the help page to add
integrate(dnorm, lower = -1.96, upper = 1.96, mean = 2, sd = 1)
Wouldn't most statisticians instead use the more accurate and
undoubtedly faster:
-0700
From: ehl...@ucalgary.ca
To: kri...@ymail.com
CC: chicagobrownb...@hotmail.com; r-help@r-project.org
Subject: Re: [R] Integrate(dnorm) with different mean and standard
deviation help
On 2012-07-23 19:48, Pascal Oettli wrote:
Hello,
Maybe the following could help:
f <- function(x) dno
ample.
>
> Thanks,
>
> Frank
> Chicago
>
>
>> Date: Mon, 23 Jul 2012 19:54:45 -0700
>> From: ehl...@ucalgary.ca
>> To: kri...@ymail.com
>> CC: chicagobrownb...@hotmail.com; r-help@r-project.org
>> Subject: Re: [R] Integrate(dnorm) with different mean
.com; r-help@r-project.org
> Subject: Re: [R] Integrate(dnorm) with different mean and standard deviation
> help
>
> On 2012-07-23 19:48, Pascal Oettli wrote:
> > Hello,
> >
> > Maybe the following could help:
> >
> > > f <- function(x) dnorm(x, mean
Hi,
Check this link
(https://stat.ethz.ch/pipermail/r-help/2010-February/227902.html).
Hope it helps.
A.K.
- Original Message -
From: FJ M
To: R
Cc:
Sent: Monday, July 23, 2012 10:23 PM
Subject: [R] Integrate(dnorm) with different mean and standard deviation help
I'm tryi
Hello,
Yes, I should learn to read.
Regards
Le 24/07/2012 11:54, Peter Ehlers a écrit :
On 2012-07-23 19:48, Pascal Oettli wrote:
Hello,
Maybe the following could help:
> f <- function(x) dnorm(x, mean=2, sd=1)
> integrate(f, -1.96, 1.96)
0.4840091 with absolute error < 1.4e-12
Or yo
integrate(dnorm, -1.96, 1.96, mean=2, sd=1)
Read the help for integrate! It tells you that the
integrate function has a "..." argument which consists of
"additional arguments to be passed to f".
cheers,
Rolf Turner
On 24/07/12 14:23, FJ M wrote:
I'm trying to provide different
On 2012-07-23 19:48, Pascal Oettli wrote:
Hello,
Maybe the following could help:
> f <- function(x) dnorm(x, mean=2, sd=1)
> integrate(f, -1.96, 1.96)
0.4840091 with absolute error < 1.4e-12
Or you could note the '...' argument indicated on the help page:
integrate(dnorm, lower = -1.96
Try
> integrate(dnorm, mean = 2, sd = 1, -1.96, 1.96)
0.4840091 with absolute error < 1.4e-12
HTH,
Jorge.-
On Mon, Jul 23, 2012 at 10:23 PM, FJ M <> wrote:
>
> I'm trying to provide different parameters to the integrate function for
> various probability functions. I'm using dnorm as the simpl
Hello,
Maybe the following could help:
> f <- function(x) dnorm(x, mean=2, sd=1)
> integrate(f, -1.96, 1.96)
0.4840091 with absolute error < 1.4e-12
HTH
Regards.
Le 24/07/2012 11:23, FJ M a écrit :
I'm trying to provide different parameters to the integrate function for
various probabilit
I'm trying to provide different parameters to the integrate function for
various probability functions. I'm using dnorm as the simplest example here.
For instance integrate(dnorm, -1.96, 1.96) produces the correct answer for a
normal distribution with mean 0 and standard deviation 1. I've tried
11 matches
Mail list logo