I'm creating a script that creates an Overlay Plot with one variable (price) on the x-axis and two variables on the y-axis. My script works fine, but now I want to create a dialog box in which a user could select which two variables to plot on the y-axis. There are set combinations, so I would like to use a Radio Box with the acceptable pairs listed. But unfortunately I can't tell the Overlay command which variables to use. The relevant portion of my code is:
| | Outline Box("Select Curves to Analyze",rb = Radio Box( {"Optimal Price Point", |
| | "Indifference Price Point", |
| | "Point of Marginal Cheapness", |
| | "Point of Marginal Expensiveness" |
| | } |
| ), | |
| | Outline Box("van Westendorf Graph", |
| | op = Data Table( "vw3" ) << Overlay Plot( |
| | X( :Price ), |
| | choose( rb << Get(), Y( :Expensive, :Bargain ), Y( :Too Expensive, :Cheap ) ), |
I though I'd use the choose function to return the relevant Y statement. But this doesn't work. Any suggestions?
Thanks,
Walt