powered by
Function to perform create a transformation of phenotypes
creating.phenotypic.transform( population, phenotypic.transform.function = NULL, trait = 1, test.h2 = TRUE, gen = NULL, database = NULL, cohorts = NULL, h2 = seq(0.05, 0.5, by = 0.05), export.h2 = FALSE, n.sample = 1000 )
Population-list with a new phenotypic transformation function
Population list
Phenotypic transformation to apply
Trait for which a transformation is to be applied
Set to FALSE to not perform heritability check
Quick-insert for database (vector of all generations to export)
Groups of individuals to consider for the export
Quick-insert for database (vector of names of cohorts to export)
Vector of heritability input to test (before introducing noise from trafo; default: seq(0.05,0.5, by = 0.05))
Set TRUE to export matrix of heritability before/after transformation
Sample size to use in test.h2 (default: 1000)
data(ex_pop) trafo <- function(x){return(x^2)} population <- creating.phenotypic.transform(ex_pop, phenotypic.transform.function=trafo, n.sample = 100)
Run the code above in your browser using DataLab