This is a test version of Biostars. For the public version, visit https://www.biostars.org.
How to run logisticPCA on binary data

I am trying to run logisticPCA in R on my binary data. I tried the following method (prcomp) for PCA. Please suggest a code how to use logisticPCA instead.

dd_pca_full <- read.csv("final.csv", sep=",")

dd.pca.full <- prcomp(dd_pca_full[c(2:20251)],
                 center = TRUE)

dd.pca.full.plot <- autoplot(dd.pca.full,
                        data = dd_pca_full,
                        colour = 'country')


Example:
code   ppc  aga    dmsC    hyaA    mgtB
AL2 1   1   1   1   1
AL2 0   1   1   0   1
AL2 1   1   1   1   1
AL3 1   1   0   1   1
AL3 0   0   1   1   1
AL3 1   1   1   1   1
AL3 1   1   1   1   1
binary genome pca logisticpca

0 answers

No answers yet.

Log in to answer this question.