Could you post a sample workbook so we can better understand the issue?
Most of this should be able to be solved with parameters.
Parameter 1 should be a list as E1, E2, E2, and then use that to create a calculated field:
"If [Parameter1]="E1" then
If [Period]<=[7/29/2016] and [Period]>=[7/26/2016] then [Period] end
Elseif [Parameter1]="E2" then....
You can also create a DateParameter for "Date Granularity" (Create a list in the Parameter called "Daily", "Monthly", "Quarterly", "Annually), and you'll want to have two calculated fields on this.
The first would be:
"If [DateParam]=[Frequency] then [Period] else null end"
And then I would take that Calculated Field, and create:
"If [DateParam]="Daily" then Day([Period])
elseif [DateParam]="Monthly" then Month([Period])
You'll want to put Calculation 2 on the Rows, and then Measurement in the Rows.
You'll have 2 Parameters the User can change, Date Granularity and Entity Name.
Hope this helps!
I'll be honest to say that you're more likely to get help if you start to make some progress on this and upload a Tableau Packaged Workbook showing that you've made an effort yourself.
You've indicated that you're new to Tableau (welcome to the community!) so I'll point you to some concepts which should help you get started with your expected output:
Thanks Tom & Kathryn. I will work & start a new discussion with the updated doubts.