You should get a slider if you do as below.
Drag Vendor Name to Filters shelf.
Press Top. By Field.
Top, Create parameter (here create a parameter) by Expense Total Amount, Sum
So the trick is to create a parameter inside the Top sheet of the filter menu.
Dropdown on Top N parameter and click edit calculation
you will see the window popping up as shown below
Select Range and type in the max and min field.
If you want to set from the field as you mentioned
create a calculated field and drag and drop it on details in marks card
Dropdown again from parameter --> edit calculation -->set from field --> Count.
Change Min to 1 as shown
Then go to Top N parameter, on dropdown and change to Slider from Type in.
You will get the slider as you wanted.
Hope this helps
Thanks a lot Manoj
I wanted a solution which is dynamic i.e. if the number of unique vendors varies in the data connection, then the range of values within the filter should also change. I removed the observations of a vendor, however the range of values remained static within the filter.
Did you reload the values of the parameter after making changes in the dataset. I guess if you reload them again it might replicate the same range.
Out of the box, Parameters in Tableau are NOT dynamic. There are a couple of different ways you can make a dynamic parameter though.
1) In 2018.2 or later, use an Extension
2) There is a method to use a parameter to call a calculated field that loads the data domain from a column. I don't have a link handy but you should be able to find it if you search.
These might help: