Skip to content

Commit

Permalink
fix x axis group by none
Browse files Browse the repository at this point in the history
  • Loading branch information
vieiralucas committed Jan 22, 2025
1 parent 7cbd41e commit e204c75
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions apps/api/src/python/visualizations-v2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,12 @@ def _briefer_create_visualization(df, options):
# Group by the specified frequency
df[options["xAxis"]["name"]] = df[options["xAxis"]["name"]].dt.to_period(freq).dt.start_time
else:
# just group by values who are the same
df["_grouped"] = df[options["xAxis"]["name"]]
df = df.groupby(grouping_columns).agg({
series["column"]["name"]: "first"
}).reset_index()
elif series["aggregateFunction"]:
y_axis_agg_func = series["aggregateFunction"]
datetime_agg_funcs = set(["count", "mean", "median"])
Expand Down

0 comments on commit e204c75

Please sign in to comment.