6 Replies Latest reply on Feb 13, 2019 9:35 AM by Shane Fife

# Make Table Calculations Empty for future

Dear Tableau Community,

I'm trying to get blank out all fields if the year has yet to come. (E.g., There won't be Fifth Year retention stats for the Fall 2017 cohort for quite some time).

Most of it is controlled for, but for every other year after it'll show up.

It must remain Table Down.

I've tried as much as I could. I think it might be the order of the formula. See below.

I've also attached the packaged workbook.

Thanks!

Formula for Graduate %, the remaining measure that shows up when it should be blank.

IF

RUNNING_SUM(

WINDOW_MAX(COUNTD([IR]))=PREVIOUS_VALUE(1) THEN NULL

ELSEIF

RUNNING_SUM(

WINDOW_MAX(COUNTD([IR]))=0 THEN NULL

ELSEIF PREVIOUS_VALUE(1) = NULL THEN NULL

ELSEIF LOOKUP(RUNNING_SUM(

WINDOW_MAX(COUNTD([IR])),-1) = NULL

THEN NULL

ELSE

RUNNING_SUM(

WINDOW_MAX(COUNTD([IR]))

END

• ###### 1. Re: Make Table Calculations Empty for future

I'm looking at this.  Are you trying to get, for example, the 69% in the 8th year for Fall 2008 not to display? Or the 63% in 7th year of Fall 2010?

How does it happen that there is a Total Number Enrolled in the 8th year of Fall 2009 when there was nothing in the 7th year?  Is that legitimate?

I'm trying to determine a condition that guarantees when something should be null without having to reverse engineering all the table calcs in your sheet.  At a visual glance it might be that those table calcs should be null when there is no value for Total Number Enrolled.

• ###### 2. Re: Make Table Calculations Empty for future

Hey Joe,

For your first question, it would be both.

I need to explain further. You are correct in that the 8th year has passed for Fall 2008 cohort, but we wanna leave it blank since they're were no changes the prior year.

For your second question, a student can come back and enroll if they did not attend the previous year. It's few and far between, but we can detect it on this dashboard.

Hopefully that helps!

Shane

• ###### 3. Re: Make Table Calculations Empty for future

So am I correct in what I said at the end of my first post?  " At a visual glance it might be that those table calcs should be null when there is no value for Total Number Enrolled."

• ###### 4. Re: Make Table Calculations Empty for future

Yes.

• ###### 5. Re: Make Table Calculations Empty for future

IF

not ISNULL([Total Number Enrolled]) then

RUNNING_SUM(

WINDOW_MAX(COUNTD([IR]))

END

It fixed all those spurious values.  But it also eliminated  all the places where the value showed up as 0% (such as all the ones in "First Year".)  It's far simpler than all the conditions and previous_values and all that you had originally.

• ###### 6. Re: Make Table Calculations Empty for future

Wow! Thanks so much for your time and help Joe!

I made it too complicated lol.