What Iím working on is a survey tool. Iím trying to generate a large amount of test data for the reporting end of it. The way we have implemented the survey is to keep it in an XML file. The XML file has the list of questions. Each question can be of type text, date, numeric, single select, or multi-select. Text, date and numeric have a single field to enter. When the type is numeric then an acceptable range of answers is indicated. One response can be selected for the single select and zero or one to all may be selected for the multi-select. (By making a response required.)
Iíve created a script and libraries to read through the XML file and then can answer the questions. As it is structured now it can work on any of the surveys created for the system. However, Iím working on a particular medical survey right now and it is presenting some problems. The issue has to do with the normal range of a response compared with the acceptable range. For example: The acceptable value range for a personís weight is 50 to 400 pounds. In reality, most people fit into a range of, say, 150 to 220. The random generator would spread them evenly across the larger range.
What Iíd like to do is somehow make the data more realistic by having the majority of weights fit into that ďnormalĒ range. It would be great if I could somehow set in a bell curve or something like that. This information isnít in the surveys XML file. Does anyone have a suggestion on how I might accomplish this?
Iím looking for two answers. One is how/where to store the range information and the other has to do with that information what Iím trying to do.