Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

reset logs before adding default_view #472

Merged
merged 1 commit into from
Apr 17, 2017

Conversation

lindsayplatt
Copy link

Addressing error found by @zmoore-usgs when side 2 had negatives, but you were logging side 4. Side 4 was last to be added, so par('ylog') was TRUE when print got to set_frame for the default view and failed because of the negative values on side 2. Fix was to reset pars before adding default_view.

plot2 <- gsplot() %>% 
  points(side=2, 1,-1) %>% 
  points(side=4, 100, 102) %>%
  view(side=4, log='y')
plot2

# this was the error that popped up, but doesn't now
Error in plot.window(xlim = xlim(object, as.x_side(view.name)), ylim = ylim(object,  : 
  Logarithmic axis must have positive limits

@coveralls
Copy link

Coverage Status

Coverage increased (+0.09%) to 80.612% when pulling bc686a5 on lindsaycarr:master into f9cc1bf on USGS-R:master.

@zmoore-usgs
Copy link

Tested the fix in Repgen and it seems to work properly now!

@lindsayplatt lindsayplatt merged commit 8f333f4 into USGS-R:master Apr 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants