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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
mhasler
Frequent Visitor

Cortar una media móvil

Esto fue una gran ayuda y funciona, pero la medida no segmenta con el otro valor en la misma visualización que corta - por estado.
https://community.powerbi.com/t5/Desktop/Moving-Average/m-p/1097929

No creo haber hecho una medida antes de que no se corte por cualquier campo del conjunto de datos que haya configurado una segmentación de datos.

En el lado positivo de estos datos está disponible públicamente en el sitio covidTrackingProject: https://covidtracking.com/data/api

Esta es la medida - funciona pero no se corta por estado:

Laminado positivo AVG - 7 días ?
CALCULAR (
SUM (StatesDaily[positiveIncrease]) / 7,
DATESINPERIOD (
StatesDaily[DateText],
LASTDATE ( StatesDaily[DateText] ),
-7,
Día
),
FILTRO (
TODO (StatesDaily ),
MAX ( StatesDaily[DateText] ) < HOY ()
)
)
Todos los estados (sin corte)
mhasler_0-1594153431690.png

Cortado a un estado - tenga en cuenta que el promedio en movimiento permanece igual y las otras rebanadas de medida correctamente

mhasler_1-1594153521252.png

2 REPLIES 2
parry2k
Super User
Super User

@mhasler cambiar TODO a ALLSELECTED

Me gustaría elogiossi mi solución ayudara.👉Si puedes pasar tiempo publicando la pregunta, también puedes hacer esfuerzos para dar a Kudos quien haya ayudado a resolver tu problema. ¡Es una muestra de agradecimiento!

Visítenos enhttps://perytus.com, su ventanilla única para proyectos/formación/consulta relacionados con Power BI.



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

en el proceso de probar ALLSELECTED en lugar de ALL, terminé necesitando simplemente eliminar el filtro para comenzar limpio.

Me di cuenta de que lo hizo cortar correctamente y no necesitaba el filtro de fecha en primer lugar, ya que los datos no tienen ninguna fecha futura para filtrar como el ejemplo del que vino.

Ahora obtengo una medida adecuada cuando se corta / sin cortar!

¡Gracias!

mhasler_0-1594222281349.png

Helpful resources

Announcements
Feb2025 Sticker Challenge

Join our Community Sticker Challenge 2025

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

Jan NL Carousel

Fabric Community Update - January 2025

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

Top Solution Authors