Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
evadung
Frequent Visitor

Moving average excluding days without data

Hello, 

 

I have this chart with moving average. I dont want to see 4th and 5th day because theres no data (theres more date without data, 4th and 5th is for example). I have no clue what to do.

evadung_1-1676360046697.png

 

Its from calculated measure from two tables:

 

Table1: date, hours1
Table2: date, hours2

(In those tables arent days with null or blank spaces.)

 

calculated measure: Produtivität = hours1/hours2

 

Moving average % =

averagex(
    FILTER(ALLSELECTED(Kalender),
    Kalender[Datum] <= MAX(Kalender[Datum])),
        [Produktivität])
 
1 ACCEPTED SOLUTION
wdx223_Daniel
Super User
Super User

Moving average % =IF( [Produktivität],

averagex(
    FILTER(ALLSELECTED(Kalender),
    Kalender[Datum] <= MAX(Kalender[Datum])),
        [Produktivität]))

View solution in original post

2 REPLIES 2
wdx223_Daniel
Super User
Super User

Moving average % =IF( [Produktivität],

averagex(
    FILTER(ALLSELECTED(Kalender),
    Kalender[Datum] <= MAX(Kalender[Datum])),
        [Produktivität]))

Works! Thank you!

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.