Hello,
I am using names function to name an array.
It works first time when I use *as.numeric(names(myVar1)*
However, at a place later, when I tried to use a very similar line of code
*as.numeric(names(myVar2)*, it always returned 'numeric(0)' (or if I only
type 'names(myVar2), it gave me NULL'.
I just realize this:
For myVar1, I used colnames to name it firstly, and then convert myVar1 to
numeric;
However, I forgot to use rownames to name myVar2, instead I thought
as.numeric(names(myVar2)) would work.
Now I name myVar2 using rownames first, as.numeric(names(myVar2)) is
working.
Thank
Hello,
I have a self-defined function to be computed on each column in a matrix.
The basic idea is to ignore the elements that have value of 0 during
computation.
I should be able to write my own function but it could be computational
expensive, so I'd love to ask if anyone may have suggestions
Thank you all for the quick responses.
Setting 0 with *NA* is the right thing to do.
Also Peter, thanks to your package, using the command 'cos <-
cor(m,method='pearson',cosine=TRUE,use='p')' you mentioned' makes my life a
lot more easier.
zz
--
V
Hello
i need some precision about nipals in the chemometrics package in R .
When i use nipals in chemometrics i obtain T and P matrix.
I really don't understand what to do with these two matrix to obtain
the scores for every the component (like in spss fo example)
Comp1Comp2 C
metrics...) for calculation of the next PCA
component.
If someone can help me ?
Thank's a lot
2011/12/1 zz dd
> Hello
> i need some precision about nipals in the chemometrics package in R .
>
> When i use nipals in chemometrics i obtain T and P matrix.
>
> I really don't
> Sent from my phone. Please excuse my brevity.
>
> zz dd wrote:
>
> >Hello
> >The solution maybe there but i need to compute it into R if someone can
> >help me :
> >(Previously store score vector t in score matrix T; stor
> Perhaps you can try the examples given in
> http://www.jstatsoft.org/v18/i02 for getting a better idea about how
> the NIPALS algorithm works. BTW, yes,it looks like a homework question
> specially when your user name is "zz dd " so you
> can't be recognized.
>
&
That's solved.
Just a cor between X and ti values.
Thank you all.
2011/12/5 zz dd
> Thank's Pedro Madrones,
> you're right that i have removed my name of the email (because of Spam,
> and datas that i can't remove on the net).
> Ok, i explain a bit more :
9 matches
Mail list logo