Forum Discussion
(Yet another) time query
- Anonymous7 years ago
I think I've solved it myself!
I was asking for daily data, and Power BI was trying to average, but by removing day from my query, it is retuening the expected results.
Thanks for your help!
Anonymous
Hi,
If the column is loading as duration and you need to convert it as total seconds then use following:
Transform or Add Column > Duration (Under Date & Time segment) > Total Seconds
It will convert the existing duration column in seconds.
I am not sure about your second requirement because as per my experience, average calculation in Power BI gives accurate results. I would recommend you to calcualte average after performing the steps above.
Rgds,
Vivek
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- Anonymous7 years agoNot applicable
Hi vivran
As the screenshot will show, I have explored the Time functions under transforming columns, and I cannot see find a seconds option:
What I did find though was the 'Duration' button lit, and that gives an option to split out seconds from the duration, and, although it doesn't deal with milliseconds, this may move me further forward.
Thanks for taking the time to reply
Daniel
- vivran227 years agoCommunity Champion
Anonymous
Hi,
Forgot to mention: The option I have suggested is available in Power Query and not in Power BI. You need to open the table in the Edit Query mode to access the feature.
Rgds,
Vivek
- Anonymous7 years agoNot applicable
Thanks Vivran
So the Duration button has given me the seconds I need, however, I'm now trying to replicate the Average Time on Page and Bounce Rate metrics from Google Analytics.
When I put my measures in a table I see the following:
However , the totals are different (in some cases as much as 5%) from those that Google Analytics are reporting.
As you can see from the table, I've tried weighting the average to minimise the difference, however it is still enough to render the table completely innaccurate to it's audience.
Is there a calculation method I'm missing to get this closer to the mark?
Daniel