Rolling average with working days in DAX

  Рет қаралды 13,618

SQLBI

SQLBI

Күн бұрын

This article shows how to compute a rolling average (useful to smooth out charts) taking into account only the working days.
Article and download: sql.bi/757611?...
How to learn DAX: www.sqlbi.com/...
The definitive guide to DAX: www.sqlbi.com/...

Пікірлер: 30
@Tom-kp2lv
@Tom-kp2lv 2 ай бұрын
Thanks!! So, import and a calc col is and available option in my scenario. Is the "add columns"/measure version slower or faster than using a calculated column?
@mnowako
@mnowako 2 жыл бұрын
That’s a very interesting business case. Both examples are great and the explanation is second to none. Thank you and please make more such examples. 👏
@readistreet9383
@readistreet9383 Жыл бұрын
Hi, great video as allways, it would help me a lot. Just one thing, the first values of the moving average are not correct, till it reach the 30 days of data. for example, in the first day youre dividing the first value by 30 wich is not correct. Maybe a better way is to use in the VAR NumberOfDays the actual number of days in the range min/max workingday instead of just 30
@matthewdufty606
@matthewdufty606 Жыл бұрын
The KZbin algorithm literally read my mind. I wanted to look at rolling averages this morning and this popped up in my feed. How bizarre!
@PJJACOB360
@PJJACOB360 Жыл бұрын
You are the best
@matthiask4602
@matthiask4602 2 жыл бұрын
Alberto, thank you so much for videos like this. You are the best teacher of data analytics (esp. DAX of course) I ever experienced.
@graemegourlay2850
@graemegourlay2850 8 ай бұрын
Exactly what I needed to do for a piece of analysis. I would never have figured this out myself. Big thank you for this tutorial.
@FitofnietOfficial
@FitofnietOfficial 2 жыл бұрын
Thanks for the great content. I was wondering why did you add the less "
@naylord5
@naylord5 2 жыл бұрын
This video is excellent master! Thank you for sharing your knowledge and experience with the community. Can I ask you a question? I have a statement with a list of payments, each movement is associated to a document number, the problem is that the payments can be cancelled N amount of times and reapplied, either to the same doc or to another one. I would like to use Power Query to keep only the last odd (non) occurrence of the payments, but if the number of payments is even, discard them all. That is, if doc 1 had 1 payment, 1 cancellation and 1 payment again, only keep the third transaction, but if doc 2 had a payment and it was cancelled, but it was not paid again, discard all the payments of doc 2. Do you think you could help me? Thanks in advance for your time.
@MS-im2zy
@MS-im2zy 2 жыл бұрын
Thank you! Doing this in a measure is exactly what I have been working on...and was stuck
@kesavaraju9652
@kesavaraju9652 2 жыл бұрын
In live connection also we can create a calculated column, By simply allowing a local model. But You showed an excellent way instead.
@Anthony_Lecoq
@Anthony_Lecoq 2 жыл бұрын
Crazy amazing good job Alberto as always. I love when you demonstrate how to solve an issue when starting from scratch. 👍
@datasapien
@datasapien 2 жыл бұрын
Amazing content Alberto! , the live calculated column part was pure wizardy.
@brizotfrizot
@brizotfrizot 10 ай бұрын
What is the relationship between your date table and sales table?
@justFast1k
@justFast1k 2 жыл бұрын
Amazing! As usual Thank you, Alberto!
@Bharath_PBI
@Bharath_PBI 2 жыл бұрын
That's best as always! You mentioned IF() should be avoided in calculated column as best practice (optimization), do you have any article on this or any reference link?
@SQLBI
@SQLBI 2 жыл бұрын
www.sqlbi.com/articles/calculated-columns-and-measures-in-dax/
@AgulloBernat
@AgulloBernat 2 жыл бұрын
I love these vídeos!! Keep them coming!
@PeterKontogeorgis
@PeterKontogeorgis 2 жыл бұрын
You always make things look so easy! Looking forward to your training in Melbourne in October!
@SQLBI
@SQLBI 2 жыл бұрын
Thank you Peter! Just one note: Marco will be teaching in Melbourne this year, not Alberto.
@irfandaud7380
@irfandaud7380 2 жыл бұрын
DAX needs to be organized and should be in sequence ... Now i know why people say DAX is difficult
@andreikilla
@andreikilla Жыл бұрын
What if you have multiple products in same table
@SQLBI
@SQLBI Жыл бұрын
Use the product name as a grouping condition so you merge them.
@firdosesyed8981
@firdosesyed8981 2 жыл бұрын
Hlo sir I'm a beginner how much time it takes to learn the advanced level if SQL
@sbn4862
@sbn4862 2 жыл бұрын
To learn DAX one must training every day, it's single way! What if we accept one filter in Calculate as WorkingDay="True"?
@SQLBI
@SQLBI 2 жыл бұрын
The issue is how to count the number of working days so that they are always the same number in each interval. This is the purpose of the calculation made in the video.
@frankgovers8420
@frankgovers8420 2 жыл бұрын
Should the not function have brackets?
@AgulloBernat
@AgulloBernat 2 жыл бұрын
Question: the removefilters on date you add on 23:28 was not necessary in the calculated column version of the code?
@SQLBI
@SQLBI 2 жыл бұрын
Not necessary there.
Understanding context transition
18:25
SQLBI
Рет қаралды 69 М.
How to create a ROLLING AVERAGE in Power BI by Using DAX [2021]
29:43
Nestor Adrianzen
Рет қаралды 10 М.
Офицер, я всё объясню
01:00
История одного вокалиста
Рет қаралды 4,4 МЛН
Man Mocks Wife's Exercise Routine, Faces Embarrassment at Work #shorts
00:32
Fabiosa Best Lifehacks
Рет қаралды 6 МЛН
А ВЫ ЛЮБИТЕ ШКОЛУ?? #shorts
00:20
Паша Осадчий
Рет қаралды 9 МЛН
Computing rolling average in DAX
16:43
SQLBI
Рет қаралды 73 М.
Propagating filters using TREATAS in DAX
19:18
SQLBI
Рет қаралды 45 М.
Optimizing SUMMARIZE by using ADDCOLUMNS - Unplugged #40
14:31
Row Context in DAX
20:42
SQLBI
Рет қаралды 99 М.
Calculate a Rolling Average in Power BI Using DAX
11:00
Essential Excel
Рет қаралды 56 М.
When to use KEEPFILTERS over iterators
18:56
SQLBI
Рет қаралды 48 М.
Using RELATED and RELATEDTABLE in DAX
18:04
SQLBI
Рет қаралды 40 М.
Офицер, я всё объясню
01:00
История одного вокалиста
Рет қаралды 4,4 МЛН