compatibility(scene, method, subject = "all", averageType = "mean")subject:
If subject is "population" the return list will contain a numeric
value that has a range depending on the method. If
subject is "pair" the return list will contain a matrix
with all pairwise compatibilities. If subject is "individual"
the return list will contain a dataframe with a column containing IDs and
a column containing compatibility averages. If subject is "all"
the return list will contain all three of the items above.method is "si_echinacea" compatibility will be
calculated as sporophytic self incompatible (si) in the same manner as Echinacea
(and many other plants). For two individuals, they are incompatible if
they share any S alleles (columns s1 and s2) and they compatible otherwise.
When method is "dioecious" it is assumed that the column s1 will
contain either a 1 or 2 depending on the individual's sex. Thus, when
comparing two individuals, they are compatible if s1 of the first != s1
of the second, and s2 is ignored.pop <- simulateScene()
compatibility(pop, "si_echinacea")Run the code above in your browser using DataLab