turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Find a Community

- Home
- /
- BI
- /
- Visual Analytics
- /
- Compare metric values by day

Topic Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

03-26-2015 06:10 AM

Godd morning all!

I have a VA Report in which I have lots of metrics grouped by Day, Hour and quarter of hour.

I neeed to compare the average of the values grouped by day with values of the previous day and calculate the delta.

I mean...

Let's suppose that metric average for 24/03/2015 is 10, the metric average for 25/03/2015 is 30, I need to show a row in a table in which I have:

DATE: 25/03/2015

VALUE: 30

DELTA: 20 (30 - 10)

%DELTA: 66,67% [100*(30 - 10)/30]

If I could calculate easily VALUE_FOR_YESTERDAY I'll achieve the goal!

I try to use pre-defined functions like Difference for previous period using Date, by I suppose that I can use it only to compare one day with the previous Month...

Can you help me?

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

Posted in reply to ita_sas

03-26-2015 07:40 AM

If you want to calculate with the previoud row.. then it is better to use LAG funtion. or DIF

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

Posted in reply to viveklanka

03-26-2015 08:49 AM

Thank you for your quick answer...

Can you explain me a little more about LAG and DIF functions?

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

Posted in reply to ita_sas

03-26-2015 08:56 AM

LAG function is something which refers to the previous row.

for ex:

Name Age

A 20

B 50

C 40

New= age-lag(age)

this gives you

Name Age New

A 20 .

B 50 30

C 40 10

And DIF is ,you can directly write the function DIF(age) you get the difference.

With Lag you can do any calculation with the previous row. and also with the previous row of any variable with the present row,

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

Posted in reply to viveklanka

03-26-2015 08:59 AM

Thank you very much!!!

Let me try your solution

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

Posted in reply to viveklanka

06-15-2016 04:37 PM

FYI

dif and lag do NOT exist in visual analytics in either the create aggregated measure or create calculated item sections.