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

Fix scoping in summarize function #33

Closed
hofnerb opened this issue Jun 29, 2016 · 0 comments
Closed

Fix scoping in summarize function #33

hofnerb opened this issue Jun 29, 2016 · 0 comments
Assignees

Comments

@hofnerb
Copy link
Owner

hofnerb commented Jun 29, 2016

require("nlme")
require("papeR")

data(Orthodont, package = "nlme")

test = function(type) {
    a1 = Orthodont
    print(summary(a1))
    ## Get summary for continuous variables
    (tab1 <- summarize(a1, type = type))
}
test("factor")
##  Error in mySapply(data[, variables], is.factor) : object 'a1' not found 

test("numeric")
##  Error in summarize_numeric(data = a1) : object 'a1' not found 

(spotted by Douglas Ezra Morrison)

@hofnerb hofnerb self-assigned this Jun 29, 2016
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

No branches or pull requests

1 participant