Prepare phenofile

The function magicscan requires two input files: ancestryfile resulting from magicreconstruct (hmmalg = "forwardbackward") and phenofile. The 1st column of phenofile must be a list of offspring IDs that match those in ancestryfile.

The phenofile must be a CSV file with extension ".csv " and with commas as delimiter; no specific requirement on the column names. The columns for the phenotype and explanatory variables can be specified in the keyarg equation.

individual,site, phenotype
ind1, site1, 10.2
ind2, site1, 3.2
ind3, site2, 20.2
...

For the above example phenofile, you may specify equation = @formula(phenotype ~ 1 + site) for julia REPL, or --equation "phenotype ~ 1 + site" for CLI.

see StatsModels.@formula for the syntax. See section Pipeline for an example of running magicscan.