<%BANNER%>

MDC: A Mobile Data Collection System for Pocket Pc


PAGE 1

MDC: A MOBILE DATA COLLECTION SYSTEM FOR POCKET PC By MANISH MALIK A THESIS PRESENTED TO THE GRADUATE SCHOOL OF THE UNIVERSITY OF FLORIDA IN PARTIAL FULFILLMENT OF THE REQUIREMENTS FOR THE DEGREE OF MASTER OF SCIENCE UNIVERSITY OF FLORIDA 2002

PAGE 2

Copyright 2002 by Manish Malik

PAGE 3

To my family, for all the love, support and encouragement.

PAGE 4

ACKNOWLEDGMENTS I would like to thank my advisor, Dr. Douglas Dankel, for giving me an opportunity to work under him. He has been very supportive and helpful and this thesis would not be possible without his supervision and encouragement. I would also like to thank Dr. Joachim Hammer and Dr. Chris Sistrom for serving on my thesis committee. Finally, I thank God and my family for always being there for me. iv

PAGE 5

TABLE OF CONTENTS page ACKNOWLEDGMENTS.................................................................................................iv LIST OF TABLES............................................................................................................vii LIST OF FIGURES.........................................................................................................viii ABSTRACT.......................................................................................................................ix CHAPTER 1 INTRODUCTION...........................................................................................................1 2 SURVEY OF THE EXISTING QUESTIONNAIRE SYSTEMS...................................4 The Survey System.........................................................................................................4 Questionnaire Design Software......................................................................................5 eSurvey...........................................................................................................................6 Tripod Data Systems Survey Pro for Pocket PC (TDS).................................................7 PalmQues........................................................................................................................8 Professional Quest..........................................................................................................9 SurveyMate.....................................................................................................................9 ScreenSurvey................................................................................................................10 Chapter Summary.........................................................................................................11 3 FEATURES AND DESIGN OF MDC..........................................................................12 Paper-based Method of Data Collection....................................................................... 12 Mobile Data Collection System for Pocket PC.............................................................14 Questions and Their Types....................................................................................17 Creation / Editing of the Questionnaire ................................................................. 18 Questionnaire Layout.............................................................................................19 Dynamic Questionnaire System.............................................................................20 Design Issues................................................................................................................21 Platform..................................................................................................................21 Connecting to the Database....................................................................................22 Data Entry..............................................................................................................23 Chapter Summary.........................................................................................................24 v

PAGE 6

4 MDC PROXY................................................................................................................25 Info Packet....................................................................................................................26 Next Packet...................................................................................................................28 Back Packet...................................................................................................................29 Finish Packet.................................................................................................................30 Chapter Summary.........................................................................................................30 5 MDC SERVER..............................................................................................................32 MDC server Components.............................................................................................32 Database.................................................................................................................33 GetInformation.......................................................................................................35 AddResults.............................................................................................................36 Chapter Summary.........................................................................................................38 6 MDC CLIENT...............................................................................................................39 MainForm.....................................................................................................................39 Question1Form.............................................................................................................41 Question2Form.............................................................................................................43 FinishForm....................................................................................................................44 SendRec........................................................................................................................45 Chapter Summary.........................................................................................................45 7 CONCLUSION AND FUTURE WORK......................................................................46 LIST OF REFERENCES...................................................................................................49 BIOGRAPHICAL SKETCH.............................................................................................51 vi

PAGE 7

LIST OF TABLES Table page 2.1 Comparison of properties of data collection systems...................................................4 4.1 Different Types of Packets from the MDC client.......................................................25 4.2 Response packet sent to the MDC client....................................................................28 vii

PAGE 8

LIST OF FIGURES Figure page 3.1 Data Flow in Paper based Questionnaires..................................................................13 3.2 Data Flow in the MDC................................................................................................14 3.3 Demographic Information Screen...............................................................................15 3.4 Sample Question within the Questionnaire.................................................................16 3.5 Finish Screen...............................................................................................................17 3.6 Mobile Questionnaire component data flow...............................................................18 3.7 General Questions Table.............................................................................................19 3.8 Critical Question.........................................................................................................21 3.9 After triggering the Critical Question.........................................................................22 3.10 Without triggering the Critical Question..................................................................23 4.1 HTML Page with the Questions Details passed to the Proxy by the MDC server....27 5.1 MDC server component data flow..............................................................................34 5.2 GetInformation HTML Page.......................................................................................36 5.3 AddResults HTML Page.............................................................................................37 6.1 MainForm...................................................................................................................40 6.2 Pop up Message..........................................................................................................41 6.3 Question1Form...........................................................................................................42 6.4 Question2Form...........................................................................................................43 6.5 FinishForm..................................................................................................................45 viii

PAGE 9

Abstract of Thesis Presented to the Graduate School of the University of Florida in Partial Fulfillment of the Requirements for the Degree of Master of Science MDC: A MOBILE DATA COLLECTION SYSTEM FOR POCKET PC By Manish Malik December 2002 Chair: Dr. Douglas D. Dankel II Major Department: Computer and Information Science and Engineering The traditional method of collecting questionnaire data uses a paper form completed by each respondent. Collecting data in this manner is very inefficient because the layout of the questions on the paper based questionnaires is often quite complex for the respondent to understand, and the collected dataset has to be manually entered into a database, which potentially results in time delays and data entry errors. This method of data collection is very static in which every respondent receives an identical form and has to answer the applicable questions and skip the non-relevant questions. In domains having complex, multi-path sets of questions (e.g., medicine) it is virtually impossible to construct a paper-based questionnaire in which a respondent is asked only relevant questions. Although a paper-based questionnaire has proven to be an economical solution in the medical waiting rooms, it is often confusing for the respondent. To date, there has been no cost-effective electronic questionnaire system available that can completely automate this process. Although several methods for data entry have been proposed in the ix

PAGE 10

past, none has come close enough to completely automate this process in the questionnaire systems. The requirements of a system that can replace a paper-based questionnaire are as follows: provide a method to create/edit the questions, eliminate the need to manually enter the data into the database, provide an intelligent way of asking questions (i.e., asking only relevant questions), and provide a cost-effective solution that can be easily deployed. This thesis presents such a solution: the Mobile Data Collection System for Pocket PC. x

PAGE 11

CHAPTER 1 INTRODUCTION A paper-based questionnaire is a traditional method for data collection. This method is not only time consuming but also a very inefficient way of data collection. Although electronic questionnaires have replaced paper-based questionnaires in many areas, this method is still used in medical waiting rooms since no existing system has been able to completely automate the process of data collection for this setting. To understand the requirements of a system that could replace the paper-based method in medical waiting rooms, we need to know the complete process of data collection in a medical waiting room and its shortcomings. A doctor or questionnaire creator creates questions to be answered by the respondent. These questions are then organized, arranged, and structured prior to being printed on paper. The receptionist gives these printed-paper questionnaires to the respondents, who complete and return them to the receptionist. To utilize this collected data, they must be entered into an existing database. This paper-based method of data collection is a costeffective solution for medical waiting rooms but it has some shortcomings. Paper-based questionnaires are static, i.e., all potential questions to be answered must appear regardless of how many will actually be completed. The editing of these paper-based questionnaires is very time consuming and requires the whole process of questionnaire creation to be repeated. If the questionnaire contains some questions that are specific to some group of respondents, then the layout of the questionnaire can become very complex for the respondents. For 1

PAGE 12

2 example, if some questions are specific to male respondents, then female respondents will not answer these questions and will have to skip these questions and go to some other part of the questionnaire. This often is not very intuitive for the respondents and leads to confusion. Once the questionnaires are completed, to utilize the collected data, they need to be manually entered into an existing database. Manual data entry is error prone and adds to the inefficiency of the system in terms of time delays and typographical errors. The requirements of a system that could replace the paper based method include the following: provide a simple way to create/edit the questionnaire, provide an intuitive layout to the respondents, eliminate the errors/delays that occur due to data entry of the collected data, provide a dynamic way of asking questions from the respondents and a cost-effective solution that can be deployed in the medical waiting rooms. The Mobile Data Collection System for Pocket PC (MDC) has been developed to meet all the requirements stated above. MDC provides a very simple structure for creating/editing the questionnaire. The questionnaire creation time is almost the same as in paper-based questionnaire, but editing the questionnaire is very simple and takes less time. The questions database for the questionnaire resides on the desktop computer. The questions are entered into different tables of this database by the physician. A subset of these questions, based upon the demographic information of the respondent, is then one by one wirelessly downloaded from this database. The questions are displayed on the Pocket PC one-at-a-time. In this way, MDC avoids confusion and is very intuitive for the respondents. MDC has wireless database connectivity, so the dataset is entered into the database as soon as it is collected, thus eliminating the errors and delays caused by manual data entry. MDC

PAGE 13

3 uses the answer to a question to decide which of the subsequent questions should be answered by the respondents, so it provides a way to ask only relevant questions, resulting in a very efficient data collection system. MDC runs on a Pocket PC making it a cost-effective solution that can be deployed in medical waiting rooms with minimal infrastructure required. MDC consists of three components: the MDC client, the MDC proxy, and the MDC server. These components interact with each other to perform all of the tasks. This thesis discusses each of these components in detail. Chapter 2 is a survey of the existing questionnaire systems and Chapter 3 describes the design and features of MDC. The next three chapters discuss in detail each component. Chapter 4 is the description of MDC proxy, Chapter 5 is the description of MDC server, and Chapter 6 is the description of MDC client. Finally, Chapter 7 gives conclusions and lists future research needed in this area.

PAGE 14

CHAPTER 2 SURVEY OF THE EXISTING QUESTIONNAIRE SYSTEMS Many electronic questionnaire systems have been designed to replace the paper-based questionnaires. Table 2-1 gives a comparison of the properties of paper-based and the proposed system of data collection. Table 2.1 Comparison of properties of data collection systems Method of Data Collection Way to Create/Edit the Questionnaire Layout Data Entry Type Cost Effectiveness Paper Based No Confusing Manual Static Yes Proposed System Yes Intuitive Automatic Dynamic Yes Any system that has all the properties of the proposed system could replace the paper-based system in medical waiting rooms. This chapter discusses the features of the various questionnaire systems and compares their properties with the proposed system. The Survey System Designed by Creative Research Systems, Survey System is a software package available for working with questionnaires. The Survey System was designed specifically for questionnaires and handles the creation of a questionnaire through data entry, web services, table generation, and text reports. Survey System provides a way to edit the data, spell check the data, calculate complex statistics, and produce quality tables. It offers a number of optional modules: Internet Module, Voice Capture Module, and Statistics Module. These modules enable you to customize this software package to fit the questionnaire needs. Survey System offers two types of online questionnaires: using a 1 4

PAGE 15

5 Web page or email. When using Web page surveys, the questionnaire is posted on a Web page. People then visit the page and answer your questions. When using e-mail surveys you send a questionnaire to a list of respondents and then they reply with their answers. This system works on either a Windows based PC or a Macintosh. The Survey System succeeds in meeting two of the requirements of a system that can be used in the medical waiting rooms. It provides a way to create your own questionnaire and eliminates the need for manual data entry into the database. The shortcoming of the Survey System is that it needs another system to extract the data from the exported files and to enter it into the database. Another system has to be developed to automate the process of data entry. Moreover, there are only two methods in which this system can be used: Web and email. Since both these approaches needs a desktop PC, it is not a cost-effective solution and, therefore, would not be deployed in medical waiting rooms. Questionnaire Design Software Designed by Pocket Survey, Questionnaire Design Software is a tool for designing questionnaires and collecting questionnaire data on Windows CE handheld devices. With this system, you can open a new questionnaire, save the questionnaire, and design the questionnaire. You can add questions to the questionnaire or change the questions in the questionnaire. Questions are grouped in this system, which allows the questions to be displayed sequentially or randomly when running the questionnaire. A built-in handheld simulator is provided with the system to test the questionnaire on the desktop PC before deploying the system on the handheld computer. You can also use the handheld simulator to run the questionnaire for real on the desktop PC. Once you have finished designing and testing the questionnaire, you transmit the questionnaire to the handheld computer by 2

PAGE 16

6 synchronizing it to the desktop PC. When you have finished collecting data, you again have to synchronize it to the desktop PC to receive the results. This system gives the facility to design and edit the questionnaire and it runs on Pocket PC, which is a cost-effective solution. It does not completely automate the process of data entry. Someone has to synchronize the handheld PC to the desktop PC to download the questionnaire. After collecting the data, someone has to again synchronize it to the desktop PC to receive the results. Moreover this questionnaire system is not dynamic (i.e., the next question does not depend on the answer of the last question). Therefore, this system does not meet all the requirements of the proposed system. eSurvey Designed by eSurvey Solutions, eSurvey is a costeffective solution to market research. eSurvey Solutions provides three types of survey systems: Palm Surveys, Internet Survey, and Phone Surveys. You can create your survey with the Internet based Survey Builder Application. You enter the questions and answer choices and this system combines them to create a survey definition. Palm Surveys allow users to download, through an Internet connection, one or more survey definitions to their Palm Pilot or compatible device. A respondent taps buttons on the Palms screen to answer a question. Once a question is answered, it disappears from the view, and the next question appears. Once the survey is complete, the results are uploaded to the Survey Reporter via a Palm Pilot Internet Connection. Uploading and viewing results varies depending on the type of the survey (Palm, Internet, or Phone). After the results imported into the Internet based Survey Reporter Application, you can ask for the results. 3 This system meets many of the requirements of the proposed system. You can create your own questionnaire with this system. Since it executes on the Palm OS, it is a

PAGE 17

7 cost-effective solution. The problem with this system is that you have to use the Survey Reporter to view the results. Someone then has to either enter the data into the database manually, which is error prone, or build another application that enters the data into the database. So, this system by itself cannot be deployed to a medical waiting room. Tripod Data Systems Survey Pro for Pocket PC (TDS) Survey Pro (TDS) runs in the Windows CE environment and supports different styles of surveys. This system supplies its own soft keyboard (SIP), which has larger keys than the iPAQ version. There are two TDS SIPs: one for numbers and one for letters, which provide a convenient way to enter the numbers and characters commonly used in surveys. Shortcuts are provided for certain tasks. For example, when actually starting the application all you need to do is press the key: the big silver button located at the bottom of the iPAQ. You are then prompted to enter a description for the survey. You can choose from the earlier descriptions or define a new one. Certain steps need to be followed to create a new description and through these steps TDS provides a way to design your own questionnaire. Survey Pro supports description files and remembers the last one used, if you are going to use the same description. Survey Pro ships with Survey Link, a program used to transfer data from the iPAQ to a PC. Survey Link also has a number of conversion routines used to convert between TDS *.JOB files and other formats nave to a number of other popular software packages. 4 Although this system provides ways to create your own questionnaire, it does not completely automate the process of data entry. After collecting the data, someone again has to synchronize it to the desktop PC to receive the results. Moreover this questionnaire system is not dynamic (i.e., the next question does not depend on the answer of the last

PAGE 18

8 question). Therefore, this system does not meet all the requirements of the proposed system. PalmQues Designed by Ryan Donahue, PalmQues runs on the Palm OS and was specially designed to replace the paper-based questionnaire in the medical waiting rooms. PalmQues has three components: Editor, Synchronizer, and Mobile Presenter. PalmQues assists the questionnaire designer in creating or editing a questionnaire definition. The questionnaire definition is saved to the receptionists desktop. When a patient arrives, the receptionist enters the patients identification, connects a Palm OS device to the desktop, and informs PalmQues to synchronize with the device. At this point, PalmQues checks the device for results from a previous session. If none are present, it sends the questionnaire definition along with the patient identification to the Palm OS device. Once this is complete, the receptionist hands the device to the patient. The patient selects answers for each question and, once the questionnaire is completed, returns the Palm OS device to the receptionist. The receptionist again connects the Palm OS device and the desktop and synchronizes PalmQues. This time PalmQues finds results on the device and downloads them to the desktop, where they are automatically stored in the appropriate database. 5 Although this system was designed specially for medical waiting rooms, it does not completely automate the process of data entry. Someone has to synchronize the handheld PC to the desktop PC to download the questionnaire. After collecting the data, someone has to again synchronize it to the desktop PC to receive the results. This system is not dynamic; the questionnaire definition must be downloaded before the start of the

PAGE 19

9 questionnaire by synchronizing the Palm with the desktop PC. Therefore, this system does not meet all the requirements of the proposed system. Professional Quest Dipolar describes Professional Quest as the most flexible and powerful questionnaire and survey creation program available. It contains tools for creating, answering, and analyzing survey data. Professional Quest creates both structured and form-based questionnaires. It features a flexible visual designer, powerful reporting, and a range of statistical graph types. Professional Quest provides over 50 questionnaire templates, a question library, and questionnaire layout themes. It also includes a survey web site builder tool, which allows you to create a complete, web-based interface for your survey, including the ability to add, edit, delete, and view responses online. This system can be deployed in various ways including paper, HTML questionnaire forms via Email, HTML questionnaires on the Web or Intranet, and floppy-diskette questionnaires. 6 This system does not enter the data into the existing database. Therefore, someone has to either manually enter the data or build another application that enters the data into the database. So, this system by itself cannot be used in medical waiting rooms. Moreover, this system runs only on a desktop PC. To deploy this system in medical waiting rooms, these rooms will have to be equipped with desktop PCs; therefore this system is not cost-effective. SurveyMate Created by ThinkingBytes SurveyMate is an electronic questionnaire/quiz system that runs on Palm OS. It can handle single answers, multiple answers, essay-type, and conditional questions. To use this system, you create a word document on a desktop PC or as a memo in your Palms memo pad application, then type in the questions according 7

PAGE 20

10 to the format suggested by SurveyMate. This word document or memo questionnaire is downloaded to SurveyMate when it starts. After a series of interviews, you can view the results within the application on Palm either as a count, percent, or bar graph. This system succeeds in meeting two of the requirements of the proposed system. It provides a way to create your own questionnaire. This system runs on Palm OS and thus it is a cost effective solution that could replace paper-based questionnaires in the medical waiting rooms. The shortcomings of this system are that it does not provide a way to enter to data into the database, and the results can only be viewed as a count, percent, or graph, so this system cannot collect the data specific to a particular user. ScreenSurvey Developed by the National Research Council of Canada, ScreenSurvey is a software to automatically administer on-screen questionnaires. Questions in this system are designed using the custom Form Builder software. The Form Builder allows complete flexibility in placing the items on the question form, their size, and their color. This system features different response types to a question. Once created, the questions can be administered in any order. Any number of questions may be asked with any frequency. Specific questions can be defined as demographic, which are asked only once since the answers would not be expected to change over time. The answers to the demographic questions can be used to decide which questions are subsequently asked. For example, if a user is a female, she would not subsequently be asked to complete a checklist that applies to males, but instead would be asked to complete a checklist that applied to females. The responses to the questions are stored on the host computers hard disk for collection at the end of the study. 8

PAGE 21

11 This system succeeds in giving the flexibility to create the questionnaire. It is a dynamic system in which the answer to a question dictates the subsequent questions to be asked from the user. It is not clear how the results are stored in this system and whether the results of the specific user can be viewed or not. Moreover, this system runs on a Windows computer and therefore is not a costeffective solution for waiting rooms. Chapter Summary This chapter described existing questionnaire systems. All of the above systems have been successful in fulfilling some of the requirements of the proposed system, but none of them meets all the requirements. MDC is a system that is designed to meet all the requirements of the proposed system. The next four chapters discuss the design, features, and different components of the MDC system.

PAGE 22

CHAPTER 3 FEATURES AND DESIGN OF MDC As discussed in the last chapter, existing systems have not been able to replace the paper based questionnaire system in medical waiting rooms. This chapter describes the features and design of MDC. Before discussing the features of MDC, we need to know the process involved in the paper based questionnaires. Paper-based Method of Data Collection The paper-based method is the traditional method of data collection. Figure 3.1 shows its data flow. A doctor or the administrator creates/edits the questions. Once he is done writing the questions to be asked by the respondent, those questions are printed on a paper. These printed paper questionnaires then go to the receptionist who gives these questionnaires to the respondents. Respondents then complete the paper questionnaire and return it to the receptionist. To utilize the data collected, they have to be entered into an existing database. As described in Chapter 1, this method of data collection is very inefficient. Paper based questionnaires are static (i.e., the answer of a question does not dictate the subsequent questions to be asked from the respondent). The editing of these paper based questionnaires is very time consuming and requires the entire process of questionnaire creation to be repeated. 12

PAGE 23

13 Manual Questionnaire Creation / Edition Printing Receptionist Respondent Receptionist Manual entry of Data in the Database Figure 3.1 Data Flow in Paper based Questionnaires If the questionnaire contains some questions that are specific to some group of respondents then the layout of the questionnaire can become very complex for the respondents. For example, if there are some questions specific to male respondents, then female respondents do not need to answer these questions and they have to skip these questions, going to some other part of the questionnaire. Quite often this is not very intuitive for the respondents and leads to confusion. To utilize the collected data, it needs to be manually entered into the existing databases. Manual data entry is errorprone and adds to the inefficiency of the system in terms of delays and errors. In addition, there is

PAGE 24

14 the possibility that the receptionist could loose the completed questionnaires. MDC is designed to overcome the shortcomings of paper based questionnaire system. The rest of the chapter describes the MDC system in detail. Mobile Data Collection System for Pocket PC MDC is an electronic questionnaire system that meets all the requirements of the proposed solution to the medical waiting rooms problem. Figure 3.2 shows MDCs data flow. Questionnaire Editing Receptionist Pocket PC Respondent Data Database Figure 3.2 Data Flow in the MDC A doctor or administrator remotely creates/edits the questions to be answered by the respondents. Once the questionnaire is ready, the receptionist starts MDC on the Pocket PC. MDC requests the demographic information of the respondents which includes Name, SSN, Sex, and Age as shown in Figure 3.3. The receptionist or nurse completes this information and submits it to the database. MDC downloads the subset of all the questions from the database according to the demographic information submitted

PAGE 25

15 and wirelessly sends the first question to the Pocket PC to be displayed on the screen. The receptionist now gives the Pocket PC to the respondent. The respondent answers each questions by clicking on one of the displayed answers. A typical question is shown in Figure 3.4. At any time, he/she can go back to the previous question and change the previously entered answer. The progress of the respondent in completing the questionnaire is shown at the bottom of the screen. Once the respondent has answered all the questions, MDC shows a Finish screen as shown in Figure 3.5. Figure 3.3 Demographic Information Screen As soon as the respondent finishes the questionnaire, the results are submitted to the database. MDC provides a simple way to create/edit the questionnaire, an intuitive layout to the respondents, elimination of the errors/delays that occur due to manual data entry of the collected data, and provision of a dynamic way of asking questions from the respondents. All these have been achieved by three different components of the MDC: the MDC proxy, the MDC server, and the MDC client. These components are explained

PAGE 26

16 in detail in Chapters 4, Chapter 5, and Chapter 6, respectively. Figure 3.6 shows the data flow between the three components of MDC. Figure 3.4 Sample Question within the Questionnaire The flow of information between the three system components is as follows. First, the Client sends a request to the Proxy. The Proxy queries the Server, and Server writes the result of the query on an Html page and returns it to the Proxy. The Proxy then sends that Html page to the HTML Parser, which parses the data on the Html page and builds an object of the Hash Table containing all the relevant information. This Hash Table object is then sent to the Proxy. The Proxy extracts the data from the Hash Table and sends the response back to the Client.

PAGE 27

17 Figure 3.5 Finish Screen Questions and Their Types The questions database has been designed in MS Access. Two types of questions are used in this system: Normal (n): A normal question is a question whose answer does not change the subsequent questions to be answered by the respondent. Critical (c): The answer to a Critical question dictates the subsequent questions to be answered by the respondent. If the answer to a critical question is equal to the trigger answer then some follow-up questions need to be asked. These follow-up questions can also be of the type Normal or Critical. Every critical question has an associated follow number. This follow number is the number of follow-up questions to be asked. Figure 3.7 shows the General Questions Table of the database. Every record of this table is a question and every question has following attributes: Q_Id: Question ID of the question. This ID is important because it identifies the order of the questions to be asked. For Example: If the Q_Id of a question is 10, then this question will be asked after the respondent has answered the first nine questions.

PAGE 28

18 Request Query CLIENT PROXY SERVER Response Result HTML Page HASH Table HTML PARSER Figure 3.6 Mobile Questionnaire component data flow Q_String: This is the Question itself. For Example: Do you have fever? Q_Type: Normal, Critical or Follow. Q_Trigger: If the question is a Critical question, then this is the Trigger answer of the question; otherwise, this value is null. Q_Follow: If the question is a critical question, then this is the number of follow-up questions; otherwise, this value is 0. Ans1, Ans2, Ans3, Ans4, Ans5: Five fields for five possible answers to a question, which are specified by the person designing the questionnaire. Creation / Editing of the Questionnaire MDC provides a very simple way to create/edit the questionnaire. Figure 3.7 shows the General Questions Table of the database. MDC has an already designed database that has some tables with no records. If you want to create the Questionnaire, all you must do

PAGE 29

19 is add a record in the table for each question. Every record is a question with the attributes defined in the last section. Once you are done adding records in the table, you can start using MDC on the Pocket PC for the data collection. Figure 3.7 General Questions Table If you want to edit or update the questionnaire, all you must do is click on the fields of the question that you want to edit and make the necessary changes. Once you save the changes, MDC accepts those changes. The next time you start the application on the Pocket PC, it will display the updated questionnaire. In this way the creation and editing of the questionnaire becomes very simple. Questionnaire Layout One of the problems with the paper based questionnaire is that the layout becomes very complex if there are many questions in the questionnaire. This can become very confusing for the respondents. MDC has overcome this shortcoming by providing a very simple and intuitive layout of the questionnaire. Figure 3.4 shows a typical question to be answered by the respondent. Only one question is asked on each screen, reducing the

PAGE 30

20 complexity for the respondents. The respondent answers the question with just a single click on the screen. Dynamic Questionnaire System MDC is a dynamic questionnaire system (i.e., the answer of a question decides the subsequent questions to be asked from the respondents). It provides a way of asking only the relevant questions from the respondent, making this system a very efficient data collection system. This is achieved by a wireless connection between MDC and the database. When the respondent answers a question, the application sends a query to MDC proxy. The Proxy checks to see if the answered question was a critical question. If it is a not a critical question, it simply picks up the next question in the sequence and sends it to the MDC. If it was a critical solution, then it checks to see if the respondent has triggered the critical question. The answer to the critical question dictates the subsequent questions to be asked from the respondent as shown in the Figures 3.8, 3.9, and 3.10. Figure 3.8 shows a critical question on the Pocket PC. The trigger answer of this critical question is Yes. If the respondent selects Yes and clicks the next button, the result is shown in Figure 3.9. The progress bar shows the increased progress towards completion compared to the one in Figure 3.8. This progress is achieved by answering a single question. The question shown in Figure 3.9 is a follow-up question that is to be asked from the respondent. If the respondent selects any other answer in Figure 3.8 except Yes and clicks the Next button, the result is shown in Figure 3.10. In this case, the respondent has not triggered the critical question and, therefore, MDC has skipped all the follow-up questions because the respondent does not need to answer them now. As a result, the progress bar is showing more progress as compared to the one in Figure 3.9. So, in a way

PAGE 31

21 the respondent has in effect answered more than one question by not triggering the critical question. The number of questions that are skipped determines the amount of change in the progress bar. Figure 3.8 Critical Question MDC thus executes in a dynamic manner by asking only relevant questions. Only one question is asked on one screen and the next question is selected based on the response to the current question. Respondents do not need to skip the questions themselves, which makes MDC very user-friendly. Design Issues Platform Visual Studio .NET with Smart Device Extensions (SDE) was selected to develop this application. Visual Studio .NET is a unified development environment, which enables applications to be developed for mobile devices. Smart device extensions are 9 10

PAGE 32

22 specifically targeted towards development for the mobile devices. It includes the templates for Pocket PC and Windows CE based application. The MDC client application was developed using Visual C# because it is a very powerful language for making applications involving Graphical User Interface and network programming. The MDC proxy application was developed using Java because it is platform independent and can execute on any environment. The database for the MDC was designed using MS Access because of its simplicity of use and its capability to interact effectively with Java Servlets 11 12 13 Figure 3.9 After triggering the Critical Question Connecting to the Database MDC can work with any database that is compatible with Java Database Connectivity (JDBC). JDBC is an API that provides access to any tabular data source from the Java programming language. JDBC API provides the advantages of Java Platforms Write once and Run Anywhere. JDBC was designed to simplify

PAGE 33

23 development tasks. It makes database tasks like Select, Insert, etc. very simple and provides cross-DBMS connectivity to a wide range of SQL databases. JDBC API provides access to other tabular data sources, such as spreadsheets. Figure 3.10 Without triggering the Critical Question JDBC is compatible with many databases like: ADABAS, ALLBASE SQL, BASIS, CA-IDMS, Cache, Centura SQLBase, CISAM, Clipper, Cloudscape, CodeBase, DABroker, DafodilDB, Datacom, DataFlex, dBase, DBMaker, DL/I, DMSII, Domin, Empress RDBMS, Enscribe, Essentia, FoxPro, FrontBase, IBM AS/400, IDMS, ImageSQL, IMS, Informix, Ingres, InstantDB, InterBase, JDataStore, kdp, LDAP, MUMPS, Mimer SQL, MS Access, MS SQL Server, mSQL, MySQL, NewsServer, Nonstop SQL/MP, OpenBase, Oracle, and many more. Data Entry Hospitals are shifting to a wireless infrastructure, providing one reason why wireless was chosen as the medium of data entry. Data entry is done automatically when

PAGE 34

24 the respondent finishes the questionnaire on the Pocket PC. A wireless connection is established between the MDC and the database. Wireless data entry eliminates the need of error-prone manual data entry into the database and also eliminates the need of synchronizing the device to the desktop PC. There were two choices for wireless data entry: One answer at one time. All the answers of one respondent at one time. When the respondent answers a question, MDC sends the answer to the MDC proxy. The Proxy does some processing and sends the next question to the MDC. This answer could have been added to the database at this time. But, the respondents have been given the flexibility to go back and change any answer if they like and this would lead to many temporary results stored in the database. So, if a respondent changes answers frequently, this choice of data entry would lead to a very inefficient system that continually changes and updates the database. Moreover, this would lead to many interactions with the database, which is time consuming and can lead to delays. The second choice, hence, leads to less database interaction by storing only the final answers submitted by the respondents. Therefore, the second choice of data entry was selected. Chapter Summary This chapter discussed the design issues and features of MDC. MDC has a very simple and intuitive layout, and it is dynamic. It uses JDBC for database connectivity, which makes it compatible with a large number of database products. All these features makes MDC it a very efficient system of data collection.

PAGE 35

CHAPTER 4 MDC PROXY MDC is a client-server application. Respondent data is collected by the Client, which has to be submitted to the Server. For effective communication between these two modules, an interface is required. This is achieved by implementing the MDC proxy. The Proxy serves as an interface between the Client and the Server performing various functions: Receiving the request from the client, Querying the server according to the received request, Receiving the results of the query from the server, and Sending the Response packet back to the Client. The Proxy decides the next question to be sent to the Client depending upon the answer of the previous question. Once the MDC proxy starts, it opens a Datagram socket and receives the packets from the Client. Example packets are shown in Table 4.1. Table 4.1 Different Types of Packets from the MDC client Info Packet Info#123456789#Chris#Jackson#M#24 Next Packet Next#6#No Back Packet Back#9#Yes Finish Packet Finish# 25

PAGE 36

26 These received packets are one of the following four types: Info Packet, Next Packet, Back Packet, and Finish Packet. Info Packet If the first field of the packet is Info, it identifies that the user has just completed the personal information. This packet is shown in Table 4.1 and contains the following information of the respondent: SSN, First name, Last Name, Sex, and Age. The Proxy extracts all this information from the packet and creates a connection with the Server using the HttpURLConnection class available in Java. The Proxy then writes a query to the GetInformation HTML page of the Server to insert a record containing the personal information of the respondent in the P_Info table of the database (the database details are discussed in Chapter 5). This is done using the setRequestMethod (Post) method of the HttpURLConnection class. The MDC server inserts the record in the P_Info table, then retrieves and writes all the questions to an HTML page with each questions information on a line as shown in Figure 4.1. The MDC server is discussed in Chapter 5.

PAGE 37

27 Figure 4.1 HTML Page with the Questions Details passed to the Proxy by the MDC server Every line in Figure 4.1 has complete details of one question. The first field of every line is the Question_Id, second is the question to be answered, third is the type of the question as described in Chapter 3, fourth is the Answer Trigger, fifth is the number of follow questions to be asked, sixth is the number of answer choices, and the rest five are the five answer choices to the question. The HTML class is written to parse all the data written by the MDC server and performs the following functions: Reads the HTML page line by line, Extracts all the information about each question, Makes an instance of the Question class, and Inserts the instance into a Hash Table with its Key equal to the Question_Id. Since the Questions in the questionnaire may be accessed several times for editing or retrieving purpose, a Hash Table has been designed to store the instances of the

PAGE 38

28 questions to minimize the complexity of data access. The Proxy then calls the getString method of the HTML class, which returns the instance of the Hash Table class containing all the Question objects. In this way, Proxy retrieves all the questions from the database as a result of a single query and hence avoids the need of multiple queries. Next, the Proxy retrieves the Question object at the key location and prepares a Response packet according to the information in this Question object. The Response packet is shown in Table 4.2 and it contains information about the next question: the Question_Id, the Total number of Questions, the Question String, and the answer if already selected or null otherwise. After the Response packet has been prepared, the Proxy sends this packet to the MDC client. The MDC client extracts the question information from this packet and displays the question on the Pocket PC. The MDC client is discussed in Chapter 6. Table 4.2 Response packet sent to the MDC client Response Packet 3#1#12#Are you Allergic?#null#Yes#No#Not Sure#null#null Next Packet If the first field of the packet is Next, the user has answered a question from the questionnaire. This Packet is shown in Table 4.1 and contains information about the question answered including the Question_Id and the answer selected. Depending on the answer selected, the Proxy must decide which is the next question to be asked. There are three types of questions: Normal, Critical, and Follow. If the answered question is of type Normal or Follow, then the next question has a Key equal to Question_Id + 1. Critical questions are triggered by a particular answer. If the answer to the Critical question is equal to the Trigger answer, then the follow-up questions are

PAGE 39

29 asked, otherwise the follow-up questions are skipped and the subsequent question is asked. So, if an answer is a Trigger answer, then the next questions Key equals Question_Id + 1. If not, then the next question has a Key equal to Question_Id + Follow number + 1. If this calculated position is greater than the number of questions in the Hash Table, then the Response Packet is set to Finish. Otherwise, the MDC proxy receives the Question object at the calculated Key location and prepares a Response packet according to the information in this Question instance. After the Response packet has been prepared, the Proxy sends this packet to the MDC client. Back Packet If the first field of the packet is Back, the user has clicked the Back button on the Client Application. This packet is shown in Table 4.1 and contains information about the current question on the Client like Question_Id and the answer selected, if any. The Proxy then must select the previous question that was answered by the respondent. The previously answered question does not have a null answer because this was a question previously answered. The Proxy retrieves this question from the database subset, which it received as a result of the query to the Server, using a Key equal to Question_Id 1. Using this key, it checks whether the answer to the previous question in the database subset is null or not. If the answer is null, then the Proxy again gets a question with the Key equal to this Question_Id 1. This process continues until the Proxy finds an answered question. This is the previous question that was answered by the respondent. The Response packet is then created using the information in this Question instance. After the Response packet has been prepared, the Proxy sends this packet to the MDC client.

PAGE 40

30 Finish Packet If the first field of the packet is Finish, the respondent has answered all the questions and has clicked the Finish button on the FinishForm. This packet is shown in Table 4.1 and contains no more information. The Proxy keeps all the answers submitted by the respondent until the end of the questionnaire. Finish packet signifies the end of the questionnaire. After the Proxy receives this packet, it must submit all the answers to the Server. The Proxy retrieves each question from the Hash Table and checks whether the answer is null or not. If an answer is null, then it means that its corresponding question was not asked in the questionnaire as it was a follow-up question to a critical question. In this case, the proxy skips to the next question. If not, then it creates a connection with the Server using the HttpURLConnection class. The Proxy writes a query to the Server to insert the records in the Results table of the database. This is done using the setRequestMethod (Post) method of the HttpURLConnection class. Finally, the Response packet is set to Your answers have been added to the Database. Once the Response packet has been prepared, the Proxy opens another Datagram Socket and sends the packet to the Client Application so this final message is displayed to the respondent. Chapter Summary The function of the Proxy is to provide an efficient communication interface between the MDC client and the Server. The HTML class has been implemented for parsing the HTML page produced by the MDC server as a result of the query. The Proxy retrieves all the questions from the database; therefore, multiple queries to retrieve the questions are not needed. The Proxy keeps all the answers submitted by the respondent

PAGE 41

31 until the end of the questionnaire; therefore, only final answers are submitted to the MDC server. The next Chapter discusses the MDC server.

PAGE 42

CHAPTER 5 MDC SERVER The MDC server is the second module in this application. It holds the archive of questions and is responsible for providing the subset of these questions based upon the demographic information submitted by the respondent. It performs the following functions: Archives the questions and their details, Responds to the queries from the MDC proxy, Stores the respondents demographic information, and Stores the respondent data. MDC server Components The MDC server consists of a database and two web applications: GetInformation and AddResults. Figure 5.1 shows the interaction between these components of the MDC server. The MDC proxy writes a query on the GetInformation HTML Page to retrieve all the questions from the database. The GetInformation Servlet is associated with the GetInformation HTML page and performs the following functions: Queries the database to select all the questions, Receives the results, and Writes the result on another HTML Page, which is shown in Figure 4.2. The MDC proxy writes another query on the AddResults HTML Page to submit the answers of the respondents to the database. The AddResults Servlet is associated with the AddResults HTML Page and queries the database to insert the answer. Each component in the MDC server performs a pivotal operation to respond to the queries of the MDC proxy. 32

PAGE 43

33 Database The MDC database has the following tables: P_Info: This table contains the demographic information for all respondents. Each respondent has a single record in this table containing the following information: FName, the first name of the respondent, LName, the last name of the respondent, SSN, the respondents Social Security Number, Sex, the sex of the respondent, and Age, the respondents age. General_Q: This table contains general questions to be answered by the respondent. Every record is a question having the following properties: Question_ Id, the questions Id, Question Name, the question string, Question Type, the value Normal, Critical, or Follow, Question Trigger, the Trigger answer if it is a Critical question and null otherwise, Question Follow Number, the number of follow up questions if it is a critical question and null otherwise, No_Ans, the number of answer choices to the question, and Five answer fields, the five possible answers to a question. Male_Q: This table contains questions to be answered by male respondents. Every record is a question having the same properties as the General_Q table. Female_Q: This table contains questions to be answered by female respondents. Every record is a question having the same properties as the General_Q table. Results: This table contains the answers given by the respondents. Every record in this table is an answer given by a respondent to a particular question. Each record has the following fields: SSN, the Social Security Number of the respondent, Question_Id, the Id of the question, and Answer, the answer selected by the respondent.

PAGE 44

34 MDC server Database GetInformation AddResults Servlet Servlet HTML Page HTML Page Query Query MDC Proxy Result Result Figure 5.1 MDC server component data flow The Questions in this questionnaire system are not hard coded, but rather can be easily changed by modifying the values in the three question tables. Also, adding records to the appropriate table in the database extends the questions to be asked. In this way, this application provides a method to edit or extend the questionnaire, allowing the questionnaire to provide a broad range of questions for a complete understanding the patients medical history.

PAGE 45

35 GetInformation GetInformation has been designed for entering the respondents demographic information into the database and to retrieve all the questions from the Questions archive based upon that information. Its functionality is achieved through the following modules: GetInformation HTML page and GetInformation Java Servlet. The GetInformation HTML page has five text boxes, which are used to obtain the respondents demographic information. A Submit Query button has been placed at the bottom of this page as shown in Figure 5.2. This HTML page has the following five text boxes: SSN, First Name, Last Name, Sex, and Age. The MDC proxy establishes an HTTPConnection with this HTML page and writes a query using the setRequestMethod("POST") method. This query contains the information for these five text boxes and is submitted to the database by the associated GetInformation Servlet. The GetInformation Java Servlet uses the contents of these five text boxes to prepare the Insert query. The query used is insert into P_Info (FName,LName,SSN,Sex,Age) values (fname, lname, ssn, sex, age). After this query is executed, the respondents demographic information is entered into the P_Info table of the database. Depending upon the sex of the respondent, this Servlet prepares a Select query, which retrieves all of the questions from the appropriate two tables in the database. General_Q table is always used in this query, while the second table is either Male_Q or

PAGE 46

36 Female_Q depending upon the sex of the respondent. The query used is either select from General_Q,Male_Q or select from General_Q,Female_Q. The Servlet displays all the extracted questions on an HTML page, which is passed to the MDC proxy. The Proxy sends this HTML page to the HTML Parser, which is responsible for reading the questions and inserting them into the Hash Table. Figure 5.2 GetInformation HTML Page AddResults AddResults has been designed to enter the respondents answers into the database. This is achieved through the following modules: AddResults HTML page and AddResults Java Servlet.

PAGE 47

37 The AddResults HTML page has three text boxes, which are used to obtain the respondents answer to a question. A Submit Query button has been placed at the bottom of this page as shown in Figure 5.3. This HTML page has the following three text boxes: SSN, Question_Id, and Answer. Figure 5.3 AddResults HTML Page The MDC proxy establishes an HTTPConnection with this HTML page and writes the query using the setRequestMethod("POST") method. This query contains the information for these three text boxes and is submitted to the database by the AddResults Servlet associated with this HTML page. The AddResults Java Servlet uses the contents of these three text boxes to prepare the Insert query. The query used is insert into Results (SSN, Q_Id, Ans) values (ssn,

PAGE 48

38 q_id, ans). After this query is executed, the respondents answer is entered into the Results table of the database. Chapter Summary The MDC server provides an archive of questions for the application and allows different operations to insert information in and extract information from its database. The database has various Tables, which provide a subset of questions from the questions archive to the MDC proxy for conducting the questionnaire. The GetInformation and AddResults modules of the Server render wireless accessibility for these operations. The next Chapter discusses MDC client.

PAGE 49

CHAPTER 6 MDC CLIENT The MDC client runs on a Pocket PC and provides the respondent interface. It is an electronic substitute for the paper-based method of data collection. It displays one question at a time and has a very intuitive layout. Through its respondent-friendly graphical interface, it provides simplicity of use and efficiency in data collection. This application is implemented using four different forms, which are designed to display the information and the instructions for the respondents. The various forms are: MainForm, which collects the demographic information of the respondent, Question1Form, which presents the details of the first question, Question2Form, which presents the remaining questions, and FinishForm, which indicates the completion of the questionnaire. MainForm The application starts with the MainForm as shown in Figure 6.1. This form requests personal information of the respondent like SSN, First Name, Last Name, etc. Textboxes are used to collect the respondent data. Once the respondent has provided the information, he can submit it by pressing the submit button at the bottom of the form. If all the required information is not provided, the application displays a pop up message box asking the respondent to fill out the desired information, as shown in Figure 6.2. After the respondent has provided the requested information and clicked the submit button, the application prepares an Info Datagram packet to be sent to the MDC proxy as shown in Table 4.1. The SendRec method is responsible for sending and receiving the datagram packets between the MDC client and MDC proxy. This method is described 39

PAGE 50

40 in the last section of this Chapter. After the packet has been sent to the MDC proxy, the Client waits for the Response packet. Figure 6.1 MainForm The Response packet as shown in Table 4.2 contains the following information for the first question in the questionnaire: No_Ans, which is the number of answer choices to the first question, Question_Id, which is the Id of the question in the database, TotalQues, which identifies the total number of questions in the questionnaire, Question String, which is the question being posed to the respondent, Answer, which is a null string, and Ans1, Ans2, Ans3, Ans4, Ans5, which are the five answer choices to the first question. These answers are displayed on the Pocket PC as different radio buttons. All five answer choices are not displayed all the time and which are displayed depends on the value of No_Ans. For example: If the No_Ans is 3, then only Ans1, Ans2 and Ans3 are displayed as possible answer choices as shown in Figure 6.3.

PAGE 51

41 Figure 6.2 Pop up Message When the Client receives the Response packet from the MDC proxy, it creates an instance of the Question1Form by passing the question information to its constructor. The Client then calls the ShowDialog method of the Question1Form class, which displays the form on the Pocket PC. Question1Form The Question1Form contains a Textbox for displaying the question to be asked. See Figure 6.3. This form also has various Radio buttons for different answer choices. A Next button and a Progress Bar are placed at the bottom of this form. The Progress Bar displays the respondents progress through the questionnaire. It uses the value of TotalQues and the question number to display the respondents progress through the questionnaire. If the respondent clicks the Next button without answering the question, the application displays a pop up message box prompting the respondent to answer the question.

PAGE 52

42 Figure 6.3 Question1Form Once the respondent clicks the Next button after answering the question, the application prepares a Next Datagram packet as shown in Table 4.1. This packet contains the Id of the question displayed on the Pocket PC and the answer selected by the respondent. The first field in the packet is Next, which signifies that the next question is to be selected. Once the packet has been prepared, it is sent to the proxy, and the application waits for a Response packet. The MDC proxy selects the next question to be answered by the respondent. The answer to the previously asked question is used to determine the next question. Proxy sends a Response packet as shown in Table 4.2 to the Client. When the application receives the packet from the proxy, it creates an instance of the Question2Form by passing the question information to its constructor. The application then calls the ShowDialog method of the Question2Form, which displays the form on the Pocket PC.

PAGE 53

43 Question2Form Question2Form has a Textbox for displaying the question to be asked. See Figure 6.4. This form also has various Radio Buttons for the different answer choices. Back and Next buttons and a progress bar are present at the bottom of this form. If the respondent clicks the Back button, the application prepares a Back Datagram packet as shown in Table 4.1. This packet contains the Id of the question displayed on the Pocket PC and the answer, if selected by the respondent. The first field in the packet is Back, which signifies that the previous question is to be selected. Once the packet has been prepared, it is sent to the proxy and the application waits for the Response packet. The MDC proxy locates the previous question asked. The Proxy returns a Response packet to the Client containing the information of the previous question. The MDC client displays this previous question as well as the answer that had been selected. Figure 6.4 Question2Form

PAGE 54

44 If the respondent clicks the Next button on Question2Form without answering the question, the application displays a pop up message box asking the respondent to answer the question. After answering the question, if the respondent clicks the Next button, the application prepares a Next Datagram packet as shown in Table 4.1. This packet contains the Id of the question displayed on the Pocket PC and the answer selected by the respondent. The first field in the packet is Next, which signifies that the next question is to be selected. Once the packet has been prepared, it is sent to the proxy and the application waits for the Response packet. This process continues until there are no more questions in the questionnaire. At this time, the proxy responds with a packet containing Finish string. When the application receives this packet from the proxy, it creates an instance of the FinishForm. The Question_Id of the question currently displayed on the Pocket PC and the answer selected by the respondent are passed to the FinishForm. This is the last question which was asked from the respondent. The application then calls the ShowDialog method of the FinishForm, which displays the FinishForm on the Pocket PC. FinishForm The FinishForm, shown in Figure 6.5, has Back and Finish buttons. If the respondent clicks the Back button, a packet as shown in Table 4.1 is prepared and sent to the MDC proxy. In this case, the Proxy sends the Response packet like the one shown in Table 4.2. This packet contains the information about the previous question, which is displayed by calling the ShowDialog method of the Question2Form. If the respondent clicks the Finish button, a packet containing the Finish string is prepared and sent to the MDC proxy. MDC client then calls the Close method of the FinishForm and the MDC client on the Pocket PC closes.

PAGE 55

45 SendRec The SendRec method has been implemented to send and receive the datagram packets between MDC client and MDC proxy. This method receives a string argument containing the packet as shown in Table 4.1, creates a datagram socket, sends the packet to the MDC proxy and receives the Response packet from the MDC proxy. Figure 6.5 FinishForm Chapter Summary This chapter discussed the implementation aspects of the MDC client in conjunction with the MDC proxy and Server. The various forms used for displaying the questions have been described in detail. The communication between the Client and the Proxy has been explained. The simple and intuitive graphical interface makes the MDC client a very effective tool for addressing the data collection problem.

PAGE 56

CHAPTER 7 CONCLUSION AND FUTURE WORK The MDC application is an electronic questionnaire system, which emulates the paper-based method of data collection. It is a very effective system for data collection and can be easily deployed in medical waiting rooms. Various applications developed in the past have addressed similar issues but have not been able to replace paper-based questionnaire in medical waiting rooms. They have neglected at least one of the following features: the dynamic nature of the questionnaire, the ability to provide unlimited questions in the database, wireless access to the database, and the development of a cost-effective solution. This application, which is developed for a Pocket PC tackles the drawbacks of the earlier systems and uses various modules to achieve all of the above mentioned features. The ease of use, the user-friendly interface, and its dynamic environment are instrumental features in making this application very accessible and operational in medical waiting rooms. Using this system, physicians can access patient information without any time delays or possibilities of errors in collecting data. Hence, this application holds the prospects of revolutionizing data collection techniques not only in the medical waiting rooms but also in any environment supporting wireless accessibility. Despite the various features implemented in this application, there are several features which can be extended to make this application more efficient and effective. This application uses Client-Server architecture. The MDC proxy has been implemented to provide an interface for communication between the MDC client and the Server. 46

PAGE 57

47 However, the Proxy can provide the interface for only one Client. Multiple Proxy modules are required to cater to multiple Clients. This would necessitate starting a separate Proxy module for each Client, which could result in a bottleneck. This issue can be resolved by modifying the Proxy so it can single handedly respond to requests from multiple Clients. This can be achieved by generating a new thread of operation at every instance of a new Client request. This would maintain the effectiveness of the application in a multiple Client environment. The MDC server contains a database, which holds an archive of questions in different tables. The Servlet queries the database according to the sex of the respondent. This information is hard-coded in the Servlet, which makes the system rigid for any further extensions in accessing the database tables. This issue can be resolved by passing an informative data set to the Servlet, which would dictate the selection of the tables from the database. This would eliminate the need for hard-coding the tables in the Servlet and would hence, utilize the data set information as the key for accessing the tables from the database. Another extension to this application would be to make it platform independent. This could be done by making the Client run on any environment. A separate module could be written on the Client, which would recognize the operating system and accordingly start the Client application. This modification could equip the MDC application with write once, run anywhere capability. Such a feature would extend the usability of this application and make it accessible to multi-platform environments.

PAGE 58

48 The starting page of the application on the Pocket PC is currently static and always displays the same information. Extending the system so the first page is not hard coded, but is dynamic like all of the other pages, is another area for future extension. At present, the application provides at most five possible answer choices and the option to select only one answer to a given question. This style although most frequently encountered in questionnaires, nevertheless, ignores the possibility of more than five answer choices to a given question and selecting multiple answers to a single question. Improving on this scheme can be performed as possible future work. The MDC application is designed and implemented to address the electronic-based questionnaire system problems. Several features have been incorporated to achieve the same goals. The design aspects of this application provide the scope for extension. Although several issues have been discussed as future work, this application is expected to meet the requirements of the proposed system.

PAGE 59

LIST OF REFERENCES 1. Creative Research Systems, The Survey System, Petaluma, Accessed: July 2002; www.surveysystem.com/bro.htm 2. Pocket Survey Design Software, Questionnaire Design Software, Accessed July 2002; www.pocketsurvey.info 3. eSurvey Solutions, Inc., eSurvey Solutions, Alpharetta, Accessed: August 2002; www.esurveysolutions.com 4. P. Gay, Survey Pro for Pocket PC, Tripod Data Systems, Corvallis, 2002. 5. R. Donahue, PalmQues, University of Florida, Gainesville, 2002. 6. Dipolar, Professional Quest Release 2.2, Sutherland, Accessed: July 2002; www.dipolar.com.au 7. thinkingBytes, SurveyMate, Lexington, Accessed: July 2002; www.thinkingbytes.com/products/surveymate.asp 8. National Research Council, ScreenSurvey, Ottawa, Accessed: August 2002; www.nrc.ca/irc/ie/light/lq_project/software.html 9. Microsoft Corporation, Visual Studio .NET, Redmond, Accessed: August 2002; http://msdn.microsoft.com/vstudio/ 10. Microsoft Corporation, Smart Device Extensions and .NET Compact Framework, Redmond, Accessed: July 2002; http://msdn.microsoft.com/vstudio/device/sdebeta.asp 11. E. Gunnerson, A Programmers Introduction to C#, Apress, New York, 2000. 12. P. Naughton and H. Schildt, The Complete Reference, Java 2, Tata McGraw Hill, New Delhi, 2000. 13. Sun Microsystems, Inc., Java Servlet Technology, Newark, Accessed: Jan. 2002; http://java.sun.com/products/servlet 14. Apache Software Foundation, Apache Tomcat, Accessed: Mar. 2002; http://jakarta.apache.org/tomcat 49

PAGE 60

50 15. H. W. Griffith, Complete Guide to Symptoms, Illness and Surgery, The Body Press/Perigee Health, New York, 1995.

PAGE 61

BIOGRAPHICAL SKETCH Manish Malik was born on October 6, 1979, in Panipat, India. In May of 2000 he earned a Bachelor of Engineering degree from C R State College of Engineering where he majored in computer science and engineering. He enrolled at the University of Florida in August 2000 to pursue a Master of Science in computer science and will complete the degree in December 2002. 51


Permanent Link: http://ufdc.ufl.edu/UFE0000569/00001

Material Information

Title: MDC: A Mobile Data Collection System for Pocket Pc
Physical Description: Mixed Material
Copyright Date: 2008

Record Information

Source Institution: University of Florida
Holding Location: University of Florida
Rights Management: All rights reserved by the source institution and holding location.
System ID: UFE0000569:00001

Permanent Link: http://ufdc.ufl.edu/UFE0000569/00001

Material Information

Title: MDC: A Mobile Data Collection System for Pocket Pc
Physical Description: Mixed Material
Copyright Date: 2008

Record Information

Source Institution: University of Florida
Holding Location: University of Florida
Rights Management: All rights reserved by the source institution and holding location.
System ID: UFE0000569:00001


This item has the following downloads:


Full Text











MDC: A MOBILE DATA COLLECTION SYSTEM FOR POCKET PC


By

MANISH MALIK

















A THESIS PRESENTED TO THE GRADUATE SCHOOL
OF THE UNIVERSITY OF FLORIDA IN PARTIAL FULFILLMENT
OF THE REQUIREMENTS FOR THE DEGREE OF
MASTER OF SCIENCE

UNIVERSITY OF FLORIDA


2002




























Copyright 2002

by

Manish Malik




























To my family, for all the love, support and encouragement.















ACKNOWLEDGMENTS

I would like to thank my advisor, Dr. Douglas Dankel, for giving me an opportunity

to work under him. He has been very supportive and helpful and this thesis would not be

possible without his supervision and encouragement. I would also like to thank Dr.

Joachim Hammer and Dr. Chris Sistrom for serving on my thesis committee. Finally, I

thank God and my family for always being there for me.
















TABLE OF CONTENTS
page

A C K N O W L E D G M E N T S ................................................................................................. iv

LIST OF TA BLE S ....................................................... .. ........... ............ .. vii

LIST OF FIGURES ..................................................... .......... ................ viii

ABSTRACT ........ .............. ............. ...... .......... .......... ix

CHAPTER

1 IN T R O D U C T IO N .................................................... ........................... .............. 1

2 SURVEY OF THE EXISTING QUESTIONNAIRE SYSTEMS..............................4

T h e S u rv ey S y stem ........ .................... .... .......................................... ............. .. 4
Questionnaire D esign Softw are ........................... ....... ................................... 5
eSurvey ................................ ............ ..... ............................ 6
Tripod Data Systems Survey Pro for Pocket PC (TDS) .............................................. 7
P a lm Q u e s ....................................................................... 8
Professional Quest ........................................ 9
SurveyM ate .................................................................................... . 9
S c re e n S u rv e y ................................................................................................................ 1 0
Chapter Summary ......................................... 11

3 FEATURES AND DESIGN OF MDC............................ ............................12

Paper-based Method of Data Collection ................. ..... .............. 12
Mobile Data Collection System for Pocket PC................................ 14
Questions and Their Types ........................................ 17
Creation / Editing of the Questionnaire ........ ........................ ........... 18
Questionnaire Layout ..................................... ........... .... .... .. .......... .. 19
Dynamic Questionnaire System ................................................... ................ 20
Design Issues ............................................................ 21
P latfo rm ......................................................................................... ... ......... 2 1
Connecting to the D atabase..................................... ............... .............. 22
Data Entry ........................................................... 23
C chapter Sum m ary ............................................................................................ 24




v









4 M D C PR OX Y ............. ..... .. ........................ ..................... 25

Info P ack et ............................................................................................ ...... 2 6
N ext Packet ................. .............................. ............... .............. 28
B ack P ack et ..................... ..................................................................... ....... 2 9
Finish Packet ................. .................................. .......... .............. 30
Chapter Summary ......................................... 30

5 M D C SER V ER .................................................................. 32

MDC server Components ............. .................. .............. 32
Database ................ ........ ......................... 33
GetInform action .............................................. .................. 35
A ddR results ................................................................................................... 36
Chapter Summary ......................................... 38

6 M D C C L IE N T ............................................................................................................... 3 9

M ain F o rm ................................................................... 3 9
QuestionlForm ......................................... 41
Question2Form ......................................... 43
F in ish F o rm ........................................................................................ 4 4
SendRec .................................. ................... 45
Chapter Summary ......................................... 45

7 CONCLUSION AND FUTURE WORK ..........................................46

L IST O F R EFER EN CE S ............... ......................... ............................................ .................49

BIO GR A PH ICA L SK ETCH .................51..............................................
















LIST OF TABLES

Table page


2.1 Comparison of properties of data collection systems ................................................4

4.1 Different Types of Packets from the M DC client...................................................25

4.2 Response packet sent to the M DC client ........................................ ............... 28
















LIST OF FIGURES

Figure page


3.1 Data Flow in Paper based Questionnaires ...................................... ............... 13

3.2 D ata Flow in the M D C ......................................................................... .. ........ 14

3.3 Dem graphic Inform action Screen.................................................................. 15

3.4 Sample Question within the Questionnaire ......... ..... ......... ............16

3.5 Finish Screen................................................... 17

3.6 Mobile Questionnaire component data flow....................................18

3.7 G general Q questions Table.................................................. ............................... 19

3.8 C critical Q question ................. .................................... .. .......... .............2 1

3.9 After triggering the Critical Question................................................22

3.10 W without triggering the Critical Question ...................................... ............... 23

4.1 HTML Page with the Questions' Details passed to the Proxy by the MDC server....27

5.1 M D C server com ponent data flow ........................................ .......................... 34

5.2 G etInform ation H TM L P age............................................................ .....................36

5.3 A ddR results H TM L Page.................................................. ............................... 37

6 .1 M a in F o rm ............................................................................................................. 4 0

6.2 Pop up M message .............................................. .. .. .......................41

6.3 Q question lF orm ........................... .......................... .. ... ........ ....... .. 42

6.4 Q uestion2F orm .......................... ...................... .. .. .... ........ ....... .. 43

6 .5 F inishF orm .............................................................................4 5















Abstract of Thesis Presented to the Graduate School
of the University of Florida in Partial Fulfillment of the
Requirements for the Degree of Master of Science

MDC: A MOBILE DATA COLLECTION SYSTEM FOR POCKET PC

By

Manish Malik

December 2002

Chair: Dr. Douglas D. Dankel II
Major Department: Computer and Information Science and Engineering

The traditional method of collecting questionnaire data uses a paper form

completed by each respondent. Collecting data in this manner is very inefficient because

the layout of the questions on the paper based questionnaires is often quite complex for

the respondent to understand, and the collected dataset has to be manually entered into a

database, which potentially results in time delays and data entry errors. This method of

data collection is very static in which every respondent receives an identical form and has

to answer the applicable questions and skip the non-relevant questions. In domains

having complex, multi-path sets of questions (e.g., medicine) it is virtually impossible to

construct a paper-based questionnaire in which a respondent is asked only relevant

questions. Although a paper-based questionnaire has proven to be an economical solution

in the medical waiting rooms, it is often confusing for the respondent. To date, there has

been no cost-effective electronic questionnaire system available that can completely

automate this process. Although several methods for data entry have been proposed in the









past, none has come close enough to completely automate this process in the

questionnaire systems.

The requirements of a system that can replace a paper-based questionnaire are as

follows: provide a method to create/edit the questions, eliminate the need to manually

enter the data into the database, provide an intelligent way of asking questions (i.e.,

asking only relevant questions), and provide a cost-effective solution that can be easily

deployed. This thesis presents such a solution: the Mobile Data Collection System for

Pocket PC.














CHAPTER 1
INTRODUCTION

A paper-based questionnaire is a traditional method for data collection. This

method is not only time consuming but also a very inefficient way of data collection.

Although electronic questionnaires have replaced paper-based questionnaires in many

areas, this method is still used in medical waiting rooms since no existing system has

been able to completely automate the process of data collection for this setting. To

understand the requirements of a system that could replace the paper-based method in

medical waiting rooms, we need to know the complete process of data collection in a

medical waiting room and its shortcomings.

A doctor or questionnaire creator creates questions to be answered by the

respondent. These questions are then organized, arranged, and structured prior to being

printed on paper. The receptionist gives these printed-paper questionnaires to the

respondents, who complete and return them to the receptionist. To utilize this collected

data, they must be entered into an existing database.

This paper-based method of data collection is a cost-effective solution for medical

waiting rooms but it has some shortcomings. Paper-based questionnaires are static, i.e.,

all potential questions to be answered must appear regardless of how many will actually

be completed. The editing of these paper-based questionnaires is very time consuming

and requires the whole process of questionnaire creation to be repeated. If the

questionnaire contains some questions that are specific to some group of respondents,

then the layout of the questionnaire can become very complex for the respondents. For









example, if some questions are specific to male respondents, then female respondents will

not answer these questions and will have to skip these questions and go to some other

part of the questionnaire. This often is not very intuitive for the respondents and leads to

confusion. Once the questionnaires are completed, to utilize the collected data, they need

to be manually entered into an existing database. Manual data entry is error- prone and

adds to the inefficiency of the system in terms of time delays and typographical errors.

The requirements of a system that could replace the paper based method include the

following: provide a simple way to create/edit the questionnaire, provide an intuitive

layout to the respondents, eliminate the errors/delays that occur due to data entry of the

collected data, provide a dynamic way of asking questions from the respondents and a

cost-effective solution that can be deployed in the medical waiting rooms. The Mobile

Data Collection System for Pocket PC (MDC) has been developed to meet all the

requirements stated above.

MDC provides a very simple structure for creating/editing the questionnaire. The

questionnaire creation time is almost the same as in paper-based questionnaire, but

editing the questionnaire is very simple and takes less time. The questions database for

the questionnaire resides on the desktop computer. The questions are entered into

different tables of this database by the physician. A subset of these questions, based upon

the demographic information of the respondent, is then one by one wirelessly

downloaded from this database. The questions are displayed on the Pocket PC one-at-a-

time. In this way, MDC avoids confusion and is very intuitive for the respondents. MDC

has wireless database connectivity, so the dataset is entered into the database as soon as it

is collected, thus eliminating the errors and delays caused by manual data entry. MDC









uses the answer to a question to decide which of the subsequent questions should be

answered by the respondents, so it provides a way to ask only relevant questions,

resulting in a very efficient data collection system. MDC runs on a Pocket PC making it a

cost-effective solution that can be deployed in medical waiting rooms with minimal

infrastructure required.

MDC consists of three components: the MDC client, the MDC proxy, and the

MDC server. These components interact with each other to perform all of the tasks. This

thesis discusses each of these components in detail. Chapter 2 is a survey of the existing

questionnaire systems and Chapter 3 describes the design and features of MDC. The next

three chapters discuss in detail each component. Chapter 4 is the description of MDC

proxy, Chapter 5 is the description of MDC server, and Chapter 6 is the description of

MDC client. Finally, Chapter 7 gives conclusions and lists future research needed in this

area.














CHAPTER 2
SURVEY OF THE EXISTING QUESTIONNAIRE SYSTEMS

Many electronic questionnaire systems have been designed to replace the paper-

based questionnaires. Table 2-1 gives a comparison of the properties of paper-based and

the proposed system of data collection.


Table 2.1 Comparison of properties of data collection systems
Method Way to Layout Data Entry Type Cost
of Data Create/Edit the Effectiveness
Collection Questionnaire
Paper Based No Confusing Manual Static Yes

Proposed Yes Intuitive Automatic Dynamic Yes
System

Any system that has all the properties of the proposed system could replace the

paper-based system in medical waiting rooms. This chapter discusses the features of the

various questionnaire systems and compares their properties with the proposed system.

The Survey System

Designed by Creative Research Systems, Survey System is a software package

available for working with questionnaires.1 The Survey System was designed specifically

for questionnaires and handles the creation of a questionnaire through data entry, web

services, table generation, and text reports. Survey System provides a way to edit the

data, spell check the data, calculate complex statistics, and produce quality tables. It

offers a number of optional modules: Internet Module, Voice Capture Module, and

Statistics Module. These modules enable you to customize this software package to fit the

questionnaire needs. Survey System offers two types of online questionnaires: using a









Web page or email. When using Web page surveys, the questionnaire is posted on a Web

page. People then visit the page and answer your questions. When using e-mail surveys

you send a questionnaire to a list of respondents and then they reply with their answers.

This system works on either a Windows based PC or a Macintosh.

The Survey System succeeds in meeting two of the requirements of a system that

can be used in the medical waiting rooms. It provides a way to create your own

questionnaire and eliminates the need for manual data entry into the database. The

shortcoming of the Survey System is that it needs another system to extract the data from

the exported files and to enter it into the database. Another system has to be developed to

automate the process of data entry. Moreover, there are only two methods in which this

system can be used: Web and email. Since both these approaches needs a desktop PC, it

is not a cost-effective solution and, therefore, would not be deployed in medical waiting

rooms.

Questionnaire Design Software

Designed by Pocket Survey, Questionnaire Design Software is a tool for designing

questionnaires and collecting questionnaire data on Windows CE handheld devices.2

With this system, you can open a new questionnaire, save the questionnaire, and design

the questionnaire. You can add questions to the questionnaire or change the questions in

the questionnaire. Questions are grouped in this system, which allows the questions to be

displayed sequentially or randomly when running the questionnaire. A built-in handheld

simulator is provided with the system to test the questionnaire on the desktop PC before

deploying the system on the handheld computer. You can also use the handheld simulator

to run the questionnaire for "real" on the desktop PC. Once you have finished designing

and testing the questionnaire, you transmit the questionnaire to the handheld computer by









synchronizing it to the desktop PC. When you have finished collecting data, you again

have to synchronize it to the desktop PC to receive the results.

This system gives the facility to design and edit the questionnaire and it runs on

Pocket PC, which is a cost-effective solution. It does not completely automate the process

of data entry. Someone has to synchronize the handheld PC to the desktop PC to

download the questionnaire. After collecting the data, someone has to again synchronize

it to the desktop PC to receive the results. Moreover this questionnaire system is not

dynamic (i.e., the next question does not depend on the answer of the last question).

Therefore, this system does not meet all the requirements of the proposed system.

eSurvey

Designed by eSurvey Solutions, eSurvey is a cost-effective solution to market

research.3 eSurvey Solutions provides three types of survey systems: Palm Surveys,

Internet Survey, and Phone Surveys. You can create your survey with the Internet based

Survey Builder Application. You enter the questions and answer choices and this system

combines them to create a survey definition. Palm Surveys allow users to download,

through an Internet connection, one or more survey definitions to their Palm Pilot or

compatible device. A respondent taps buttons on the Palm's screen to answer a question.

Once a question is answered, it disappears from the view, and the next question appears.

Once the survey is complete, the results are uploaded to the Survey Reporter via a Palm

Pilot Internet Connection. Uploading and viewing results varies depending on the type of

the survey (Palm, Internet, or Phone). After the results imported into the Internet based

Survey Reporter Application, you can ask for the results.

This system meets many of the requirements of the proposed system. You can

create your own questionnaire with this system. Since it executes on the Palm OS, it is a









cost-effective solution. The problem with this system is that you have to use the Survey

Reporter to view the results. Someone then has to either enter the data into the database

manually, which is error prone, or build another application that enters the data into the

database. So, this system by itself cannot be deployed to a medical waiting room.

Tripod Data Systems Survey Pro for Pocket PC (TDS)

Survey Pro (TDS) runs in the Windows CE environment and supports different

styles of surveys.4 This system supplies its own soft keyboard (SIP), which has larger

keys than the iPAQ version. There are two TDS SIPs: one for numbers and one for

letters, which provide a convenient way to enter the numbers and characters commonly

used in surveys. Shortcuts are provided for certain tasks. For example, when actually

starting the application all you need to do is press the key: the big silver button located at

the bottom of the iPAQ. You are then prompted to enter a description for the survey. You

can choose from the earlier descriptions or define a new one. Certain steps need to be

followed to create a new description and through these steps TDS provides a way to

design your own questionnaire. Survey Pro supports description files and remembers the

last one used, if you are going to use the same description. Survey Pro ships with Survey

Link, a program used to transfer data from the iPAQ to a PC. Survey Link also has a

number of conversion routines used to convert between TDS *.JOB files and other

formats naive to a number of other popular software packages.

Although this system provides ways to create your own questionnaire, it does not

completely automate the process of data entry. After collecting the data, someone again

has to synchronize it to the desktop PC to receive the results. Moreover this questionnaire

system is not dynamic (i.e., the next question does not depend on the answer of the last









question). Therefore, this system does not meet all the requirements of the proposed

system.

PalmQues

Designed by Ryan Donahue, PalmQues runs on the Palm OS and was specially

designed to replace the paper-based questionnaire in the medical waiting rooms.5

PalmQues has three components: Editor, Synchronizer, and Mobile Presenter. PalmQues

assists the questionnaire designer in creating or editing a questionnaire definition. The

questionnaire definition is saved to the receptionist's desktop. When a patient arrives, the

receptionist enters the patient's identification, connects a Palm OS device to the desktop,

and informs PalmQues to synchronize with the device. At this point, PalmQues checks

the device for results from a previous session. If none are present, it sends the

questionnaire definition along with the patient identification to the Palm OS device. Once

this is complete, the receptionist hands the device to the patient. The patient selects

answers for each question and, once the questionnaire is completed, returns the Palm OS

device to the receptionist. The receptionist again connects the Palm OS device and the

desktop and synchronizes PalmQues. This time PalmQues finds results on the device and

downloads them to the desktop, where they are automatically stored in the appropriate

database.

Although this system was designed specially for medical waiting rooms, it does not

completely automate the process of data entry. Someone has to synchronize the handheld

PC to the desktop PC to download the questionnaire. After collecting the data, someone

has to again synchronize it to the desktop PC to receive the results. This system is not

dynamic; the questionnaire definition must be downloaded before the start of the









questionnaire by synchronizing the Palm with the desktop PC. Therefore, this system

does not meet all the requirements of the proposed system.

Professional Quest

Dipolar describes Professional Quest as the most flexible and powerful

questionnaire and survey creation program available.6 It contains tools for creating,

answering, and analyzing survey data. Professional Quest creates both structured and

form-based questionnaires. It features a flexible visual designer, powerful reporting, and

a range of statistical graph types. Professional Quest provides over 50 questionnaire

templates, a question library, and questionnaire layout themes. It also includes a survey

web site builder tool, which allows you to create a complete, web-based interface for

your survey, including the ability to add, edit, delete, and view responses online. This

system can be deployed in various ways including paper, HTML questionnaire forms via

Email, HTML questionnaires on the Web or Intranet, and floppy-diskette questionnaires.

This system does not enter the data into the existing database. Therefore, someone

has to either manually enter the data or build another application that enters the data into

the database. So, this system by itself cannot be used in medical waiting rooms.

Moreover, this system runs only on a desktop PC. To deploy this system in medical

waiting rooms, these rooms will have to be equipped with desktop PCs; therefore this

system is not cost-effective.

SurveyMate

Created by ThinkingBytes SurveyMate is an electronic questionnaire/quiz system

that runs on Palm OS.7 It can handle single answers, multiple answers, essay-type, and

conditional questions. To use this system, you create a word document on a desktop PC

or as a memo in your Palm's memo pad application, then type in the questions according









to the format suggested by SurveyMate. This word document or memo questionnaire is

downloaded to SurveyMate when it starts. After a series of interviews, you can view the

results within the application on Palm either as a count, percent, or bar graph.

This system succeeds in meeting two of the requirements of the proposed system. It

provides a way to create your own questionnaire. This system runs on Palm OS and thus

it is a cost effective solution that could replace paper-based questionnaires in the medical

waiting rooms. The shortcomings of this system are that it does not provide a way to

enter to data into the database, and the results can only be viewed as a count, percent, or

graph, so this system cannot collect the data specific to a particular user.

ScreenSurvey

Developed by the National Research Council of Canada, ScreenSurvey is a

software to automatically administer on-screen questionnaires.8 Questions in this system

are designed using the custom "Form Builder" software. The Form Builder allows

complete flexibility in placing the items on the question form, their size, and their color.

This system features different response types to a question. Once created, the questions

can be administered in any order. Any number of questions may be asked with any

frequency. Specific questions can be defined as "demographic," which are asked only

once since the answers would not be expected to change over time. The answers to the

demographic questions can be used to decide which questions are subsequently asked.

For example, if a user is a female, she would not subsequently be asked to complete a

checklist that applies to males, but instead would be asked to complete a checklist that

applied to females. The responses to the questions are stored on the host computer's hard

disk for collection at the end of the study.









This system succeeds in giving the flexibility to create the questionnaire. It is a

dynamic system in which the answer to a question dictates the subsequent questions to be

asked from the user. It is not clear how the results are stored in this system and whether

the results of the specific user can be viewed or not. Moreover, this system runs on a

Windows computer and therefore is not a cost-effective solution for waiting rooms.

Chapter Summary

This chapter described existing questionnaire systems. All of the above systems

have been successful in fulfilling some of the requirements of the proposed system, but

none of them meets all the requirements. MDC is a system that is designed to meet all the

requirements of the proposed system. The next four chapters discuss the design, features,

and different components of the MDC system.














CHAPTER 3
FEATURES AND DESIGN OF MDC

As discussed in the last chapter, existing systems have not been able to replace the

paper based questionnaire system in medical waiting rooms. This chapter describes the

features and design of MDC. Before discussing the features of MDC, we need to know

the process involved in the paper based questionnaires.

Paper-based Method of Data Collection

The paper-based method is the traditional method of data collection. Figure 3.1

shows its data flow. A doctor or the administrator creates/edits the questions. Once he is

done writing the questions to be asked by the respondent, those questions are printed on a

paper. These printed paper questionnaires then go to the receptionist who gives these

questionnaires to the respondents. Respondents then complete the paper questionnaire

and return it to the receptionist. To utilize the data collected, they have to be entered into

an existing database.

As described in Chapter 1, this method of data collection is very inefficient. Paper

based questionnaires are static (i.e., the answer of a question does not dictate the

subsequent questions to be asked from the respondent). The editing of these paper based

questionnaires is very time consuming and requires the entire process of questionnaire

creation to be repeated.








































Figure 3.1 Data Flow in Paper based Questionnaires

If the questionnaire contains some questions that are specific to some group of

respondents then the layout of the questionnaire can become very complex for the

respondents. For example, if there are some questions specific to male respondents, then

female respondents do not need to answer these questions and they have to skip these

questions, going to some other part of the questionnaire. Quite often this is not very

intuitive for the respondents and leads to confusion. To utilize the collected data, it needs

to be manually entered into the existing databases. Manual data entry is error-prone and

adds to the inefficiency of the system in terms of delays and errors. In addition, there is









the possibility that the receptionist could loose the completed questionnaires. MDC is

designed to overcome the shortcomings of paper based questionnaire system. The rest of

the chapter describes the MDC system in detail.

Mobile Data Collection System for Pocket PC

MDC is an electronic questionnaire system that meets all the requirements of the

proposed solution to the medical waiting rooms problem. Figure 3.2 shows MDC's data

flow.






Questionnaire Receptionist
Editing
Pocket PC

Respondent


Data

Database




Figure 3.2 Data Flow in the MDC

A doctor or administrator remotely creates/edits the questions to be answered by

the respondents. Once the questionnaire is ready, the receptionist starts MDC on the

Pocket PC. MDC requests the demographic information of the respondents which

includes Name, SSN, Sex, and Age as shown in Figure 3.3. The receptionist or nurse

completes this information and submits it to the database. MDC downloads the subset of

all the questions from the database according to the demographic information submitted









and wirelessly sends the first question to the Pocket PC to be displayed on the screen.

The receptionist now gives the Pocket PC to the respondent. The respondent answers

each questions by clicking on one of the displayed answers. A typical question is shown

in Figure 3.4. At any time, he/she can go back to the previous question and change the

previously entered answer. The progress of the respondent in completing the

questionnaire is shown at the bottom of the screen. Once the respondent has answered all

the questions, MDC shows a Finish screen as shown in Figure 3.5.



Welcome to the Mobile
Data Collection System
Please enter your information
SSN

First Name

Last Name

Sex (M/F)

Age

Submit




Figure 3.3 Demographic Information Screen

As soon as the respondent finishes the questionnaire, the results are submitted to

the database. MDC provides a simple way to create/edit the questionnaire, an intuitive

layout to the respondents, elimination of the errors/delays that occur due to manual data

entry of the collected data, and provision of a dynamic way of asking questions from the

respondents. All these have been achieved by three different components of the MDC:

the MDC proxy, the MDC server, and the MDC client. These components are explained









in detail in Chapters 4, Chapter 5, and Chapter 6, respectively. Figure 3.6 shows the data

flow between the three components of MDC.



Do you have fever?

O Yes

O No

Q Not sure





1Bk xt

0 % Progress Bar 100 %

Figure 3.4 Sample Question within the Questionnaire

The flow of information between the three system components is as follows. First,

the Client sends a request to the Proxy. The Proxy queries the Server, and Server writes

the result of the query on an Html page and returns it to the Proxy. The Proxy then sends

that Html page to the HTML Parser, which parses the data on the Html page and builds

an object of the Hash Table containing all the relevant information. This Hash Table

object is then sent to the Proxy. The Proxy extracts the data from the Hash Table and

sends the response back to the Client.















Thanks for using
the Questionaire
System.


Press Back
to go back,

Back


Press Finish
to end the
Application.
Finirh


Figure 3.5 Finish Screen

Questions and Their Types

The questions' database has been designed in MS Access. Two types of questions

are used in this system:

* Normal (n): A normal question is a question whose answer does not change the
subsequent questions to be answered by the respondent.

* Critical (c): The answer to a Critical question dictates the subsequent questions to
be answered by the respondent. If the answer to a critical question is equal to the
trigger answer then some follow-up questions need to be asked. These follow-up
questions can also be of the type Normal or Critical. Every critical question has an
associated follow number. This follow number is the number of follow-up
questions to be asked.

Figure 3.7 shows the General Questions Table of the database. Every record of this

table is a question and every question has following attributes:

* QId: Question ID of the question. This ID is important because it identifies the
order of the questions to be asked. For Example: If the Q_Id of a question is 10,
then this question will be asked after the respondent has answered the first nine
questions.
















Request


Response


HTML
Page


HASH
Table


Figure 3.6 Mobile Questionnaire component data flow

* Q_String: This is the Question itself. For Example: Do you have fever?

* Q_Type: Normal, Critical or Follow.

* Q_Trigger: If the question is a Critical question, then this is the Trigger answer of
the question; otherwise, this value is null.

* QFollow: If the question is a critical question, then this is the number of follow-up
questions; otherwise, this value is 0.

* Ansi, Ans2, Ans3, Ans4, Ans5: Five fields for five possible answers to a question,
which are specified by the person designing the questionnaire.

Creation / Editing of the Questionnaire

MDC provides a very simple way to create/edit the questionnaire. Figure 3.7 shows

the General Questions Table of the database. MDC has an already designed database that

has some tables with no records. If you want to create the Questionnaire, all you must do


Query


Result










is add a record in the table for each question. Every record is a question with the

attributes defined in the last section. Once you are done adding records in the table, you

can start using MDC on the Pocket PC for the data collection.


_Id Q_String Q_Type Q_Trgger Q_Follow No_Ars Ansi Ans2 Ans3 Ais4 Ans5.
) 1 Do you have headache? n 0 3 Yes No Not sure Null Nulli

2 Are you fatigued? n 0 3 Yes No Not sure Null Null

3 Do /ou have fever? c Yes 4 3 Yes No Not sure Null Null

4 Are you Nauseatic? n 0 3 A lot A little No Null Null

5 Are you Drowsy? n 0 4 A lot A little Not sure No Null

6 Do ,ou have cough? n 0 2 Yes No Null Null Null

7 Do ,ou have sore throat? n 0 2 Yes No Null Null Null

none none none none none 0 none none none none none

0
-_a
Record: HIII 4 F of S

Figure 3.7 General Questions Table

If you want to edit or update the questionnaire, all you must do is click on the fields

of the question that you want to edit and make the necessary changes. Once you save the

changes, MDC accepts those changes. The next time you start the application on the

Pocket PC, it will display the updated questionnaire. In this way the creation and editing

of the questionnaire becomes very simple.

Questionnaire Layout

One of the problems with the paper based questionnaire is that the layout becomes

very complex if there are many questions in the questionnaire. This can become very

confusing for the respondents. MDC has overcome this shortcoming by providing a very

simple and intuitive layout of the questionnaire. Figure 3.4 shows a typical question to be

answered by the respondent. Only one question is asked on each screen, reducing the









complexity for the respondents. The respondent answers the question with just a single

click on the screen.

Dynamic Questionnaire System

MDC is a dynamic questionnaire system (i.e., the answer of a question decides the

subsequent questions to be asked from the respondents). It provides a way of asking only

the relevant questions from the respondent, making this system a very efficient data

collection system. This is achieved by a wireless connection between MDC and the

database. When the respondent answers a question, the application sends a query to MDC

proxy. The Proxy checks to see if the answered question was a critical question. If it is a

not a critical question, it simply picks up the next question in the sequence and sends it to

the MDC. If it was a critical solution, then it checks to see if the respondent has triggered

the critical question. The answer to the critical question dictates the subsequent questions

to be asked from the respondent as shown in the Figures 3.8, 3.9, and 3.10.

Figure 3.8 shows a critical question on the Pocket PC. The trigger answer of this

critical question is "Yes." If the respondent selects "Yes" and clicks the next button, the

result is shown in Figure 3.9. The progress bar shows the increased progress towards

completion compared to the one in Figure 3.8. This progress is achieved by answering a

single question.

The question shown in Figure 3.9 is a follow-up question that is to be asked from

the respondent. If the respondent selects any other answer in Figure 3.8 except "Yes" and

clicks the Next button, the result is shown in Figure 3.10. In this case, the respondent has

not triggered the critical question and, therefore, MDC has skipped all the follow-up

questions because the respondent does not need to answer them now. As a result, the

progress bar is showing more progress as compared to the one in Figure 3.9. So, in a way









the respondent has in effect answered more than one question by not triggering the

critical question. The number of questions that are skipped determines the amount of

change in the progress bar.



Do you have fever?

O Yes

O No

0 Not sure





IBack Next


0 % Progress Bar 100 %

Figure 3.8 Critical Question

MDC thus executes in a dynamic manner by asking only relevant questions. Only

one question is asked on one screen and the next question is selected based on the

response to the current question. Respondents do not need to skip the questions

themselves, which makes MDC very user-friendly.

Design Issues

Platform

Visual Studio .NET with Smart Device Extensions (SDE) was selected to develop

this application. Visual Studio .NET 9 is a unified development environment, which

enables applications to be developed for mobile devices. Smart device extensions 10 are









specifically targeted towards development for the mobile devices. It includes the

templates for Pocket PC and Windows CE based application.

The MDC client application was developed using Visual C# 1 because it is a very

powerful language for making applications involving Graphical User Interface and

network programming. The MDC proxy application was developed using Java 12 because

it is platform independent and can execute on any environment. The database for the

MDC was designed using MS Access because of its simplicity of use and its capability to

interact effectively with Java Servlets 13



Are you Nauseatic?

OA lot

0 A little

O No





Back Next


0 % Progress Bar 100 %

Figure 3.9 After triggering the Critical Question

Connecting to the Database

MDC can work with any database that is compatible with Java Database

Connectivity (JDBC). JDBC is an API that provides access to any tabular data source

from the Java programming language. JDBC API provides the advantages of Java

Platform's "Write once and Run Anywhere." JDBC was designed to simplify









development tasks. It makes database tasks like Select, Insert, etc. very simple and

provides cross-DBMS connectivity to a wide range of SQL databases. JDBC API

provides access to other tabular data sources, such as spreadsheets.



Do you have pain in neck?

O Yes

O No

0 Not Sure





IBack Next


0 % Progress Bar 100 %

Figure 3.10 Without triggering the Critical Question

JDBC is compatible with many databases like: ADABAS, ALLBASE SQL,

BASIS, CA-IDMS, Cache, Centura SQLBase, CISAM, Clipper, Cloudscape, CodeBase,

DABroker, DafodilDB, Datacom, DataFlex, dBase, DBMaker, DL/I, DMSII, Domin,

Empress RDBMS, Enscribe, Essentia, FoxPro, FrontBase, IBM AS/400, IDMS,

ImageSQL, IMS, Informix, Ingres, InstantDB, InterBase, JDataStore, kdp, LDAP,

MUMPS, Mimer SQL, MS Access, MS SQL Server, mSQL, MySQL, NewsServer,

Nonstop SQL/MP, OpenBase, Oracle, and many more.

Data Entry

Hospitals are shifting to a wireless infrastructure, providing one reason why

wireless was chosen as the medium of data entry. Data entry is done automatically when









the respondent finishes the questionnaire on the Pocket PC. A wireless connection is

established between the MDC and the database. Wireless data entry eliminates the need

of error-prone manual data entry into the database and also eliminates the need of

synchronizing the device to the desktop PC. There were two choices for wireless data

entry:

* One answer at one time.
* All the answers of one respondent at one time.

When the respondent answers a question, MDC sends the answer to the MDC

proxy. The Proxy does some processing and sends the next question to the MDC. This

answer could have been added to the database at this time. But, the respondents have

been given the flexibility to go back and change any answer if they like and this would

lead to many temporary results stored in the database. So, if a respondent changes

answers frequently, this choice of data entry would lead to a very inefficient system that

continually changes and updates the database. Moreover, this would lead to many

interactions with the database, which is time consuming and can lead to delays. The

second choice, hence, leads to less database interaction by storing only the final answers

submitted by the respondents. Therefore, the second choice of data entry was selected.

Chapter Summary

This chapter discussed the design issues and features of MDC. MDC has a very

simple and intuitive layout, and it is dynamic. It uses JDBC for database connectivity,

which makes it compatible with a large number of database products. All these features

makes MDC it a very efficient system of data collection.














CHAPTER 4
MDC PROXY

MDC is a client-server application. Respondent data is collected by the Client,

which has to be submitted to the Server. For effective communication between these two

modules, an interface is required. This is achieved by implementing the MDC proxy.

The Proxy serves as an interface between the Client and the Server performing various

functions:

* Receiving the request from the client,
* Querying the server according to the received request,
* Receiving the results of the query from the server, and
* Sending the "Response" packet back to the Client.

The Proxy decides the next question to be sent to the Client depending upon the

answer of the previous question. Once the MDC proxy starts, it opens a Datagram socket

and receives the packets from the Client. Example packets are shown in Table 4.1.


Table 4.1 Different Types of Packets from the MDC client
Info Packet Info#123456789#Chris#Jackson#M#24

Next Packet Next#6#No

Back Packet Back#9#Yes

Finish Packet Finish#









These received packets are one of the following four types:

* Info Packet,
* Next Packet,
* Back Packet, and
* Finish Packet.

Info Packet

If the first field of the packet is "Info," it identifies that the user has just completed

the personal information. This packet is shown in Table 4.1 and contains the following

information of the respondent:

* SSN,
* First name,
* Last Name,
* Sex, and
* Age.

The Proxy extracts all this information from the packet and creates a connection

with the Server using the HttpURLConnection class available in Java. The Proxy then

writes a query to the GetInformation HTML page of the Server to insert a record

containing the personal information of the respondent in the P_Info table of the database

(the database details are discussed in Chapter 5). This is done using the

setRequestMethod ("Post") method of the HttpURLConnection class. The MDC server

inserts the record in the PInfo table, then retrieves and writes all the questions to an

HTML page with each question's information on a line as shown in Figure 4.1. The

MDC server is discussed in Chapter 5.











File Edit View Favorites Tools Help
SBack ,T Mj f aI search GFavorites Fjr.-.iji. (E| Ij% >
Address C:\tomcat\webapps\GetInformation\getinfor.html j IGo Links


1#Do you have headache?#n#null#0#3#Yes#No#Not sure#Null#Null
2#Are you fatigued?#n#null#0#3#Yes#No#Not sure#Null#Null
3#Do you have fever?#c#Yes#4#3#Yes#No#Not sure#Null#Null
4#Are you Nauseatic?#n#null#0#4#A lot#A little#No#Not sure#Null
5#Are you Drowsy?#n#null#O#4#A lot#A little#No#Not sure#Null
6#Do you have cough?#n#null#0#3#Yes#No#Not sure#Null#Null
7#Do you have sore throat?#n#null#0#3#Yes#No#Not sure#Null#Null
8#Do you have pain in neck?#n#null#0#3#Yes#No#Not Sure#Null#Null
9#Do you have painful urnation?#n#null#0#3#Yes#No#Not sure#Null#Null




1SJ Done 7 1 My Computer '

Figure 4.1 HTML Page with the Questions' Details passed to the Proxy by the MDC
server

Every line in Figure 4.1 has complete details of one question. The first field of

every line is the QuestionId, second is the question to be answered, third is the type of

the question as described in Chapter 3, fourth is the Answer Trigger, fifth is the number

of follow questions to be asked, sixth is the number of answer choices, and the rest five

are the five answer choices to the question. The HTML class is written to parse all the

data written by the MDC server and performs the following functions:

* Reads the HTML page line by line,
* Extracts all the information about each question,
* Makes an instance of the Question class, and
* Inserts the instance into a Hash Table with its Key equal to the QuestionId.

Since the Questions in the questionnaire may be accessed several times for editing

or retrieving purpose, a Hash Table has been designed to store the instances of the









questions to minimize the complexity of data access. The Proxy then calls the getString

method of the HTML class, which returns the instance of the Hash Table class containing

all the Question objects. In this way, Proxy retrieves all the questions from the database

as a result of a single query and hence avoids the need of multiple queries. Next, the

Proxy retrieves the Question object at the key location "1" and prepares a "Response"

packet according to the information in this Question object. The "Response" packet is

shown in Table 4.2 and it contains information about the next question: the QuestionId,

the Total number of Questions, the Question String, and the answer if already selected or

null otherwise. After the "Response" packet has been prepared, the Proxy sends this

packet to the MDC client. The MDC client extracts the question information from this

packet and displays the question on the Pocket PC. The MDC client is discussed in

Chapter 6.


Table 4.2 Response packet sent to the MDC client
Response Packet 3#1#12#Are you Allergic?#null#Yes#No#Not Sure#null#null


Next Packet

If the first field of the packet is "Next," the user has answered a question from the

questionnaire. This Packet is shown in Table 4.1 and contains information about the

question answered including the QuestionId and the answer selected. Depending on the

answer selected, the Proxy must decide which is the next question to be asked.

There are three types of questions: Normal, Critical, and Follow. If the answered

question is of type Normal or Follow, then the next question has a Key equal to

QuestionId + 1. Critical questions are triggered by a particular answer. If the answer to

the Critical question is equal to the "Trigger answer," then the follow-up questions are









asked, otherwise the follow-up questions are skipped and the subsequent question is

asked. So, if an answer is a "Trigger answer," then the next question's Key equals

QuestionId + 1. If not, then the next question has a Key equal to QuestionId + Follow

number + 1.

If this calculated position is greater than the number of questions in the Hash Table,

then the "Response" Packet is set to "Finish." Otherwise, the MDC proxy receives the

Question object at the calculated Key location and prepares a "Response" packet

according to the information in this Question instance. After the "Response" packet has

been prepared, the Proxy sends this packet to the MDC client.

Back Packet

If the first field of the packet is "Back," the user has clicked the "Back" button on

the Client Application. This packet is shown in Table 4.1 and contains information about

the current question on the Client like QuestionId and the answer selected, if any. The

Proxy then must select the previous question that was answered by the respondent.

The previously answered question does not have a null answer because this was a

question previously answered. The Proxy retrieves this question from the database subset,

which it received as a result of the query to the Server, using a Key equal to QuestionId

- 1. Using this key, it checks whether the answer to the previous question in the database

subset is null or not. If the answer is null, then the Proxy again gets a question with the

Key equal to this QuestionId 1. This process continues until the Proxy finds an

answered question. This is the previous question that was answered by the respondent.

The "Response" packet is then created using the information in this Question instance.

After the "Response" packet has been prepared, the Proxy sends this packet to the MDC

client.









Finish Packet

If the first field of the packet is "Finish," the respondent has answered all the

questions and has clicked the "Finish" button on the FinishForm. This packet is shown in

Table 4.1 and contains no more information. The Proxy keeps all the answers submitted

by the respondent until the end of the questionnaire. Finish packet signifies the end of the

questionnaire. After the Proxy receives this packet, it must submit all the answers to the

Server.

The Proxy retrieves each question from the Hash Table and checks whether the

answer is null or not. If an answer is null, then it means that its corresponding question

was not asked in the questionnaire as it was a follow-up question to a critical question. In

this case, the proxy skips to the next question. If not, then it creates a connection with the

Server using the HttpURLConnection class. The Proxy writes a query to the Server to

insert the records in the Results table of the database. This is done using the

setRequestMethod ("Post") method of the HttpURLConnection class. Finally, the

"Response" packet is set to "Your answers have been added to the Database."

Once the "Response" packet has been prepared, the Proxy opens another Datagram

Socket and sends the packet to the Client Application so this final message is displayed to

the respondent.

Chapter Summary

The function of the Proxy is to provide an efficient communication interface

between the MDC client and the Server. The HTML class has been implemented for

parsing the HTML page produced by the MDC server as a result of the query. The Proxy

retrieves all the questions from the database; therefore, multiple queries to retrieve the

questions are not needed. The Proxy keeps all the answers submitted by the respondent






31


until the end of the questionnaire; therefore, only final answers are submitted to the MDC

server. The next Chapter discusses the MDC server.














CHAPTER 5
MDC SERVER

The MDC server is the second module in this application. It holds the archive of

questions and is responsible for providing the subset of these questions based upon the

demographic information submitted by the respondent. It performs the following

functions:

* Archives the questions and their details,
* Responds to the queries from the MDC proxy,
* Stores the respondent's demographic information, and
* Stores the respondent data.

MDC server Components

The MDC server consists of a database and two web applications: GetInformation

and AddResults. Figure 5.1 shows the interaction between these components of the MDC

server. The MDC proxy writes a query on the GetInformation HTML Page to retrieve all

the questions from the database. The GetInformation Servlet is associated with the

GetInformation HTML page and performs the following functions:

* Queries the database to select all the questions,
* Receives the results, and
* Writes the result on another HTML Page, which is shown in Figure 4.2.

The MDC proxy writes another query on the AddResults HTML Page to submit the

answers of the respondents to the database. The AddResults Servlet is associated with the

AddResults HTML Page and queries the database to insert the answer. Each component

in the MDC server performs a pivotal operation to respond to the queries of the MDC

proxy.









Database


The MDC database has the following tables:

* P_Info: This table contains the demographic information for all respondents. Each
respondent has a single record in this table containing the following information:

FName, the first name of the respondent,
LName, the last name of the respondent,
SSN, the respondent's Social Security Number,
Sex, the sex of the respondent, and
Age, the respondent's age.

* General_Q: This table contains general questions to be answered by the respondent.
Every record is a question having the following properties:

Question_ Id, the question's Id,

Question Name, the question string,

Question Type, the value "Normal," "Critical," or "Follow,"

Question Trigger, the "'Trigger answer" if it is a Critical question and null
otherwise,

Question Follow Number, the number of follow up questions if it is a critical
question and null otherwise,

NoAns, the number of answer choices to the question, and

Five answer fields, the five possible answers to a question.

* Male_Q: This table contains questions to be answered by male respondents. Every
record is a question having the same properties as the General_Q table.

* Female_Q: This table contains questions to be answered by female respondents.
Every record is a question having the same properties as the General_Q table.

* Results: This table contains the answers given by the respondents. Every record in
this table is an answer given by a respondent to a particular question. Each record
has the following fields:

SSN, the Social Security Number of the respondent,
QuestionId, the Id of the question, and
Answer, the answer selected by the respondent.









































Figure 5.1 MDC server component data flow

The Questions in this questionnaire system are not hard coded, but rather can be

easily changed by modifying the values in the three question tables. Also, adding records

to the appropriate table in the database extends the questions to be asked. In this way, this

application provides a method to edit or extend the questionnaire, allowing the

questionnaire to provide a broad range of questions for a complete understanding the

patient's medical history.









GetInformation

GetInformation has been designed for entering the respondent's demographic

information into the database and to retrieve all the questions from the Questions archive

based upon that information. Its functionality is achieved through the following modules:

* GetInformation HTML page and
* GetInformation Java Servlet.

The GetInformation HTML page has five text boxes, which are used to obtain the

respondent's demographic information. A "Submit Query" button has been placed at the

bottom of this page as shown in Figure 5.2. This HTML page has the following five text

boxes:

* SSN,
* First Name,
* Last Name,
* Sex, and
* Age.

The MDC proxy establishes an HTTPConnection with this HTML page and writes

a query using the "setRequestMethod("POST")" method. This query contains the

information for these five text boxes and is submitted to the database by the associated

GetInformation Servlet.

The GetInformation Java Servlet uses the contents of these five text boxes to

prepare the Insert query. The query used is "insert into P_Info

(FName,LName,SSN,Sex,Age) values namem, Iname, ssn, sex, age)." After this query is

executed, the respondent's demographic information is entered into the P_Info table of

the database. Depending upon the sex of the respondent, this Servlet prepares a Select

query, which retrieves all of the questions from the appropriate two tables in the database.

General_Q table is always used in this query, while the second table is either Male_Q or









Female_Q depending upon the sex of the respondent. The query used is either "select *

from General_Q,Male_Q" or "select from General_Q,Female_Q." The Servlet displays

all the extracted questions on an HTML page, which is passed to the MDC proxy. The

Proxy sends this HTML page to the HTML Parser, which is responsible for reading the

questions and inserting them into the Hash Table.


I r ... .. I i.. |


I_. xI


File Edit View Favorites Tools Help
4 Back 4 i, f- |F search Favorites Fr-ir e.j:l >>
Address |I Cl:rtomcat\webapps\GetInFormation\GetInormat Go Links >>

Get all the Questions

Social Security Number:
First Name: F
Last Name:
Sex (M/F):
Age: I
Submit Query



SDone I I My Computer

Figure 5.2 GetInformation HTML Page

AddResults

AddResults has been designed to enter the respondent's answers into the database.

This is achieved through the following modules:

* AddResults HTML page and
* AddResults Java Servlet.


IL7111C;IL~~IIIII:C~IIIL7;1L~I;ICIYII~









The AddResults HTML page has three text boxes, which are used to obtain the

respondents' answer to a question. A "Submit Query" button has been placed at the

bottom of this page as shown in Figure 5.3. This HTML page has the following three text

boxes:

* SSN,
* Question Id, and
* Answer.


I- ILl 1 1: I I I H l-up -' e r- l I MIl -, =i,


-JQJj


File Edit View Favorites Tools Help
Back 41 -,1 [M fl I |, search [ Favorites FaPr li-eiI
Address | C:\tomcat\webapps\Addresults\Addresults.html j PGo Links >

Submit the Answer

Social Security Number:
Question Number:
Answer:

Submit Query



-I
SDone I My Computer

Figure 5.3 AddResults HTML Page

The MDC proxy establishes an HTTPConnection with this HTML page and writes

the query using the "setRequestMethod("POST")" method. This query contains the

information for these three text boxes and is submitted to the database by the AddResults

Servlet associated with this HTML page.

The AddResults Java Servlet uses the contents of these three text boxes to prepare

the Insert query. The query used is "insert into Results (SSN, Q_Id, Ans) values (ssn,









q_id, ans)." After this query is executed, the respondent's answer is entered into the

Results table of the database.

Chapter Summary

The MDC server provides an archive of questions for the application and allows

different operations to insert information in and extract information from its database.

The database has various Tables, which provide a subset of questions from the questions'

archive to the MDC proxy for conducting the questionnaire. The GetInformation and

AddResults modules of the Server render wireless accessibility for these operations. The

next Chapter discusses MDC client.














CHAPTER 6
MDC CLIENT

The MDC client runs on a Pocket PC and provides the respondent interface. It is an

electronic substitute for the paper-based method of data collection. It displays one

question at a time and has a very intuitive layout. Through its respondent-friendly

graphical interface, it provides simplicity of use and efficiency in data collection. This

application is implemented using four different forms, which are designed to display the

information and the instructions for the respondents. The various forms are:

* MainForm, which collects the demographic information of the respondent,
* QuestionlForm, which presents the details of the first question,
* Question2Form, which presents the remaining questions, and
* FinishForm, which indicates the completion of the questionnaire.

MainForm

The application starts with the MainForm as shown in Figure 6.1. This form requests

personal information of the respondent like SSN, First Name, Last Name, etc. Textboxes

are used to collect the respondent data. Once the respondent has provided the

information, he can submit it by pressing the submit button at the bottom of the form. If

all the required information is not provided, the application displays a pop up message

box asking the respondent to fill out the desired information, as shown in Figure 6.2.

After the respondent has provided the requested information and clicked the submit

button, the application prepares an "Info" Datagram packet to be sent to the MDC proxy

as shown in Table 4.1. The "SendRec" method is responsible for sending and receiving

the datagram packets between the MDC client and MDC proxy. This method is described









in the last section of this Chapter. After the packet has been sent to the MDC proxy, the

Client waits for the "Response" packet.



Welcome to the Mobile
Data Collection System
Please enter your information
SSN

First Name

Last Name

Sex (M/F)

Age

Submit




Figure 6.1 MainForm

The "Response" packet as shown in Table 4.2 contains the following information

for the first question in the questionnaire:

* NoAns, which is the number of answer choices to the first question,

* QuestionId, which is the Id of the question in the database,

* TotalQues, which identifies the total number of questions in the questionnaire,

* Question String, which is the question being posed to the respondent,

* Answer, which is a null string, and

* Ansi, Ans2, Ans3, Ans4, Ans5, which are the five answer choices to the first
question. These answers are displayed on the Pocket PC as different radio buttons.

All five answer choices are not displayed all the time and which are displayed

depends on the value of NoAns. For example: If the NoAns is 3, then only Ansi, Ans2

and Ans3 are displayed as possible answer choices as shown in Figure 6.3.











Welcome to the Mobile
Data Collection System
Please enter your information


O Please Enter Your Age



Sex (M/F)

Age

Submit




Figure 6.2 Pop up Message

When the Client receives the "Response" packet from the MDC proxy, it creates an

instance of the QuestionlForm by passing the question information to its constructor. The

Client then calls the "ShowDialog" method of the QuestionlForm class, which displays

the form on the Pocket PC.

QuestionlForm

The QuestionlForm contains a Textbox for displaying the question to be asked. See

Figure 6.3. This form also has various Radio buttons for different answer choices. A

"Next" button and a Progress Bar are placed at the bottom of this form. The Progress Bar

displays the respondent's progress through the questionnaire. It uses the value of

TotalQues and the question number to display the respondent's progress through the

questionnaire. If the respondent clicks the "Next" button without answering the question,

the application displays a pop up message box prompting the respondent to answer the

question.












Do you have headache?

O Yes

O No

O Not sure





I ext I
Next


0 % Progress Bar 100 %

Figure 6.3 QuestionlForm

Once the respondent clicks the "Next" button after answering the question, the

application prepares a "Next" Datagram packet as shown in Table 4.1. This packet

contains the Id of the question displayed on the Pocket PC and the answer selected by the

respondent. The first field in the packet is "Next," which signifies that the next question

is to be selected.

Once the packet has been prepared, it is sent to the proxy, and the application waits

for a "Response" packet. The MDC proxy selects the next question to be answered by the

respondent. The answer to the previously asked question is used to determine the next

question. Proxy sends a "Response" packet as shown in Table 4.2 to the Client. When the

application receives the packet from the proxy, it creates an instance of the

Question2Form by passing the question information to its constructor. The application

then calls the ShowDialog method of the Question2Form, which displays the form on the

Pocket PC.









Question2Form

Question2Form has a Textbox for displaying the question to be asked. See Figure

6.4. This form also has various Radio Buttons for the different answer choices. "Back"

and "Next" buttons and a progress bar are present at the bottom of this form. If the

respondent clicks the "Back" button, the application prepares a "Back" Datagram packet

as shown in Table 4.1. This packet contains the Id of the question displayed on the Pocket

PC and the answer, if selected by the respondent. The first field in the packet is "Back,"

which signifies that the previous question is to be selected.

Once the packet has been prepared, it is sent to the proxy and the application waits

for the "Response" packet. The MDC proxy locates the previous question asked. The

Proxy returns a "Response" packet to the Client containing the information of the

previous question. The MDC client displays this previous question as well as the answer

that had been selected.



Do you have pain in neck?

0 Yes

O No

0 Not Sure





Back Next


0 % Progress Bar 100 %


Figure 6.4 Question2Form









If the respondent clicks the "Next" button on Question2Form without answering

the question, the application displays a pop up message box asking the respondent to

answer the question. After answering the question, if the respondent clicks the "Next"

button, the application prepares a "Next" Datagram packet as shown in Table 4.1. This

packet contains the Id of the question displayed on the Pocket PC and the answer selected

by the respondent. The first field in the packet is "Next," which signifies that the next

question is to be selected.

Once the packet has been prepared, it is sent to the proxy and the application waits

for the "Response" packet. This process continues until there are no more questions in the

questionnaire. At this time, the proxy responds with a packet containing "Finish" string.

When the application receives this packet from the proxy, it creates an instance of the

FinishForm. The QuestionId of the question currently displayed on the Pocket PC and

the answer selected by the respondent are passed to the FinishForm. This is the last

question which was asked from the respondent. The application then calls the

ShowDialog method of the FinishForm, which displays the FinishForm on the Pocket PC.

FinishForm

The FinishForm, shown in Figure 6.5, has "Back" and "Finish" buttons. If the

respondent clicks the "Back" button, a packet as shown in Table 4.1 is prepared and sent

to the MDC proxy. In this case, the Proxy sends the "Response" packet like the one

shown in Table 4.2. This packet contains the information about the previous question,

which is displayed by calling the ShowDialog method of the Question2Form. If the

respondent clicks the "Finish" button, a packet containing the "Finish" string is prepared

and sent to the MDC proxy. MDC client then calls the Close method of the FinishForm

and the MDC client on the Pocket PC closes.









SendRec

The "SendRec" method has been implemented to send and receive the datagram

packets between MDC client and MDC proxy. This method receives a string argument

containing the packet as shown in Table 4.1, creates a datagram socket, sends the packet

to the MDC proxy and receives the "Response" packet from the MDC proxy.


Figure 6.5 FinishForm

Chapter Summary

This chapter discussed the implementation aspects of the MDC client in

conjunction with the MDC proxy and Server. The various forms used for displaying the

questions have been described in detail. The communication between the Client and the

Proxy has been explained. The simple and intuitive graphical interface makes the MDC

client a very effective tool for addressing the data collection problem.


Ol~ini +E 5a:52okD


Thanks for using
the Questionaire
System.


Press Back Press Finish
to go back, to end the
Application.
Back Finish














CHAPTER 7
CONCLUSION AND FUTURE WORK

The MDC application is an electronic questionnaire system, which emulates the

paper-based method of data collection. It is a very effective system for data collection

and can be easily deployed in medical waiting rooms. Various applications developed in

the past have addressed similar issues but have not been able to replace paper-based

questionnaire in medical waiting rooms. They have neglected at least one of the

following features: the dynamic nature of the questionnaire, the ability to provide

unlimited questions in the database, wireless access to the database, and the development

of a cost-effective solution.

This application, which is developed for a Pocket PC tackles the drawbacks of the

earlier systems and uses various modules to achieve all of the above mentioned features.

The ease of use, the user-friendly interface, and its dynamic environment are instrumental

features in making this application very accessible and operational in medical waiting

rooms. Using this system, physicians can access patient information without any time

delays or possibilities of errors in collecting data. Hence, this application holds the

prospects of revolutionizing data collection techniques not only in the medical waiting

rooms but also in any environment supporting wireless accessibility.

Despite the various features implemented in this application, there are several

features which can be extended to make this application more efficient and effective. This

application uses Client-Server architecture. The MDC proxy has been implemented to

provide an interface for communication between the MDC client and the Server.









However, the Proxy can provide the interface for only one Client. Multiple Proxy

modules are required to cater to multiple Clients. This would necessitate starting a

separate Proxy module for each Client, which could result in a bottleneck. This issue can

be resolved by modifying the Proxy so it can single handedly respond to requests from

multiple Clients. This can be achieved by generating a new thread of operation at every

instance of a new Client request. This would maintain the effectiveness of the application

in a multiple Client environment.

The MDC server contains a database, which holds an archive of questions in

different tables. The Servlet queries the database according to the sex of the respondent.

This information is hard-coded in the Servlet, which makes the system rigid for any

further extensions in accessing the database tables. This issue can be resolved by passing

an informative data set to the Servlet, which would dictate the selection of the tables from

the database. This would eliminate the need for hard-coding the tables in the Servlet and

would hence, utilize the data set information as the key for accessing the tables from the

database.

Another extension to this application would be to make it platform independent.

This could be done by making the Client run on any environment. A separate module

could be written on the Client, which would recognize the operating system and

accordingly start the Client application. This modification could equip the MDC

application with "write once, run anywhere" capability. Such a feature would extend the

usability of this application and make it accessible to multi-platform environments.









The starting page of the application on the Pocket PC is currently static and always

displays the same information. Extending the system so the first page is not hard coded,

but is dynamic like all of the other pages, is another area for future extension.

At present, the application provides at most five possible answer choices and the

option to select only one answer to a given question. This style although most frequently

encountered in questionnaires, nevertheless, ignores the possibility of more than five

answer choices to a given question and selecting multiple answers to a single question.

Improving on this scheme can be performed as possible future work.

The MDC application is designed and implemented to address the electronic-based

questionnaire system problems. Several features have been incorporated to achieve the

same goals. The design aspects of this application provide the scope for extension.

Although several issues have been discussed as future work, this application is expected

to meet the requirements of the proposed system.















LIST OF REFERENCES

1. Creative Research Systems, The Survey System, Petaluma, Accessed: July 2002;
www.surveysystem.com/bro.htm

2. Pocket Survey Design Software, Questionnaire Design Software, Accessed July
2002; www.pocketsurvey.info

3. eSurvey Solutions, Inc., eSurvey Solutions, Alpharetta, Accessed: August 2002;
www.esurveysolutions.com

4. P. Gay, Survey Pro for Pocket PC, Tripod Data Systems, Corvallis, 2002.

5. R. Donahue, PalmQues, University of Florida, Gainesville, 2002.

6. Dipolar, Professional Quest Release 2.2, Sutherland, Accessed: July 2002;
www.dipolar.com.au

7. thinkingBytes, SurveyMate, Lexington, Accessed: July 2002;
www.thinkingbvtes.com/products/surveymate.asp

8. National Research Council, ScreenSurvey, Ottawa, Accessed: August 2002;
www.nrc. ca/irc/ie/light/lqproj ect/software.html

9. Microsoft Corporation, Visual Studio .NET, Redmond, Accessed: August 2002;
http://msdn.microsoft.com/vstudio/

10. Microsoft Corporation, Smart Device Extensions and .NET Compact Framework,
Redmond, Accessed: July 2002;
http://msdn.microsoft.com/vstudio/device/sdebeta.asp

11. E. Gunnerson, A Programmer's Introduction to C#, Apress, New York, 2000.

12. P. Naughton and H. Schildt, The Complete Reference, Java 2, Tata McGraw Hill,
New Delhi, 2000.

13. Sun Microsystems, Inc., Java Servlet Technology, Newark, Accessed: Jan. 2002;
http://java.sun.com/products/servlet

14. Apache Software Foundation, Apache Tomcat, Accessed: Mar. 2002;
http://jakarta.apache.org/tomcat






50


15. H. W. Griffith, Complete Guide to Symptoms, Illness and Surgery, The Body
Press/Perigee Health, New York, 1995.















BIOGRAPHICAL SKETCH

Manish Malik was born on October 6, 1979, in Panipat, India. In May of 2000 he

earned a Bachelor of Engineering degree from C R State College of Engineering where

he majored in computer science and engineering. He enrolled at the University of Florida

in August 2000 to pursue a Master of Science in computer science and will complete the

degree in December 2002.