vqv / ggbiplot

A biplot based on ggplot2
302 stars 159 forks source link

ggbiplot size between vectors #63

Open hiyamgh opened 4 years ago

hiyamgh commented 4 years ago

I have plot that is produced as follows: pca_pure

How can I add some space between the vectors ? I want larger angles between them because they are not apparent

This is my code:

ggbiplot(df.pca,  obs.scale = 1, var.scale = 1,
  alpha=0) + 
  ggtitle("PCA")+
  theme_minimal()+
  theme(legend.position = "bottom") 
hiyamgh commented 4 years ago

Update

I only made the plot somehow looking better by:

pca_pure

This looks somewhat better, but I will not close the issue as my problem is not solved completely

My code now:

ggbiplot(df.pca,
  alpha=0, varname.size = 4, varname.adjust=5) + 
  ggtitle("PCA")+
  theme_minimal()+
  theme(legend.position = "bottom") 
bneises commented 4 years ago

@hiyamgh I don't have an answer for you, but you may have better luck using the latest maintained fork of this function: AMR::ggplot_pca() or using this (older) fork that uses ggrepel to add the text: https://github.com/tpq/ggbiplot

That last one is also nice for only printing a subset of the labels if that would help.