Merge pull request #4719 from solgenomics/topic/fixing_histogram
[sgn.git] / R / solGS / combine_gebvs_files.r
blobac531a0ac9b6e7bcc9416b1730b5aa906f77f79a
1 #combines gebvs of traits of a population
2 # Isaak Y Tecle
4 library(phenoAnalysis)
6 options(echo = FALSE)
8 allArgs <- commandArgs()
9 inFile <- grep("gebv_files", allArgs, value = TRUE)
10 outputFile <- grep("combined_gebvs", allArgs, value = TRUE)
11 inputFiles <- scan(inFile, what = "character")
13 combinedGebvs <- mergeVariables(inputFiles)
15 if (length(outputFile) != 0 ) {
16 write.table(combinedGebvs,
17 file = outputFile,
18 sep = "\t",
19 quote = FALSE,
20 col.names = NA,
24 q(save = "no", runLast = FALSE)