Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!View all the Fabric Data Days sessions on demand. View schedule
Hello Friends,
I am working on a dataset for my project and need to create a moving average. Below is the sample dataset that i am using. Can you suggest me the DAX command for the same.
| Company | Date | Close |
| Caplin Labs | 01-04-2016 | 215.89 |
| Caplin Labs | 04-04-2016 | 221.09 |
| Caplin Labs | 05-04-2016 | 215.26 |
| Caplin Labs | 06-04-2016 | 212.05 |
| Caplin Labs | 07-04-2016 | 213.60 |
| Caplin Labs | 08-04-2016 | 212.38 |
| Caplin Labs | 11-04-2016 | 211.19 |
| Caplin Labs | 12-04-2016 | 213.01 |
| Caplin Labs | 13-04-2016 | 212.19 |
| Caplin Labs | 18-04-2016 | 211.13 |
| Caplin Labs | 20-04-2016 | 207.77 |
| Caplin Labs | 21-04-2016 | 206.42 |
| Caplin Labs | 22-04-2016 | 203.23 |
| Caplin Labs | 25-04-2016 | 199.75 |
| Caplin Labs | 26-04-2016 | 199.56 |
| Caplin Labs | 27-04-2016 | 198.96 |
| Caplin Labs | 28-04-2016 | 195.75 |
| Caplin Labs | 29-04-2016 | 194.25 |
| Caplin Labs | 02-05-2016 | 196.55 |
@Abhijith_KG , based on what I got
New column = averageX(filter(Table, [Date] = earlier([Date])),[Close])
or
New measure = averageX(filter(allselected(Table), Table[Date] = max(Table[Date])),[Close])
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 14 | |
| 11 | |
| 9 | |
| 5 | |
| 4 |
| User | Count |
|---|---|
| 28 | |
| 20 | |
| 19 | |
| 18 | |
| 12 |