Skip to content

How to use normal julia variables in Kezdi macro? #222

@jmboehm

Description

@jmboehm

I'd like to do the following

setdf(df)
t1 = 2012
@keep @if fiscalyear == t1

and I get

ERROR: ArgumentError: column name :t1 not found in the data frame

because t1 is not a column in df. The only workaround I've found is to use

@keep @if fiscalyear == Main.t1

Is that the preferred method? If so, it might be a good idea to add that to the documentation (where, if i'm not mistaken, the only discussion of Main. is with functions).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions