cohorts icon indicating copy to clipboard operation
cohorts copied to clipboard

Allow the plot_boolean column to be a function

Open tavinathanson opened this issue 8 years ago • 1 comments

By adding something like this, albeit less hacky, to plot_boolean:

if type(boolean_col) == FunctionType:
    cols, df = self.as_dataframe([on, boolean_col], **kwargs)
    boolean_col = cols[1]
df = filter_not_null(df, boolean_col)

tavinathanson avatar Jul 09 '16 14:07 tavinathanson

More generally, all columns in cohorts should be specifiable as functions. We can probably centralize that concept and get rid of some code.

tavinathanson avatar Jul 09 '16 14:07 tavinathanson