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

Expression Set Analysis

Hi at all,

I have a dataset with one field called data and another one called unit price

I would like to create a formula that shows me the first available unit price for a specific product, i have created a variable called MinData with this formula =Min(data)

And then i wanted to try this one

Avg({<data = $(=MinData)>}Unit_Price)

But it doesn't work, anyone can help me with this..

Best regards

Andrea

1 Solution

Accepted Solutions
krishnacbe
Partner - Specialist III
Partner - Specialist III

MinData variable settings I have added expression as =Date(Min(data))

avg({<data={"$(MinData)"}>}Unit_Price)

Hope it works

View solution in original post

11 Replies
Anil_Babu_Samineni

May be flower bracket missed as syntax of set expression

Avg({<data = {$(=MinData)}>}Unit_Price)

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
andrea90casa
Creator
Creator
Author

Hi Anil

I tried with curly brakets in that position but it hasn't worked too

krishnacbe
Partner - Specialist III
Partner - Specialist III

Try below expression

Avg({<data = {"=$(=MinData)"}>}Unit_Price)

or

Avg({<data = {"=$(MinData)"}>}Unit_Price)

Anil_Babu_Samineni

Try this

Avg({<data = {'$(MinData)}>}Unit_Price)'

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
andrea90casa
Creator
Creator
Author

with this solutions it calcs the average considering all the unite price and it doesn't give to me the only first one

krishnacbe
Partner - Specialist III
Partner - Specialist III

Can you share some sample data to debug.

andrea90casa
Creator
Creator
Author

This one for example.

In the first text box i would like to see the first price, for example for the product A. So the correct value should be 1,1

Andrea

krishnacbe
Partner - Specialist III
Partner - Specialist III

Check below expression

=aggr(avg(Unit_Price),Product)

andrea90casa
Creator
Creator
Author

With that expression the result is 1.188 so the mean of all that value, so it is not give to me the min data unit price (01/01/2017 = 1,1)