0

I want to use GenABEL for GWAS in a diploid plant species, but GenABEL stuck on as it requires a "sex" column in pheno file. It should be filled with "1" for male or "0" for female. But I am working with a plant species. What should I do?

Error in R:

impute <- load.gwaa.data(phe="traits.dat", gen="gen0tped.raw", force=TRUE)

Error in if (length(a) == 1 && !(names(a)[1] == 0 || names(a)[1] == 1)) stop("the column named \"sex\" contains 1 code which is neither 0 (=female) or 1 (=male)") : missing value where TRUE/FALSE needed

zx8754
  • 52,746
  • 12
  • 114
  • 209

1 Answers1

0

From the details section of ?load.gwaa.data:

The first column of the phenotype file MUST contain the subjects' unique ID, named "id"; there should also be a column named "sex" and giving sex information (0 = female, 1 = male). Other columns in the file should contain phenotypic information. Missing values should be coded with "NA"

So try including a sex column with every value as NA.

Also, contact the maintainer (packageDescription("GenABEL", fields = c("Maintainer", "BugReports"))) to explain that GWASs can be done on things where gender isn't relevant.

Richie Cotton
  • 118,240
  • 47
  • 247
  • 360
  • Thanks for a nice reply....I've checked group queries and found a solution. I am working on it and trying to do an association analysis using genabel its taking time as m not handy on r. – Vinod Kumar May 13 '15 at 10:18