Entering edit mode
2.3 years ago
synat.keam
▴
100
Dear all,
Anyone has any idea why plotPCA shows smaller plot in R studio. Even though I tried to save it, but it did not work. I wanted to make the height a bit taller. Anyone can help fix? thank in advance!
Synat,
pcaData <- plotPCA(vsd, intgroup=c("Group", "Treatment"), returnData=TRUE)
percentVar <- round(100 * attr(pcaData, "percentVar"))
pca<- ggplot(pcaData, aes(PC1, PC2, color=Group, shape=Treatment)) +
geom_point(size=3) + theme_minimal() +
xlab(paste0("PC1: ",percentVar[1],"% variance")) +
ylab(paste0("PC2: ",percentVar[2],"% variance")) +
coord_fixed() + geom_point(size=4) +
labs(title = "Principle Component Analysis") +
theme(plot.title = element_text(hjust = 0.5, face = "bold", size = 14),
axis.text = element_text(face = "bold", size=12), axis.title = element_text(face = "bold", size=13),
legend.title = element_text(size = 13, face = "bold"), legend.text = element_text(size = 12))
You already got a solution, but you have duplicate
geom_point
calls with different sizes that you might want to combine.Hi Trivas,
thanks you for your suggestion. I will try your idea.
Thanks,
SK