<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Arial,Helvetica,sans-serif;" dir="ltr">
<p><span style="font-size: 12pt;">(2nd try) </span><br>
</p>
<div style="color: rgb(0, 0, 0);">
<div>
<div id="divtagdefaultwrapper" dir="ltr" style="font-size:12pt; color:#000000; font-family:Calibri,Arial,Helvetica,sans-serif">
<p>Hi all, </p>
<p><br>
</p>
<p>I have a genlight object and I would like to analyze the contributions of different alleles to populations structure.</p>
<p><br>
</p>
<p></p>
<div>The example on the manual is for genind objects and a previous answer indicated that the fix-around, using as.data.frame, is only good for haploid data. <a href="http://lists.r-forge.r-project.org/pipermail/adegenet-forum/2014-May/000840.html" class="OWAAutoLink" id="LPlnk51232" style="font-size:12pt" previewremoved="true">http://lists.r-forge.r-project.org/pipermail/adegenet-forum/2014-May/000840.html</a></div>
<div><br>
</div>
<div>Is it yet possible to do section 3.4 (Jombart and Collins 2015) with a diploid dataset? It would be really cool if so!</div>
<div><br>
</div>
<div>Thanks,</div>
<div><br>
</div>
<div>Alan</div>
<div><br>
</div>
<div>
<div>> pldata</div>
<div> /// GENLIGHT OBJECT /////////</div>
<div><br>
</div>
<div> // 223 genotypes, 76,288 binary SNPs, size: 9 Mb</div>
<div> 0 (0 %) missing data</div>
<div><br>
</div>
<div> // Basic content</div>
<div> @gen: list of 223 SNPbin</div>
<div> @ploidy: ploidy of each individual (range: 2-2)</div>
<div><br>
</div>
<div> // Optional content</div>
<div> @ind.names: 223 individual labels</div>
<div> @loc.names: 76288 locus labels</div>
<div> @pop: population of each individual (group size range: 1-1)</div>
<div> @other: a list containing: sex phenotype pat mat </div>
<div><br>
</div>
<div>> freq399 <- tab(genind2genpop(pldata[loc=c("41837")]),freq=TRUE)</div>
<div>Error in genind2genpop(pldata[loc = c("41837")]) : </div>
<div> x is not a valid genind object</div>
<img naturalheight="647" naturalwidth="557" size="41041" id="img789595" tabindex="0" style="max-width: 99.9%; user-select: none;" aria-expanded="false" src="cid:732fdd8f-ab46-46ff-97d3-0dd3b4bc8971"><br>
<br>
</div>
<div><br>
</div>
<div><br>
</div>
<div></div>
<br>
<p></p>
<div id="Signature">
<div><b style="line-height:14.1999998092651px; color:rgb(0,0,128); font-family:Tahoma; font-size:x-small; background-color:rgb(255,255,255)"><font color="000000" face="Tahoma" style="line-height:normal"></font></b></div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>