pca
pca copied to clipboard
Scores
A getScores()
method would be useful.
To do this I used:
let scores = pca.predict(dataset)
I made several attempts before being able to get what I needed (the scores) but I'm not a statistician, it's true. Even a reference to the scores also in the documentation can help those who are not in the field, like me.
I'd also like to add. How do i get the principal components?
The U matrix produces the principal directions. From there do i simply, first create the PCA space,
genePCA = new ML.PCA(geneMat)
Then compute the principal components like this?
genePCA.predict(geneMat)
Also, once I've computed this, is each Float64Array a row or a column?