New Wednesday, new Just KNIME It! challenge!
This week, our tenth challenge of this season focuses on Restaurant Yummy and how well it is doing in terms of sales . It’s an ETL problem and we’re excited to see your creative solutions to it!
Here is the challenge. Let’s use this thread to post our solutions to it, which should be uploaded to your public KNIME Hub spaces with tag JKISeason2-10.
Need help with tags? To add tag JKISeason2-10 to your workflow, go to the description panel on the right in KNIME Analytics Platform, click the pencil to edit it, and you will see the option for adding tags right there. Let us know if you have any problems!
Hi @alinebessa thanks for sharing the challenge I just had a look at the data and wanted to check that its correct that it only contains 1 and a half months of the year?
My solution this week converts the Date column from String to Date format and uses the -Moving Aggregation- node to calculate the Cumulative Sum for the YTD Sales. For the MTD sales, I have performed the same moving aggregation but this time after having extracted the month, I have cycled through each month using a -Group Loop-:
You can find my solution on the hub here:
here’s my solution, two loops and two moving aggregations:
See you to the next.
here is my solution:
It works even if you upload multiple years, because YTD and MTD calculations are made on two loops.
Have a nice evening,
Here is my solution.
find my take on the challenge 10 …initially presumed a static number …plotted on line .
Yes, Heather, this is the right dataset!
Hello everyone, this is my solution.
Greetings, esteemed participants,
As the author of this Challenge, I am delighted to witness a plethora of submissions on the very first day. I extend my heartfelt appreciation for the correctness and quality displayed in all of the solutions. Well done!
In order to stimulate your intellectual prowess even further (if I may indulge), I have managed to solve this Challenge without the use of loop nodes. I kindly invite you all to explore the possibility of solving it through alternative means, avoiding the usage of loop nodes.
I eagerly await to see your solutions…
Hi crazy KNIMErs, How’s that going?
I see you are very active today…
I can’t say much today, I just wanted to make something different although I know it is not the best option.
See you at the next battle!
here is my solution.
Nice to hear that you like our solutions
I’ve attempted your challenge and I think I’ve done it!
I started off the same way, calculating the YTD sales with the -Moving Aggregation- node. I extracted the month as a number, grouped by the month and took the last YTD value for each month. I guess I could have just done a sum of the sales to achieve the same result.
I then used a second -Moving Aggregation- node to perform a negative lag on the numerical month column, meaning that the month is now associated with the total value from the previous month.
I then joined these total values to the original table and subtracted them from the YTD column to calculate the MTD sales.
I made some extended sales data by expanding the date column in Excel and then generating random numbers in KNIME. I wanted to check the workflow could be applied to more than 2 months in the year
You can find my workflow in the hub here:
This is exactly what my solution looks like, amazing job! @HeatherPikairos
Oh that’s great to hear! Thank you
This is a very nice solution @MoLa_Data but I see a limitation here, you will have to add Moving Aggregation nodes whenever we have a new month in the data, eg: right now you have 2 nodes for Jan, feb and will need to add 10 more moving average nodes once we have data for March-Dec, Can you think of making this solution dynamic (works with any number of months)?
Oh yes, I know it’s not the best option, in fact, at the bottom of the workflow, I explain that. My colleagues already shared the best option, and I just wanted to share something different.
Thanks for comments @Mpattadkal I really appreciate your opinion.
Here is my solution. I tried the challenge without loop nodes, but it could be wrong. I managed to make it by using pivoting node.Thanks
A very good solution to successfully implement functionality without using loops. Thank you for sharing, I have also learned.