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

spelling error in one of the examples #56

Closed
konkam opened this issue Jun 7, 2016 · 0 comments
Closed

spelling error in one of the examples #56

konkam opened this issue Jun 7, 2016 · 0 comments

Comments

@konkam
Copy link

konkam commented Jun 7, 2016

Hello,

some of the examples give an error on julia 0.4.5

The following code

using DataArrays, DataFrames
using DataFramesMeta

df = DataFrame(x = 1:3, y = [2, 1, 2])

transform(df, newCol = cos(df[:x]), anotherCol = df[:x]^2 + 3*df[:x] + 4)
@transform(df, newCol = cos(:x), anotherCol = :x^2 + 3*:x + 4)

produces

ERROR: MethodError: * has no method matching *(::Array{Int64,1}, ::Array{Int64,1})

replacing ^ by .^ fixes the problem, ie:

transform(df, newCol = cos(df[:x]), anotherCol = df[:x].^2 + 3*df[:x] + 4)
@transform(df, newCol = cos(:x), anotherCol = :x.^2 + 3*:x + 4)

Best regards,

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

2 participants