<html dir="ltr">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" id="owaParaStyle">
<!--
p
{margin-top:0;
margin-bottom:0}
-->
P {margin-top:0;margin-bottom:0;}</style>
</head>
<body ocsi="0" fpstyle="1">
<div style="direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;"><br>
<div><font size="2">Hello, <br>
<br>
so I had understood the question, and given you the answer - use the 'pop' argument in ?scatter.dapc.<br>
<br>
Cheers<br>
Thibaut<br>
</font></div>
<div style="font-family: Times New Roman; color: #000000; font-size: 16px">
<hr tabindex="-1">
<div style="direction: ltr;" id="divRpF504350"><font face="Tahoma" size="2" color="#000000"><b>From:</b> Irina Ilyushkina [Irina.Ilyushkina@vuw.ac.nz]<br>
<b>Sent:</b> 24 February 2015 22:42<br>
<b>To:</b> Jombart, Thibaut<br>
<b>Subject:</b> RE: scatter plot problem<br>
</font><br>
</div>
<div></div>
<div>
<div style="direction:ltr; font-family:Tahoma; color:#000000; font-size:10pt">I'm sorry for double posting but I'm afraid my Outlook might have failed to include the images in the e-mail.
<div><br>
</div>
<div><span style="font-size:13.3333330154419px; background-color:rgb(255,255,255)">Hi,</span>
<div style="font-size:13.3333330154419px; background-color:rgb(255,255,255)"><br>
</div>
<div style="font-size:13.3333330154419px; background-color:rgb(255,255,255)">Thank you very much for the reply! I'm sorry I didn't explain everything clearer. Initially I have 2 populations and they form 3 clusters in DAPC, here is the scatterplot I get with
command "scatter(dapc_data, posi.da="bottomleft", bg="white", pch=17:22, scree.da=FALSE, col=myCol)" </div>
<div style="font-size:13.3333330154419px; background-color:rgb(255,255,255)">
<p></p>
<img src="cid:7fbe74d8-9d03-420b-a8dd-d913fb75500c" style="width:500px; height:460px">
<p></p>
<div style="font-size:13.3333330154419px">the assignment to the clusters didn't match my population structure perfectly so I need to indicate the origin (which one of 2 initial populations) of each individual in the clusters. </div>
<div style="font-size:13.3333330154419px"><br>
</div>
<div style="font-size:13.3333330154419px">I made 2 plots manually in Photoshop to represent my idea better:</div>
<div style="font-size:13.3333330154419px">
<p></p>
<p></p>
<img src="cid:859dc59a-2be3-4fa9-8b39-08413fa5b536" style="width:480px; height:360px">
<p></p>
<br>
<div class="a6S" dir="ltr" style="position:absolute; font-family:arial,sans-serif; left:341px; top:822px">
<br>
</div>
<br>
</div>
<div style="font-size:13.3333330154419px">or an easier to read color representation:</div>
<br>
<p></p>
<div class="a6S" dir="ltr" style="position:absolute; font-family:arial,sans-serif; left:350px; top:433px">
<div id=":2x5" class="T-I J-J5-Ji aQv T-I-ax7 L3 a5q" tabindex="0" style="position:relative; display:inline-block; font-size:11px; font-weight:bold; text-align:center; white-space:nowrap; margin-right:0px; height:24px; line-height:23px; min-width:0px; outline:0px; padding:0px; color:rgb(68,68,68); border:1px solid rgb(115,115,115); margin-left:8px; width:30px">
<div class="aSK J-J5-Ji aYr" style="position:relative; display:inline-block; vertical-align:middle; height:21px; width:21px">
</div>
</div>
<div id=":2x6" class="T-I J-J5-Ji aQv T-I-ax7 L3 a5q" tabindex="0" style="position:relative; display:inline-block; font-size:11px; font-weight:bold; text-align:center; white-space:nowrap; margin-right:0px; height:24px; line-height:23px; min-width:0px; outline:0px; padding:0px; color:rgb(68,68,68); border:1px solid rgb(115,115,115); margin-left:8px; width:30px">
<div class="wtScjd J-J5-Ji aYr aQu" style="position:relative; display:inline-block; vertical-align:middle; height:21px; width:21px">
</div>
</div>
</div>
<br>
<p></p>
<img src="cid:fddf3b1d-c165-41a8-86b0-b374fab1d57f" style="width:480px; height:360px"><br>
<p></p>
</div>
<div style="font-size:13.3333330154419px; background-color:rgb(255,255,255)">
<div class="a6S" dir="ltr" style="position:absolute; font-family:arial,sans-serif">
<div id=":2xb" class="T-I J-J5-Ji aQv T-I-ax7 L3 a5q" title="Download" tabindex="0" style="position:relative; display:inline-block; font-size:11px; font-weight:bold; text-align:center; white-space:nowrap; margin-right:0px; height:24px; line-height:23px; min-width:0px; outline:0px; padding:0px; color:rgb(68,68,68); border:1px solid rgb(115,115,115); margin-left:8px; width:30px">
<div class="aSK J-J5-Ji aYr" style="position:relative; display:inline-block; vertical-align:middle; height:21px; width:21px">
</div>
</div>
<div id=":2xc" class="T-I J-J5-Ji aQv T-I-ax7 L3 a5q" title="Save to Drive" tabindex="0" style="position:relative; display:inline-block; font-size:11px; font-weight:bold; text-align:center; white-space:nowrap; margin-right:0px; height:24px; line-height:23px; min-width:0px; outline:0px; padding:0px; color:rgb(68,68,68); border:1px solid rgb(115,115,115); margin-left:8px; width:30px">
<div class="wtScjd aQu J-J5-Ji aYr" style="position:relative; display:inline-block; vertical-align:middle; height:21px; width:21px">
<div class="T-aT4" style="display:inline-block; position:relative; direction:ltr; height:19px; width:19px">
<div></div>
<div class="T-aT4-JX" style="height:19px; width:19px; top:0px; left:0px; position:absolute">
</div>
</div>
</div>
</div>
</div>
<br>
</div>
<div style="font-size:13.3333330154419px; background-color:rgb(255,255,255)"><br>
</div>
<div style="font-size:13.3333330154419px; background-color:rgb(255,255,255)"><br>
</div>
<div style="font-size:13.3333330154419px; background-color:rgb(255,255,255)">Many thanks,</div>
<div style="font-size:13.3333330154419px; background-color:rgb(255,255,255)"><br>
</div>
<div style="font-size:13.3333330154419px; background-color:rgb(255,255,255)">Irina</div>
<div><br>
<div style="font-family:Tahoma; font-size:13px">
<div style="font-family:Tahoma; font-size:13px">
<div>Irina Ilyushkina</div>
<div><br>
</div>
<div>PhD Candidate</div>
<div><font face="Arial,sans-serif" size="2"><span style="font-size:10pt">School</span></font><font face="Arial,sans-serif" size="2"><span style="font-size:10pt"> of </span></font><font face="Arial,sans-serif" size="2"><span style="font-size:10pt">Biological</span></font><font face="Arial,sans-serif" size="2"><span style="font-size:10pt"> Sciences</span></font></div>
<div>
<div style="font-family:Tahoma,Arial,Helvetica; font-size:medium; margin:0px"><font face="Times New Roman,serif" size="3"><span style="font-size:12pt"><font face="Arial,sans-serif" size="2"><span style="font-size:10pt">Victoria</span></font><font face="Arial,sans-serif" size="2"><span style="font-size:10pt"> </span></font><font face="Arial,sans-serif" size="2"><span style="font-size:10pt">University</span></font><font face="Arial,sans-serif" size="2"><span style="font-size:10pt"> of </span></font><font face="Arial,sans-serif" size="2"><span style="font-size:10pt">Wellington</span></font></span></font></div>
<div style="font-family:Tahoma,Arial,Helvetica; font-size:medium; margin:0px"><font face="Times New Roman,serif" size="3"><span style="font-size:12pt"><font face="Arial,sans-serif" size="2"><span style="font-size:10pt">P O Box</span></font><font face="Arial,sans-serif" size="2"><span style="font-size:10pt"> 600</span></font></span></font></div>
<div style="font-family:Tahoma,Arial,Helvetica; font-size:medium; margin:0px"><font face="Times New Roman,serif" size="3"><span style="font-size:12pt"><font face="Arial,sans-serif" size="2"><span style="font-size:10pt">Wellington 6140</span></font></span></font></div>
<div style="font-family:Tahoma,Arial,Helvetica; font-size:medium; margin:0px"><font face="Times New Roman,serif" size="3"><span style="font-size:12pt"><font face="Arial,sans-serif" size="2"><span style="font-size:10pt">New Zealand</span></font></span></font></div>
<div style="font-family:Tahoma,Arial,Helvetica; font-size:medium; margin:0px"><font face="Times New Roman,serif" size="3"><span style="font-size:12pt"><font face="Arial,sans-serif" size="2"><span style="font-size:10pt"> </span></font></span></font></div>
<div style="font-family:Tahoma,Arial,Helvetica; font-size:medium; margin:0px"><font face="Times New Roman,serif" size="3"><span style="font-size:12pt"><font face="Arial,sans-serif" size="2"><span style="font-size:10pt">Mobile: 0223898085</span></font></span></font></div>
<div style="font-family:Tahoma,Arial,Helvetica; font-size:medium; margin:0px"><font face="Times New Roman,serif" size="3"><span style="font-size:12pt"><font face="Arial,sans-serif" size="2"><span style="font-size:10pt">Tel: 04 463 5233 Ext 8135</span></font></span></font></div>
</div>
</div>
</div>
</div>
<div style="font-family:Times New Roman; color:#000000; font-size:16px">
<hr tabindex="-1">
<div id="divRpF28695" style="direction:ltr"><font face="Tahoma" size="2" color="#000000"><b>From:</b> Jombart, Thibaut [t.jombart@imperial.ac.uk]<br>
<b>Sent:</b> Tuesday, 24 February 2015 12:58 a.m.<br>
<b>To:</b> Irina Ilyushkina; adegenet-forum@lists.r-forge.r-project.org<br>
<b>Subject:</b> RE: scatter plot problem<br>
</font><br>
</div>
<div></div>
<div>
<div style="direction:ltr; font-family:Tahoma; color:#000000; font-size:10pt"><br>
<div><font size="2">Hi Irina, <br>
<br>
I am not sure I understand what you are after, so sorry if I miss the point. If you want to represent a different group to the one used in the DAPC analysis on the DAPC scatterplot, use the argument 'grp'; from ?scatter.dapc:<br>
<br>
grp: a factor defining group membership for the individuals. The<br>
scatterplot is optimal only for the default group, i.e. the<br>
one used in the DAPC analysis.<br>
<br>
Cheers<br>
Thibaut<br>
<br>
<br>
</font></div>
<div style="font-family:Times New Roman; color:#000000; font-size:16px">
<hr tabindex="-1">
<div id="divRpF516353" style="direction:ltr"><font face="Tahoma" size="2" color="#000000"><b>From:</b> adegenet-forum-bounces@lists.r-forge.r-project.org [adegenet-forum-bounces@lists.r-forge.r-project.org] on behalf of Irina Ilyushkina [Irina.Ilyushkina@vuw.ac.nz]<br>
<b>Sent:</b> 23 February 2015 04:41<br>
<b>To:</b> adegenet-forum@lists.r-forge.r-project.org<br>
<b>Subject:</b> [adegenet-forum] scatter plot problem<br>
</font><br>
</div>
<div></div>
<div>
<div style="direction:ltr; font-family:Tahoma; color:#000000; font-size:10pt">
<div id="dic_bubble" class="selection_bubble" style="z-index:9999; visibility:hidden">
</div>
Hi,
<div><br>
</div>
<div>I'm new to R and would be extremely grateful if someone could help me with my problem. I need to indicate (with labels, with color, etc.) the original group assignment of every individual in the DAPC inferred clusters on the scatter plot. table.value(table(pop(x),
grp$grp) is showing the type of plot I'm after but it's a bit confusing when you have to consider two plots at the same time so I'm looking for a way to combine both in one plot if it is possible.</div>
<div><br>
</div>
<div>Many thanks,<br>
<div><br>
<div style="font-family:Tahoma; font-size:13px">
<div style="font-family:Tahoma; font-size:13px">
<div>Irina</div>
<div></div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>