calc_genetic_similarity: Calculate the genetic similarity between two individuals...

View source: R/script - gene-match-o-matic 2000.R

calc_genetic_similarityR Documentation

Calculate the genetic similarity between two individuals (based on SNPs)

Description

takes two vectors of SNPs, Each element in the vector should be the genotypes of one SNP, written as bases, e.g "CT" "CC" "AT" etc. Order, e.g. "CT" or "TC" is not taken into account. It's important that the order of SNPs in the two vectors are the same. Returns an integer between 1 and 0 (0 = 0

Usage

calc_genetic_similarity(sample1, sample2, naCutoff = 50)

Arguments

SNPs1

the first vector of SNPs

SNPs2

the second vector of SNPs


Eiriksen/Genotools documentation built on Oct. 1, 2022, 1:40 a.m.