Skip to content

Commit

Permalink
Fix bar color bug when subsetting
Browse files Browse the repository at this point in the history
Pass subsetted bar.color to the histogram.
  • Loading branch information
erichung0404 committed Aug 13, 2016
1 parent b68c0ea commit b93bbb5
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions R/addVo.R
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@
log.scale <- ifelse(x$Env$log.scale,"y","")

bar.col <- if(color.vol) {
theme$bar.col
} else theme$border.col
theme$bar.col[xsubset]
} else theme$border.col[xsubset]

border.col <- theme$border.col
border.col <- theme$border.col[xsubset]
min.vol <- min(vo)

if(x$Env$theme$thin) {
Expand Down Expand Up @@ -105,8 +105,6 @@
border.col <- ifelse(rep(is.null(lchob$Env$theme$border),NROW(xdata[,1])),
bar.col,lchob$Env$theme$border)

bar.col <- bar.col[lchob$Env$xsubset]

lchob$Env$theme$border.col <- border.col
lchob$Env$theme$bar.col <- bar.col

Expand Down

0 comments on commit b93bbb5

Please sign in to comment.