As Nick suggested, you're confusing the name of an object with the name(s)
of its elements.
Study this example:
>
> lamda <- 0.2
> lamda
[1] 0.2
> lamda <- c(g=0.2)
> lamda
g
0.2
> lamda <- c(1,3,4)
> lamda
[1] 1 3 4
> lamda <- c(g=1, x=3, foo=4)
> lamda
g x foo
1 3 4
lamda
Hello Mike.
I'm not clear on why you would want to "state your g parameter" (In fact, I
don't even know for sure what you mean by that) with
> lamda<-c(g=0.2)
If you want a variable (vector) g containing 0.2, why don't you simply do:
> g<-0.2
If you need that lamda thing for some reason later on,
Euu...
g <- 0.2
Q <- exp(g)
or
lamda <- c(g=0.2)
exp(lamda)
Ivan
Le 11/26/2010 09:12, Mike Gibson a écrit :
I must be missing something.
I first state my g parameter with:
lamda<-c(g=0.2)
However, when I do the next step R is telling me "object g not found" Here is
my next step:
Q<-e
3 matches
Mail list logo