I have a following problem: I want to group and build lines from points based on two different groupings. Firstly by category_id that indicates certain categories for the lines (number of categories varies from 1-7). Secondly by "line_number" that indicates consecutive measurements points (see first picture with four point lines). As a result (see second picture first line) or in another words I want lines where category change starts a new line within "line number"-group. Points have order_id so it is can build the lines in particular order. I've tried LineBuilder but can't figure out which aggregations/groupings I should do and in which order.
Â
Â
Â