Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
I have a cyclic group - cycling between week and month for some call data.
I want to create a static y-axis, but the max needs to be different based on what cyclic group dimension is currently showing.
Can anyone suggest how I interrogate a cyclic group dimension within an expression?
for example, logically:
If cyclic group selection is 'Weekstart(DATE)' then static max = 100
else if cyclic group selection is 'Monthname(DATE)' then static max = 500
many thanks,
Matt
Please try this.
The value of getCurrentField(GroupName) does not return the label instead it returns the expression used.
Hi,
According to my understanding, Static Min/Max can be set for expressions.If you want it to be difference for different dimensions, you may have to create two charts for two dimensions (one for month and one for week) and apply a conditional show by creating a variable.
Anyway let's wait a moment as there could be an expert idea for your matter.
Thanx
yes it is possible. Please take a look at the example.
You can set the max or min based on if(GetCurrentField(grp)='Week',50,if(GetCurrentField(grp)='Month',100))
Hi Matthew,
Use getselectedfield(groupname) and set the max of axis
Hi Sudeep - this looks like JUST the thing I need.
however, applying it to my example (see attached) it does not seem to work.
any ideas?
I have checked the group name and the dimension labels and everything seems ok...
scratching my head.
Hi,
See the attachment for the solution.
Please try this.
The value of getCurrentField(GroupName) does not return the label instead it returns the expression used.
Hi Matthew,
Problem is in the group your using expression so it not taking the name in the condition.
If you need the name comparison do it at the script level. If not follow the solution provided in the last attachment.
Regards,
@vi
Thank you both for your input.
Works perfectly!!