Post date: Mar 04, 2020 3:3:9 PM
Genetic distances:
Read this!
https://dyerlab.github.io/applied_population_genetics/genetic-distances.html
What I have: a matrix of probabilities of being heterozygotes for each SNPs
Adegenet package in R can calculate genetic distances, but based on genotypes (AA AT TT)
https://popgen.nescent.org/2015-05-18-Dist-SNP.html
Try Euclidian distance based on continious data:
https://stackoverflow.com/questions/5559384/euclidean-distance-of-two-vectors
Should I convert my probabilitities into a genotype matrix - based on the vcf file?
PCA axis could be a distance? It spread individuals... try that!
Also how to calculate spatial distances from coordinates?
Maybe I can do the same techinuqe for both (wuick and dirty peak into the data)
1 - calculate euclidian distance based on (a) probability of being hets (b) spatial distances
2 - plot genetic distance versus spatial distance
Aouch, I am dealing with more than one genetic values - how to handle genetic distance in matrices?
https://www.rdocumentation.org/packages/hopach/versions/2.32.0/topics/distancematrix
Find a way to compute
1 - pairwise euclidian distance on proba of being hets
2 - pairwise spatial distance = how many meters separate individual a and b
3 - plot both