<div dir="ltr">Apologies if this seemingly simple question has been answered before. I have found nothing from extensive searches of manuals and adegenet archives.<div><br></div><div>In my data set of 1,110+ individuals from 25 sites, a few individuals at 2 sites lack GPS coordinates. For pairwise comparisons of individuals that require coordinates, I eliminate samples with missing location data. </div><div><br></div><div>However, when I am collapsing the data set to populations using genind2genpop I would like to keep the genetic data from all samples and ignore the NA values in the genind@other$utms slot. If even one sample in a population is missing utm coordinates, the population values are NA </div><div><br></div><div>I want the population centroid returned to the genpop@other$utms slot to be the mean of the samples that DO have utm coordinates. The distances among populations are so large that any error introduced by a small number of missing locations will not affect my results. </div><div><br></div><div>I know how to specify a basic function for other.action (e.g., other.action=mean), but I can't see how to specify something like na.remove, na.omit, or complete.cases that would calculate the mean ignoring missing data.. Another option would be to replace missing @other$utms values with mean values for the population based on complete cases from within the genind2genpop call, but that also does not appear to be possible. </div><div><br></div><div>Is there an easy way to keep all my genetic observations and get a population centroids ignoring missing coordinates?</div><div><br></div><div><div><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr">____________<br><font size="2">Maile Neel<br>Professor; Director of the Norton-Brown Herbarium<br>
</font><span style="font-size:small">University of Maryland</span></div><div dir="ltr"><font size="2">Department of Plant Science and Landscape Architecture &<br>
Department of Entomology<br></font><br></div></div></div></div></div></div></div></div></div></div></div>
</div></div>