Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What's the R version of example plot code? #2

Open
baif666 opened this issue Mar 17, 2021 · 0 comments
Open

What's the R version of example plot code? #2

baif666 opened this issue Mar 17, 2021 · 0 comments

Comments

@baif666
Copy link

baif666 commented Mar 17, 2021

I modified your example plot code and try it, but I found it plot one point twice (into 2 points), I guess this is the problem of plot() or points() function. What's the R version of this example plot code?
plot(mod$u, pch = 19, cex = 2, col = "grey90", xlab = "Factor 1", ylab = "Factor 2")
points(mod$u[meta$Group.ID == "Russia_Yamnaya",], pch = 8, cex = .6, col = "darkblue")
points(mod$u[meta$Group.ID == "Anatolia_N",], pch = 8, cex = .6, col = "salmon3")
My R version is:
platform x86_64-pc-linux-gnu
arch x86_64
os linux-gnu
system x86_64, linux-gnu
status
major 3
minor 5.1
year 2018
month 07
day 02
svn rev 74947
language R
version.string R version 3.5.1 (2018-07-02)
nickname Feather Spray
I changed it into this way and it worked
plot(f4_mod$u[,1], f4_mod[,2], pch = 19, cex = .5, col = "grey90", xlab = "Factor 1", ylab = "Factor 2")
points(f4_mod$u[meta$V4 == "XXXX",1], f4_mod[meta$V4 == "XXXX",2], pch = 8, cex = .3, col = "yellow3")

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant