Hi Community,
I have a data set with 4 columns:
ID - Unique identifier
Date: Date of occurrence
Success - 0 / 1 Flag
Weight - The weight of each record
I have to calculate a success percentage, i.e. sum(Success* Weight)/sum(weight). However, I need to calculate the clopper-pearson (exact) confidence intervals for this percentage as well.
It can be done fairly easily using SAS. It would have been easy if it was a 1 time calculation but I want the user to be able to choose a date range and get the percentage and calculate the confidence interval accordingly. Is there a way to do this calculation in Tableau or embed a SAS / R engine which runs whenever a user interacts with the dashboard?
In case you're interested, I use the following SAS code:
PROC SURVEYFREQ DATA= table_name;
WEIGHT weight;
TABLES success / CL(TYPE=CP) ALPHA=0.1;
RUN;
Thanks!
Hello Yogesh,
You should be able to do this with Tableau and R.
Configuring Tableau Server for R and Rserve | Tableau Software
Patrick