Thanks Rolf,
I used your solution in my original, actual function and it worked
very fine and a much more sophisticated solution than what I
originally came up with! Thanks to the other people who replied as
well -- I know that the message said it was a "Note" rather than a
"Warning", but it sound
Try this:
temp.fn.2 <- function(mean = 0, sd = 1, n = 101) {
x <- seq(mean - sd, mean + sd, length = n)
plot(x, dnorm(x), type = "l")
}
# test
temp.fn.2()
On Mon, Mar 2, 2009 at 8:46 PM, Rob Foxall wrote:
> Dear R-Help,
>
> I have written a function, which in simplified format can be repr
On Mon, Mar 2, 2009 at 7:46 PM, Rob Foxall wrote:
> Dear R-Help,
>
> I have written a function, which in simplified format can be represented as:
>
> temp.fn <- function(my.mean,my.sd){
> Parameters <- list(mean = my.mean, sd = my.sd)
> curve(do.call(dnorm,c(list(x), Parameters)), from = my.me
On 3/03/2009, at 2:46 PM, Rob Foxall wrote:
Dear R-Help,
I have written a function, which in simplified format can be
represented as:
temp.fn <- function(my.mean,my.sd){
Parameters <- list(mean = my.mean, sd = my.sd)
curve(do.call(dnorm,c(list(x), Parameters)), from = my.mean-my.sd,
Dear R-Help,
I have written a function, which in simplified format can be represented as:
temp.fn <- function(my.mean,my.sd){
Parameters <- list(mean = my.mean, sd = my.sd)
curve(do.call(dnorm,c(list(x), Parameters)), from = my.mean-my.sd,
to = my.mean+my.sd)
}
This works as I want it do.
5 matches
Mail list logo