Forum Discussion
Automated row for averages in Power Query
Hi there, so my question is that in power query is there a way for me to get a new column that shows the average of values in a row? The number of columns will be updated on a daily basis. So, would need the average column to be updated on a daily basis.
For eg:
We have a table here, say just 4 columns of data as of now and 5th column being average of 4 columns on a row wise representation. What if tomorrow, another column comes in between Jan 4 & average column. I need a way for it to automate this and give me row wise data whenever a new column is added.
This image is just an example from normal excel, but my data is processed in Query, of course can't show the photo since data is sensitive. Once processed within Power query, I have it loaded into a Pivot table. So, it makes crucial for me to have data set in exact same format. what can be done?
1 Reply
- BA_PeteSuper User
Hi bsrujan022 ,
Try this as a new custom column:
List.Average( List.RemoveFirstN( Table.ColumnNames(previousStepName), 1))Pete