Skip to content

Commit

Permalink
docs: fix example in window.md (#8611)
Browse files Browse the repository at this point in the history
* Update window.md

I think this fixes although I can't test on my machine to be certain: #8610

Also minor wording updates.

* Update window.md

Removed redundant example

* Update window.md

* Update site/docs/transform/window.md

* style: prettier

Co-authored-by: Dominik Moritz <domoritz@gmail.com>
  • Loading branch information
PBI-David and domoritz committed Dec 19, 2022
1 parent 0dc2a35 commit 6c5d266
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions site/docs/transform/window.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,14 +114,6 @@ Here we use window transform to visualize how the average MPG for vehicles have

<div class="vl-example" data-name="window_cumulative_running_average"></div>

## Additional Examples

These are examples of window transforms that can be simplifies with the join aggregate transform. Please refer to the [join aggregate examples](joinaggregate.html#examples).

### Percent of Total

You can use the window transform to compute an aggregate and attach it to all records. In this case, you can use the [join aggregate](joinaggregate.html) instead of the window transform. Please refer to the [join aggregate examples](joinaggregate.html#examples).

Here we use the window transform to derive the global sum so that we can calculate percentage.

<div class="vl-example" data-name="window_percent_of_total"></div>
The window transform _can_ be used to compute an aggregate and attach it to all records in order to derive a percent of total, however, a simpler approach is to use the [join aggregate](joinaggregate.html) transform instead.

0 comments on commit 6c5d266

Please sign in to comment.