Skip to content

Commit

Permalink
v0.41
Browse files Browse the repository at this point in the history
  • Loading branch information
jendelman committed Feb 8, 2024
1 parent ed09201 commit ea2b00b
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: polyBreedR
Title: Genomics-assisted breeding for polyploids (and diploids)
Version: 0.40
Version: 0.41
Author: Jeffrey B. Endelman
Maintainer: Jeffrey Endelman <[email protected]>
Description: Genomics-assisted breeding for polyploids (and diploids)
Expand Down
3 changes: 3 additions & 0 deletions NEWS
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
Changes in 0.41
* Generalized data input for madc

Changes in 0.40
* OFP20 option in madc

Expand Down
11 changes: 9 additions & 2 deletions R/madc.R
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,15 @@

madc <- function(madc.file, marker) {

data <- fread(madc.file,skip=7)
tmp <- as.matrix(data[,17:ncol(data)])
con <- file(madc.file,open="r")
tmp <- readLines(con,n=10)
first.row <- grep("AlleleID",tmp)
ik <- which(strsplit(tmp[1],split=",")[[1]]!="*")
first.col <- min(ik)
close(con)

data <- fread(madc.file,skip=first.row-1)
tmp <- as.matrix(data[,first.col:ncol(data)])
id <- colnames(tmp)
n <- length(id)

Expand Down

0 comments on commit ea2b00b

Please sign in to comment.