Skip to content

Commit

Permalink
Fix issue #102 re vector-valued threshold in summary.scanone()
Browse files Browse the repository at this point in the history
  • Loading branch information
kbroman committed Jul 15, 2023
1 parent ab92398 commit 1acfc04
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 3 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: qtl
Version: 1.60
Date: 2023-04-18
Version: 1.61-1
Date: 2023-07-15
Title: Tools for Analyzing QTL Experiments
Author: Karl W Broman <broman@wisc.edu> and Hao Wu, with
ideas from Gary Churchill and Saunak Sen and contributions from
Expand Down
8 changes: 8 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Revision history for the R/qtl package

## Version 1.61, 2023-07-15

### Bug fixes

- Fixed bug in `summary.scanone()` for the case `format="onepheno"` but
`threshold` has length > 1. (Issue #102.)


## Version 1.60, 2023-04-18

### Minor changes
Expand Down
7 changes: 6 additions & 1 deletion R/summary.scanone.R
Original file line number Diff line number Diff line change
Expand Up @@ -158,8 +158,13 @@ summary.scanone <-
}
thechr <- as.character(object[wh,1])

if(!missing(threshold))
if(!missing(threshold)) {
if(length(threshold) > 1) {
warning('when format="allpheno", threshold should have length 1')
threshold <- threshold[1]
}
wh <- wh[object[wh,lodcolumn] > threshold]
}
else if(!missing(alpha)) {
thr <- summary(perms, alpha)
if("xchr" %in% names(attributes(perms))) {
Expand Down

0 comments on commit 1acfc04

Please sign in to comment.