Start your journey with Alteryx Machine Learning - Take our Interactive Lesson today!

Alteryx Machine Learning Discussions

Find answers, ask questions, and share expertise about Alteryx Machine Learning.
Getting Started

Start your learning journey with Alteryx Machine Learning Interactive Lessons

Go to Lessons

Daily forecast spread using quarterly forecast total

smanda
6 - Meteoroid

Has anyone leveraged Alteryx to spread the quarterly forecast counts to daily counts using prior year same quarter actuals as anchor/baseline ?
Is it doable ? I have the methodology but need specifics to transition from excel to alteryx

5 REPLIES 5
Yoshiro_Fujimori
15 - Aurora

Hi @smanda ,

Could you give us a specific example of input data and expected output data, which you are doing on Excel now?

Yoshiro_Fujimori
15 - Aurora

To answer your question "How can I sent my data ?When I attach excel it says format not supported" sent as a private message,

 

You should be able to attach .xlsx file via the "browse" link below.

sample.png

 

It does not need to be the whole data, but we need just enough data to exactly understand what you mean.

If it's not too big, you can simply copy the Excel range and paste it on your post (like below).

 

Input Data

QuarterCount
2023Q1360
2023Q2180
2023Q3540
2023Q4360

Expected Output

DateCount
2024-01-012
2024-01-022
2024-01-032
2024-01-042
2024-01-052
2024-01-062
2024-01-072
smanda
6 - Meteoroid

Thank you
Please see attached.

Yoshiro_Fujimori
15 - Aurora

Hi @smanda ,

Thanks for the data.

 

Looking at the sheet, I have a few comments.

 

[Prior Year Day] column is inconsistent to [Prior Year Date]

Column D has date value "2022/04-04"" while column B has "2023-04-04", which makes the Week of Day wongly displayed.

1256973_cell1.png

 

The corresponding date of This Year is not on the same row as Prior Year.

1256973_cell2.png

 

As Alteryx deals with each row, it is recommended to have the relevant information in the same row (like the sample workflow below).

1256973_Workflow.png

 

If you want to get This Yr Date with the same Day of Week of Prior Yr Date, you may use this function in Formula Tool.

This Yr Date = DateTimeAdd([Prior Yr Date], 52 * 7, "day")

 

Prior Yr DatePrior Year CountsThis Yr DateDay of Week
2023/4/4312024/4/2Tue
2023/4/5542024/4/3Wed
2023/4/6882024/4/4Thu
2023/4/71062024/4/5Fri
2023/4/81362024/4/6Sat

 

You may also want to copy the same values to each row which you use in the calculation.

This Year Counts =

Round([This Year Total forecasted] 

* [Prior Year Counts] 

/ [Prior Year Total Count] 

* [Prior_Yr] 

/ [This_Yr], 1)

 

Output

Prior Yr DatePrior Year CountsThis Yr DateDay of WeekPrior Year Total CountThis Year Total forecastedPrior_YrThis_YrThis Year Counts
2023/4/4312024/4/2Tue110067594.14959422
2023/4/5542024/4/3Wed110067594.14959438
2023/4/6882024/4/4Thu110067594.14959461
2023/4/71062024/4/5Fri110067594.14959474
2023/4/81362024/4/6Sat110067594.14959495

 

Once you cleanse the table thus fur, you may add any rules you want. (I would not dive into more details.)

Good luck.

smanda
6 - Meteoroid

Thank you !
I had the workflow created with formula but unfortunately this does not resolve the  the following that I needed help with: 
1. Match 1st few days of PY and TY regardless of 'Day' of the week until hits1st weekend days
2. Match weekends to weekends
3. Match weekdays to weekdays after #2 and #3 achieved
4. If Prior yr holiday then lookup count for same day in prior week  in the formula