Menu

A project report on HEART DISEASE PREDICTION SYSTEM Submitted in partial fulfilment for the award of the degree of M

February 6, 2019 0 Comment

A project report on
HEART DISEASE PREDICTION SYSTEM
Submitted in partial fulfilment for the award of the degree of
M.S SOFTWARE ENGINEERING (INTEGRATED)
By
D ARAVINDRAJ (13MSE0087)

SITE
MAR, 2018
A project report on
HEART DISEASE PREDICTION SYSTEM
Submitted in partial fulfilment for the award of the degree of
M.S SOFTWARE ENGINEERING (INTEGRATED)
By
D ARAVINDRAJ (13MSE0087)

SITE
MAR, 2018
DECLARATION
I hereby declare that the thesis entitled “HEART DISEASE PREDICTION SYSTEM” submitted by me, for the award of the degree of M.S SOFTWARE ENGINEERING (INTEGRATED) VIT is a record of bona fide work carried out by me under the supervision of Prof. MANIKANDAN N.

I further declare that the work reported in this thesis has not been submitted and will not be submitted, either in part or in full, for the award of any other degree or diploma in this institute or any other institute or university.

Place: Vellore
Date:Signature of the Candidate
CERTIFICATE

This is to certify that the thesis entitled “HEART DISEASE PREDICTION SYSTEM” submitted by D ARAVINDRAJ (13MSE0087) SITE VIT, for the award of the degree of M.S SOFTWARE ENGINEERING (INTEGRATED) is a record of bonafide work carried out by him under my supervision Prof. MANIKANDAN N.

The contents of this report have not been submitted and will not be submitted either in part or in full, for the award of any other degree or diploma in this institute or any other institute or university. The Project report fulfils the requirements and regulations of VIT and in my opinion meets the necessary standards for submission.

Signature of the guide Signature of the HOD
Internal Examiner External Examiner
ABSTRACT
The Heart Disease Prediction application is an end user support and online consultation project. Here, we propose a web application that allows users to get instant guidance on their heart disease through an intelligent system online. The application is fed with various details and the heart disease associated with those details. The application allows user to share their heart related issues. It then processes user specific details to check for various illness that could be associated with it. Here we use some intelligent data mining techniques to guess the most accurate illness that could be associated with patient’s details. Based on result, the can contact doctor accordingly for further treatment. The system allows user to view doctor’s details too. The system can be used for free heart disease consulting online.

ACKNOWLEDGEMENT
It is my pleasure to express with deep sense of gratitude to Prof. Manikandan N for his constant guidance, continual encouragement, and understanding; more than all, he taught me patience in my endeavour. My association with him is not confined to academics only, but it is a great opportunity on my part of work with an intellectual and expert in the field of Software Engineering. I would like to express my gratitude to Shri. Dr. G Viswanathan, Dr. Anand A Samuel, Dr. S Narayanan and Prof. Aswani Kumar Cherukuri, SITE, for providing with an environment to work in and for his inspiration during the tenure of the course. In jubilant mood I express ingeniously my whole-hearted thanks to Prof. Valarmathi B, HOD of Software and Systems Engineering (SITE), all teaching staff and members working as limbs of our university for their not self-centred enthusiasm coupled with timely encouragements showered on me with zeal, which prompted the acquirement of the requisite knowledge to finalize my course study successfully. I would like to thank my parents for their support. It is indeed a pleasure to thank my friends who persuaded and encouraged me to take up and complete this task. At last but not least, I express my gratitude and appreciation to all those who have helped me directly or indirectly toward the successful completion of this project.
Place: Vellore
Date: D ARAVINDRAJ
CONTENTS
Chapter No. Title Page No.

1 Introduction 11
1.1 Introduction of project 11
1.2 Overview of smart security 12
1.3 Challenges in the system 12
1.4 Project statement 13
1.5 Objectives 14
1.6 Scope of the project 15
2 Requirements and Literature Survey 16
2.1 Proposed system 16
2.2 System requirements 16
2.3 System analysis and User requirements 17
2.4 Literature review 18
2.5 Literature summary 22
2.6 Gant chart (Schedule) 23
3 Design and Module description 24
3.1 System architecture 24
3.2 System components 25
3.2.1 Arduino UNO AtMega 328 25
3.2.2 Servo motor 30
3.2.3 LCD display 32
3.2.4 RFID MFRC522 35
3.3 UML diagrams 36
3.3.1 Use-case diagram 36
3.3.2 Class diagram 38
3.3.3 Sequence diagram 40
3.3.4 Activity diagram 43
3.3.5 Flowchart diagram 46
4 Software testing and System implementation 49
4.1 Implementation strategy 49
4.2 Modules 49
4.2.1 Power supply unit 50
4.2.2 Micro-controller unit 50
4.2.3 Communication unit 50
4.2.4 Display unit 51
4.2.5 Software unit 51
4.3 Software product testing 52
4.3.1 Functional and System testing 52
4.3.2 Unit testing 56
4.3.3 Component testing 59
4.3.4 Integration testing 61
4.3.5 Complete test results 64
4.4 System implementation 65
Snapshots Future works 72
Conclusion 72
References 73
LIST OF FIGURES
Fig No. Name Page No.

1 Gant Chart 23
2 System architecture 24
3 Arduino UNO 26
4 Microcontroller AtMega 328 28
5 Pin diagram of AtMega 328 29
6 Servo motor 31
7 LCD display 34
8 RFID module 35
9 Use-case diagram 36
10 Class diagram 39
11 Sequence diagram 42
12 Activity diagram 45
13 Flowchart diagram 48
LIST OF TABLES
Tab No. Name Page No.

1 LCD description 33
2 Functional and System testing 54
3 Unit testing 58
4 Component testing 60
5 Integration testing 63
6 Test results 64
CHAPTER 1
1. INTRODUCTION
1.1 INTRODUCTION
A major challenge facing healthcare organizations is the provision of quality services at affordable costs. Quality service implies diagnosing patients correctly and administering treatments that are effective. Poor clinical decisions can lead to disastrous consequences which are therefore unacceptable. Hospitals must also minimize the cost of clinical tests. They can achieve these results by employing appropriate computer-based information and decision support systems. Most hospitals today employ some sort of hospital information systems to manage their healthcare or patient data. These systems typically generate huge amounts of data which take the form of numbers, text, charts and images. Unfortunately, these data are rarely used to support clinical decision making. There is a wealth of hidden information in these data that is largely untapped. This raises an important question: “How can we turn data into useful information that can enable healthcare practitioners to make intelligent clinical decisions?” Although data mining has been around for more than two decades, its potential is only being realized now. Data mining combines statistical analysis, machine learning and database technology to extract hidden patterns and relationships from large databases.
Naive Bayes or Bayes Rule is the basis for many machine-learning and data mining methods. The algorithm is used to create models with predictive capabilities. It provides new ways of exploring and understanding data. It learns from the “evidence” by calculating the correlation between the target and other variables.

1.2 OVERVIEW
Data mining is process to analyses number of data sets and then extracts the meaning of data. It helps to predict the patterns and future trends, allowing business in decision making. It might have happened so many times that you or someone yours need doctors help immediately, but they are not available due to some reason. The Heart Disease Prediction application is an end user support that will help you to finding out the heart disease. Here we use Bayes algorithm techniques to guess the most accurate illness that could be associated with patient’s details. Based on result, they can contact doctor accordingly for further treatment.

1.3 CHALLENGES PRESENT IN THE SYSTEM
Analyzing the dataset:
The dataset should be analyzed with more accuracy and that too in a speedy manner after that the user can see the doctor details to contact them.

1.4 PROJECT STATEMENT
Healthcare industries collect large volume of data which are not able to process manually. Advancements in Technology played a vital role in storing and processing such huge collection of clinical data. Medical decision support systems are intended to support doctors in their diagnosis as well as user to known the chance of getting affected by disease and take treatment accordingly.

1.5 OBJECTIVES
To provide immediate medical care to the needy in best possible way and to predict heart risk level of the user.

1.6 SCOPE OF THE PROJECT
The aim of this product is to create “Health care application” that increases the awareness of getting affected by the disease and risk of users and to consult doctor quickly and to take precaution.

CHAPTER 2
2.1 PROPOSED SYSTEM
Considering the anomalies in the existing system computerization of the whole activity is being suggested after initial analysis.It might have happened so many times that you or someone yours need doctors help immediately, but they are not available due to some reason. The Heart Disease Prediction application is an end user support and online consultation project. Here, we propose a web application that allows users to get instant guidance on their heart disease through an intelligent system online.The application is fed with various details and the heart disease associated with those details. The application allows user to share their heart related issues. It then processes user specific details to check for various illness that could be associated with it. Here we use some intelligent data mining techniques to guess the most accurate illness that could be associated with patient’s details. Based on result, system automatically shows the result specific doctor’s for further treatment.The system allows user to view doctor’s details.The system can be use in case of emergency.

2.2 SYSTEM REQUIREMENTS
The system requirements for the proposed system are:
Hardware Specifications
i3 Processor Based Computer or higher
Memory: 1 GB RAM
Hard Drive: 50 GB
Monitor
Internet Connection
Software Specifications
Windows 7 or higher
Visual studio 2010.

SQL Server 2008.

2.3 LITERATURE REVIEW
Lakshmi Devasena. CPerformance Evaluation Of Memory Based Classifiers With Correlation Based Feature Selection Subset Evaluator For Heart Disease Predictionmay-2016 -In this paper they have stated that, There are numerous works coming up for better heart disease prediction. Researchers showing interest in this area to find the better algorithms which gives superior accuracy and analyzing various measures to study the performance of different algorithms. The algorithms like neuro-fuzzy integrated approach, combined technique of Maximal Frequent Item set Algorithm K-means algorithm, Artificial Neural Network with Feature Subset Selection and Principal component Analysis are analyzed for heart disease prediction in SPAM algorithm with Nearest Neighbor Classifier, Genetic Algorithm for variety of Optimal Reduced Set of Attributes and Naive Bayes with Decision Tree classifier, decision tree algorithm with Rule reduction are compared and analyzed for heart disease prediction. Cluster based Association Rule Mining using sequence number, SMO, Logistic Function and Multilayer Perceptron, K- Nearest Neighbor Algorithm are analyzed and compared for heart disease prediction.

K. Manimekalai Dr. A. Kavitha Dr. A. Marimuthu . Intelligent Heart Disease Prediction System Using Data Mining Techniques 3. In this paper, they stated as Classification is the major data mining technique which is primarily used in healthcare sectors for medical diagnosis and predicting diseases. Classification algorithms namely Naïve bayes, J48, REP Tree and Random Forest are used for heart disease prediction. And also based on the result they have told that is proposed that Naive Bayes gives better accuracy when compared to the other algorithms Weka can be extended further to medical field for diagnosis of different diseases like cancer and many others. An added advantage of using Weka for prediction of diseases is that it can easily diagnose a disease even in case when the number of patients for whom the prediction has to be done is huge or in case of very large data sets spanning lakhs of patients. Even though Weka is a powerful data mining tool to analyse the overview of Classification, Clustering, Association Rule Mining and visualization of result in medical health to predict disease.

2.5 LITERATURE SUMMARY
All the above papers have been very valuable and constructive to help my project to improvise the prediction system. It was also very astute and discerning source to implement the idea of a completely Heart disease prediction system. The survey has been very resourceful in delivering new algorithms to implement such prediction software. It was also useful in conveying the importance of finding the heart disease to futuristic scope of the software on a global scale and also various expert suggestions and reviews on implementing such heart disease prediction systems in places where privacy, security and solidarity is very essential.

2.6 GANT CHART (SCHEDULE)

CHAPTER 3
3.1 SYSTEM ARCHITECTURE
Fig.1 System architecture

3.3 UML DIAGRAMS
3.3.1 USE CASE DIAGRAM
Access the web app

Registration

Login

Checks Heart

Specifies the Details

Checks the accurate results

User/Patient
View Doctor

Communicates with the Doctor

Feedback

Login

Add Training Data

Add Doctor Details

View Doctor Details

View User Details

View Training Data

Manages Security Issues
Admin
View Feedback

Fig.8 Use case diagram
A use case diagram at its simplest is a representation of a user’s interaction with the system that shows the relationship between the user and the different use cases in which the user is involved. A use case diagram can identify the different types of users of a system and the different use cases and will often be accompanied by other types of diagrams as well.

While a use case itself might drill into a lot of detail about every possibility, a use-case diagram can help provide a higher-level view of the system. It has been said before that Use case diagrams are the blueprints for your system. They provide the simplified and graphical representation of what the system must actually do.

Due to their simplistic nature, use case diagrams can be a good communication tool for stakeholders. The drawings attempt to mimic the real world and provide a view for the stakeholder to understand how the system is going to be designed. It was found was that the use case diagrams conveyed the intent of the system in a more simplified manner to stakeholders and that they were interpreted more completely than class diagrams.

The purpose of the use case diagrams is simply to provide the high level view of the system and convey the requirements in layman’s terms for the stakeholders. Additional diagrams and documentation can be used to provide a complete functional and technical view of the system.

3.3.2 CLASS DIAGRAM
In software engineering, a class diagram in the Unified Modelling Language (UML) is a type of static structure diagram that describes the structure of a system by showing the system’s classes, their attributes, operations (or methods), and the relationships among objects.

The class diagram is the main building block of object-oriented modelling. It is used for general conceptual modelling of the systematic of the application, and for detailed modelling translating the models into programming code. Class diagrams can also be used for data modelling. The classes in a class diagram represent both the main elements, interactions in the application, and the classes to be programmed.

In the diagram, classes are represented with boxes that contain three compartments:
The top compartment contains the name of the class. It is printed in bold and centered, and the first letter is capitalized.

The middle compartment contains the attributes of the class. They are left-aligned and the first letter is lowercase.

The bottom compartment contains the operations the class can execute. They are also left-aligned and the first letter is lowercase.

In the design of a system, a number of classes are identified and grouped together in a class diagram that helps to determine the static relations between them. With detailed modelling, the classes of the conceptual design are often split into a number of subclasses. In order to further describe the behaviour of systems, these class diagrams can be complemented by a state diagram or UML state machine.

USER
– User_id:String
– Password:String
+ Login()
+ btn_Click ()
+ Logout ()

ADMIN
– Admin_id:String
– Password:String
+ Login()
+ btn_Click ()
+ Logout ()
New Registration
– Fname: String
– Lname: String
– DOB: Int
– Gender: String
– Address: String
– Mobile No.: Int
– Email id: String
– User id: String
– Password: String
Fig.9 Class diagram

3.3.3 SEQUENCE DIAGRAM
A sequence diagram shows object interactions arranged in time sequence. It depicts the objects and classes involved in the scenario and the sequence of messages exchanged between the objects needed to carry out the functionality of the scenario. Sequence diagrams are typically associated with use case realizations in the Logical View of the system under development. Sequence diagrams are sometimes called event diagrams or event scenarios.

A sequence diagram shows, as parallel vertical lines (lifelines), different processes or objects that live simultaneously, and, as horizontal arrows, the messages exchanged between them, in the order in which they occur. This allows the specification of simple runtime scenarios in a graphical manner. If the lifeline is that of an object, it demonstrates a role. Leaving the instance name blank can represent anonymous and unnamed instances.

Solid arrow heads represent synchronous calls, open arrow heads represent asynchronous messages, and dashed lines represent reply messages. If a caller sends a synchronous message, it must wait until the message is done, such as invoking a subroutine. If a caller sends an asynchronous message, it can continue processing and doesn’t have to wait for a response. Asynchronous calls are present in multithreaded applications, event-driven applications and in message-oriented middleware. Activation boxes, or method-call boxes, are opaque rectangles drawn on top of lifelines to represent that processes are being performed in response to the message (Execution Specifications in UML).

Objects calling methods on themselves use messages and add new activation boxes on top of any others to indicate a further level of processing. If an object is destroyed (removed from memory) an X is drawn on bottom of the lifeline and the dashed line ceases to be drawn below it. It should be the result of a message, either from the object itself, or another.

A message sent from outside the diagram can be represented by a message originating from a filled-in circle (found message in UML) or from a border of the sequence diagram (gate in UML).

UML has introduced significant improvements to the capabilities of sequence diagrams. Most of these improvements are based on the idea of interaction fragments which represent smaller pieces of an enclosing interaction. Multiple interaction fragments are combined to create a variety of combined fragments, which are then used to model interactions that include parallelism, conditional branches, and optional interactions.

Heart Disease Prediction
Main Page

User

Enters User_id & Password

Validates User

Invalid Login
– – – – – – – – – – – – – – – – – – – – – – – – – – – –

New Registration

If Valid, then Displays Main page

Specifies the Details to check Heart Disease

Ask multiple questions based on Disease

Checks the accurate result

Searches/Views Doctor accordingly

Communicates with the doctor

Feedback
Main Page
Heart Disease Prediction

Admin

Enters Admin_id & Password

Validates Admin

Invalid Login
– – – – – – – – – – – – – – – – – – – – – – – – – – – –

If Valid, then Displays Main page

Adds Training Data

Training Data Added

Adds Doctor/Disease Details

Details Added Successfully

Views Doctor/Disease/User Details

Retrieves the Respective Details

View Feedback
Fig.10 Sequence diagram
3.3.4 ACTIVITY DIAGRAM
Activity diagrams are graphical representations of workflows of stepwise activities and actions with support for choice, iteration and concurrency. In the Unified Modelling Language, activity diagrams are intended to model both computational and organizational processes (i.e., workflows), as well as the data flows intersecting with the related activities. Although activity diagrams primarily show the overall flow of control, they can also include elements showing the flow of data between activities through one or more data stores. Activity diagrams are constructed from a limited number of shapes, connected with arrows.
The most important shape types:
Rounded rectangles represent actions;
Diamonds represent decisions;
Bars represent the start (split) or end (join) of concurrent activities;
A black circle represents the start (initial node) of the workflow;
An encircled black circle represents the end (final node).

Arrows run from the start towards the end and represent the order in which activities happen. Activity diagrams can be regarded as a form of a structured flowchart combined with a traditional data flow diagram. Typical flowchart techniques lack constructs for expressing concurrency. However, the join and split symbols in activity diagrams only resolve this for simple cases; the meaning of the model is not clear when they are arbitrarily combined with decisions or loops.

While in UML 1.x, activity diagrams were a specialized form of state diagrams, in UML 2.x, the activity diagrams were reformalized to be based on Petri net-like semantics, increasing the scope of situations that can be modelled using activity diagrams. These changes cause many UML 1.x activity diagrams to be interpreted differently in UML 2.x.

UML activity diagrams in version 2.x can be used in various domains, e.g. in design of embedded systems. It is possible to verify such a specification using model checking technique.

Fig.11 Activity diagram
3.3.5 DATAFLOW DIAGRAM
A data flow diagram is graphical tool used to describe and analyze movement of data through a system. These are the central tool and the basis from which the other components are developed. The transformation of data from input to output, through processed, may be described logically and independently of physical components associated with the system. These are known as the logical data flow diagrams. The physical data flow diagrams show the actual implements and movement of data between people, departments and workstations. A full description of a system actually consists of a set of data flow diagrams. Using two familiar notations Yourdon, Gane and Sarson notation develops the data flow diagrams. Each component in a DFD is labeled with a descriptive name. Process is further identified with a number that will be used for identification purpose. The development of DFD’s is done in several levels. Each process in lower level diagrams can be broken down into a more detailed DFD in the next level. The lop-level diagram is often called context diagram. It consists a single process bit, which plays vital role in studying the current system. The process in the context level diagram is exploded into other process at the first level DFD.

The idea behind the explosion of a process into more process is that understanding at one level of detail is exploded into greater detail at the next level. This is done until further explosion is necessary and an adequate amount of detail is described for analyst to understand the process.

Larry Constantine first developed the DFD as a way of expressing system requirements in a graphical from, this lead to the modular design.
A DFD is also known as a “bubble Chart” has the purpose of clarifying system requirements and identifying major transformations that will become programs in system design. So it is the starting point of the design to the lowest level of detail. A DFD consists of a series of bubbles joined by data flows in the system.

DFD SYMBOLS:
In the DFD, there are four symbols
A square defines a source(originator) or destination of system data
An arrow identifies data flow. It is the pipeline through which the information flows
A circle or a bubble represents a process that transforms incoming data flow into outgoing data flows.

An open rectangle is a data store, data at rest or a temporary repository of data
Process that transforms data flow.

Source or Destination of data
Data flow

Data Store

CONSTRUCTING A DFD:
Several rules of thumb are used in drawing DFD’s:
Process should be named and numbered for an easy reference. Each name should be representative of the process.

The direction of flow is from top to bottom and from left to right. Data traditionally flow from source to the destination although they may flow back to the source. One way to indicate this is to draw long flow line back to a source. An alternative way is to repeat the source symbol as a destination. Since it is used more than once in the DFD it is marked with a short diagonal.

When a process is exploded into lower level details, they are numbered.

The names of data stores and destinations are written in capital letters. Process and dataflow names have the first letter of each work capitalized
A DFD typically shows the minimum contents of data store. Each data store should contain all the data elements that flow in and out.

Questionnaires should contain all the data elements that flow in and out. Missing interfaces redundancies and like is then accounted for often through interviews.

SAILENT FEATURES OF DFD’s
The DFD shows flow of data, not of control loops and decision are controlled considerations do not appear on a DFD.

The DFD does not indicate the time factor involved in any process whether the data flows take place daily, weekly, monthly or yearly.

The sequence of events is not brought out on the DFD.

TYPES OF DATA FLOW DIAGRAMS
Current Physical
Current Logical
New Logical
New Physical
CURRENT PHYSICAL:
In Current Physical DFD process label include the name of people or their positions or the names of computer systems that might provide some of the overall system-processing label includes an identification of the technology used to process the data. Similarly data flows and data stores are often labels with the names of the actual physical media on which data are stored such as file folders, computer files, business forms or computer tapes.

CURRENT LOGICAL:
The physical aspects at the system are removed as much as possible so that the current system is reduced to its essence to the data and the processors that transform them regardless of actual physical form.

NEW LOGICAL:
This is exactly like a current logical model if the user were completely happy with the user were completely happy with the functionality of the current system but had problems with how it was implemented typically through the new logical model will differ from current logical model while having additional functions, absolute function removal and inefficient flows recognized.
NEW PHYSICAL:
The new physical represents only the physical implementation of the new system.

RULES GOVERNING THE DFD’S
PROCESS
No process can have only outputs.

No process can have only inputs. If an object has only inputs than it must be a sink.

A process has a verb phrase label.

DATA STORE
Data cannot move directly from one data store to another data store, a process must move data.

Data cannot move directly from an outside source to a data store, a process, which receives, must move data from the source and place the data into data store
A data store has a noun phrase label.

SOURCE OR SINK
The origin and /or destination of data.

Data cannot move direly from a source to sink it must be moved by a process
A source and /or sink has a noun phrase land
DATA FLOW
A Data Flow has only one direction of flow between symbols. It may flow in both directions between a process and a data store to show a read before an update. The later it usually indicated however by two separate arrows since these happen at different type.

A join in DFD means that exactly the same data comes from any of two or more different processes data store or sink to a common location.

A data flow cannot go directly back to the same process it leads. There must be at least one other process that handles the data flow produce some other data flow returns the original data into the beginning process.

A Data flow to a data store means update (delete or change).

A data Flow from a data store means retrieve or use.

Heart Disease Prediction DB
0.0
User
Database
DATABASE DETAIL
Query
Data Flow Diagrams
Process
Request
1.0
User
Query
Database
Feedback For
User
Check for user
Requirement
User need
Relevant
Data
1.1

LEVEL 1 DFD

Accept
Query
2.0
User
Check Availability of or for query processing
Process
Query
Give request to user
Via Heart Disease Prediction DB
Give info about DB
2.1
2.2
Query

CHAPTER 4
4.1 IMPLEMENTATION STRATEGY
Implementation is the stage of the project when the theoretical design is turned out into a working system. Thus it can be considered to be the most critical stage in achieving a successful new system and in giving the user, confidence that the new system will work and be effective. The implementation stage involves careful planning, investigation of the existing system and it’s constraints on implementation, designing of methods to achieve changeover and evaluation of changeover methods.

4.2 MODULES AND OVERVIEW OF TECHNOLOGY USED
The system comprises of 2 major modules as follows:
Admin Module
Add Training Data
Add Doctor Details
View User Details
View Feedback
View Doc Details
View Training Data
User Module
Register (With Details like Age, Sex, etc.)
Check Heart (By providing Details like
Age in Year
Gender
Chest Pain Type
Fasting Blood Sugar
Resting Electrographic Results(Restecg)
Exercise Induced Angina(Exang)
The slope of the peak exercise ST segment
CA – Number of major vessels colored by fluoroscopy
Thal
Trest Blood Pressure
Serum Cholesterol
Maximum heart rate achieved(Thalach)
ST depression induced by exercise(Oldpeak)
System will accordingly view Doctor to consult.

Give Feedback
View Doctor
Front End Technology
Microsoft .NET Framework
The .NET Framework is a new computing platform that simplifies application development in the highly distributed environment of the Internet. The .NET Framework is designed to fulfill the following objectives:
To provide a consistent object-oriented programming environment whether object code is stored and executed locally, executed locally but Internet-distributed, or executed remotely.
To provide a code-execution environment that minimizes software deployment and versioning conflicts.
To provide a code-execution environment that guarantees safe execution of code, including code created by an unknown or semi-trusted third party.
To provide a code-execution environment that eliminates the performance problems of scripted or interpreted environments.
To make the developer experience consistent across widely varying types of applications, such as Windows-based applications and Web-based applications.
To build all communication on industry standards to ensure that code based on the .NET Framework can integrate with any other code.
BACK END TECHNOLOGY:
About Microsoft SQL Server
Microsoft SQL Server is a Structured Query Language (SQL) based, client/server relational database. Each of these terms describes a fundamental part of the architecture of SQL Server.
Database
A database is similar to a data file in that it is a storage place for data. Like a data file, a database does not present information directly to a user; the user runs an application that accesses data from the database and presents it to the user in an understandable format.
A database typically has two components: the files holding the physical database and the database management system (DBMS) software that applications use to access data. The DBMS is responsible for enforcing the database structure, including:
Maintaining the relationships between data in the database.
Ensuring that data is stored correctly and that the rules defining data relationships are not violated.
Recovering all data to a point of known consistency in case of system failures.
Relational Database
There are different ways to organize data in a database but relational databases are one of the most effective. Relational database systems are an application of mathematical set theory to the problem of effectively organizing data. In a relational database, data is collected into tables (called relations in relational theory).
When organizing data into tables, you can usually find many different ways to define tables. Relational database theory defines a process, normalization, which ensures that the set of tables you define will organize your data effectively.
4.3 SOFTWARE TESTING
As the project is on bit large scale, we always need testing to make it successful. If each components work properly in all respect and gives desired output for all kind of inputs then project is said to be successful. So the conclusion is-to make the project successful, it needs to be tested.

The testing done here was System Testing checking whether the user requirements were satisfied. The code for the new system has been written completely using ASP .NET with C# as the coding language, C# as the interface for front-end designing. The new system has been tested well with the help of the users and all the applications have been verified from every nook and corner of the user.

Although some applications were found to be erroneous these applications have been corrected before being implemented. The flow of the forms has been found to be very much in accordance with the actual flow of data.

Levels of Testing
In order to uncover the errors present in different phases we have the concept of levels of testing. The basic levels of testing are:
Client NeedsAcceptance Testing

RequirementsSystem Testing

DesignIntegration Testing
Code Unit Testing
A series of testing is done for the proposed system before the system is ready for the user acceptance testing.

The steps involved in Testing are:
Unit Testing
Unit testing focuses verification efforts on the smallest unit of the software design, the module. This is also known as “Module Testing”. The modules are tested separately. This testing carried out during programming stage itself. In this testing each module is found to be working satisfactorily as regards to the expected output from the module.

Integration Testing

Data can be grossed across an interface; one module can have adverse efforts on another. Integration testing is systematic testing for construction the program structure while at the same time conducting tests to uncover errors associated with in the interface. The objective is to take unit tested modules and build a program structure. All the modules are combined and tested as a whole. Here correction is difficult because the isolation of cause is complicate by the vast expense of the entire program. Thus in the integration testing stop, all the errors uncovered are corrected for the text testing steps.

System testing
System testing is the stage of implementation that is aimed at ensuring that the system works accurately and efficiently for live operation commences. Testing is vital to the success of the system. System testing makes a logical assumption that if all the parts of the system are correct, then goal will be successfully achieved.

Validation Testing
At the conclusion of integration testing software is completely assembled as a package, interfacing errors have been uncovered and corrected and a final series of software tests begins, validation test begins. Validation test can be defined in many ways. But the simple definition is that validation succeeds when the software function in a manner that can reasonably expected by the customer. After validation test has been conducted one of two possible conditions exists.

One is the function or performance characteristics confirm to specifications and are accepted and the other is deviation from specification is uncovered and a deficiency list is created. Proposed system under consideration has been tested by using validation testing and found to be working satisfactorily.

Output Testing
After performing validation testing, the next step is output testing of the proposed system since no system could be useful if it does not produce the required output in the specified format. Asking the users about the format required by them tests the outputs generated by the system under consideration. Here the output format is considered in two ways, one is on the screen and other is the printed format. The output format on the screen is found to be correct as the format was designed in the system designed phase according to the user needs.
For the hard copy also the output comes as the specified requirements by the users. Hence output testing does not result any corrections in the system.

User Acceptance Testing
User acceptance of a system is the key factor of the success of any system. The system under study is tested for the user acceptance by constantly keeping in touch with the prospective system users at the time of developing and making changes wherever required.

TEST CASE #1: LoginLogin is the process by which an individual gains access to a computer system by identifying and authenticating themselves. The user credentials are typically some form of “username” and a matching “password” so that user can able to authenticate in their account.

TEST ID TEST STEPS TEST DATA EXPECTED OUTPUT ACTUAL OUTPUT TEST RESULT
1 Login Username:
[email protected]
Password:
ramukhsirah Navigate to Home page Navigate to Home page Pass
2 Login Username:
[email protected]
Password:
asdf Login failed Login failed
(Not Authenticated user) Pass
3 Login Username:
aravindh
Password:
1234 Login failed Login failed
(Wrong format) Pass
4 Login Username:
Null(no value)
Password:
abcd Login failed Login failed
(Null values) Pass
5 Login Username:
[email protected]
Password:
abcd Login failed Navigate to Home page Fail
Login Test caseTEST CASE #2: Signup
Description:
The user have to register their details to access the system.

TEST ID TEST STEPS TEST DATA EXPECTED OUTPUT ACTUAL OUTPUT
TEST RESULT
1
Signing up All values are provided Navigate to login page Navigate to login page
Pass
2
Signing up Null/Wrong values are provided Show error Show error Pass
3
Signing up Null/Wrong values are provided Show error Navigate to login page Fail
Table STYLEREF 2 s 4.2. SEQ Table * ARABIC s 2 1 Signup Test caseTEST CASE #3: Getting Input from UserDescription:
The system will get the input from the user and produce the result based in the given inputs.

TEST ID TEST STEPS TEST DATA EXPECTED OUTPUT ACTUAL OUTPUT TEST RESULT
1 Getting user details Giving input to all fields Result will be given Result will be given Pass
2 Getting user details Wrong input Show errors Show errors Pass
3 Getting user details Correct data Give results Show errors Fail
Table STYLEREF 2 s 4.3. SEQ Table * ARABIC s 2 1 Getting Input4.4 SYSTEM IMPLEMENTATION
;%@ Page Title=”” Language=”C#” MasterPageFile=”~/MasterPage.master” AutoEventWireup=”true” CodeFile=”MainLogin.aspx.cs” Inherits=”MainLogin” %;
;asp:Content ID=”Content1″ ContentPlaceHolderID=”head” Runat=”Server”;
;style type=”text/css”;
.auto-style1 {
width: 100%;
}
.auto-style2 {
height: 125px;
width: 33%;
}
.auto-style3 {
height: 25px;
width: 33%;
}
;/style;
;/asp:Content;
;asp:Content ID=”Content2″ ContentPlaceHolderID=”ContentPlaceHolder1″ Runat=”Server”;
;br /;
;br /;
;table style=”border: 1px solid #C0C0C0″ width=”80%”;
;tr;
;td height=”250″ align=”center” class=”auto-style2″;
;asp:ImageButton ID=”ImageButton1″ runat=”server” ImageUrl=”~/images/Admin.jpg” PostBackUrl=”~/AdminLogin.aspx” Width=”170px” /;
;/td;

;td width=”33.35%” align=”center”;
;asp:ImageButton ID=”ImageButton3″ runat=”server” ImageUrl=”~/images/User.png” PostBackUrl=”~/UserLogin.aspx” Width=”180px” /;
;/td;
;/tr;
;tr;
;td align=”center” class=”auto-style3″;
;asp:LinkButton ID=”LinkButton1″ runat=”server” Font-Bold=”True” Font-Size=”Large” Font-Underline=”False” ForeColor=”#333333″ PostBackUrl=”~/AdminLogin.aspx” style=”font-family: candara; font-size: xx-large”;Admin Login;/asp:LinkButton;
;/td;

;td width=”33.35%” align=”center” height=”20″;
;asp:LinkButton ID=”LinkButton3″ runat=”server” Font-Bold=”True” Font-Size=”Large” Font-Underline=”False” ForeColor=”#333333″ PostBackUrl=”~/UserLogin.aspx” style=”font-family: candara; font-size: xx-large”;User Login;/asp:LinkButton;
;/td;
;/tr;
;/table;
;br /;
;br /;
;/asp:Content;
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Data.SqlClient;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
public partial class UserLogin : System.Web.UI.Page
{
SqlConnection con = new SqlConnection(ConfigurationManager.ConnectionStrings”Heart”.ConnectionString);
protected void Page_Load(object sender, EventArgs e)
{
if(Session”Log”==”Data”)
{
Page.ClientScript.RegisterStartupScript(GetType(), “msgtype”, “alert(‘Registration Successful. Please login to access the system.’)”, true);
Session”Log” = “”;
}
}
protected void Button1_Click(object sender, EventArgs e)
{
if (TextBox1.Text == “”)
{
Label2.Visible = true;
Label2.Text = “Please fill out this field”;
}
else if (TextBox2.Text == “”)
{
Label3.Visible = true;
Label3.Text = “Please fill out this field”;
}
else if (TextBox1.Text != “” ;; TextBox2.Text != “”)
{
string str1 = “select id,password from Register where id='” + TextBox1.Text + “‘ and password='” + TextBox2.Text + “‘”;
SqlDataAdapter da1 = new SqlDataAdapter(str1, con);
DataTable dt1 = new DataTable();
da1.Fill(dt1);
if (dt1.Rows.Count ; 0)
{
Session”Type” = “User”;
Session”Uid” = TextBox1.Text;
Response.Redirect(“CheckHeart.aspx”);
}
else
{
Page.ClientScript.RegisterStartupScript(GetType(), “msgtype”, “alert(‘Incorrect User Id or Password.’)”, true);
}
}
}
}
;%@ Page Title=”” Language=”C#” MasterPageFile=”~/MasterPage.master” AutoEventWireup=”true” CodeFile=”CheckHeart.aspx.cs” Inherits=”CheckHeart” %;
;asp:Content ID=”Content1″ ContentPlaceHolderID=”head” Runat=”Server”;
;style type=”text/css”;
.style1
{
font-size: xx-large;
}
.intLog
{
-webkit-border-radius: 10px;
-moz-border-radius: 10px;
}
.style9
{
height: 40px;
}
.style10
{
-webkit-border-radius: 10px;
-moz-border-radius: 10px;
font-family: Calibri;
}
.style11
{
font-family: Calibri;
font-size: large;
color: #333333;
font-weight: 700;
}
.style12
{
-webkit-border-radius: 10px;
-moz-border-radius: 10px;
font-family: Calibri;
font-size: large;
}
.style13
{
width: 20%;
}
.style14
{
width: 20%;
}
.auto-style1 {
height: 23px;
}
;/style;
;/asp:Content;
;asp:Content ID=”Content2″ ContentPlaceHolderID=”ContentPlaceHolder1″ Runat=”Server”;
;asp:Panel ID=”Panel1″ runat=”server”;
;asp:Label ID=”Label1″ runat=”server” Text=”Results :” style=”font-size: x-large”;;/asp:Label;
;asp:Label ID=”Label2″ runat=”server” Text=”” style=”font-size: x-large”;;/asp:Label;
;/asp:Panel;
;br /;
;table style=”border: 1px solid #C0C0C0; background-image: url(‘Images/bg.jpg’); ”
width=”60%” class=”intLog”;
;tr;
;td colspan=”3″
style=”background-image: url(‘Images/blurred.jpg’)”
align=”center” class=”intLog” bgcolor=”#CC3300″;
;asp:Label ID=”Label3″ runat=”server” style=”font-family: calibri; font-size: xx-large; color: #FFFFFF;” Text=”– Check your Heart –“;;/asp:Label;
;/td;
;/tr;
;tr;
;td colspan=”3″ align=”right” style=”color: #FF0000; font-size: small”;
;nbsp;;/td;
;/tr;
;tr;
;td colspan=”3″ align=”center” style=”color: #FF0000; font-size: small”;
* Kindly fill up all the details given below;br /;
;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td align=”left”;
;nbsp;;/td;
;td width=”33%” align=”left” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td align=”left”;
;asp:TextBox ID=”TextBox14″ runat=”server” CssClass=”style12″
placeholder=” Chest Pain Type” required=”Required” Width=”100%”;;/asp:TextBox;
;/td;
;td width=”33%” align=”left” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td align=”left”;
;nbsp;;/td;
;td width=”33%” align=”left” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;/td;
;td class=”style9″ align=”left” ;
;asp:TextBox ID=”TextBox4″ runat=”server” CssClass=”style12″
placeholder=” Fasting Blood Sugar” required=”Required” Width=”100%”;;/asp:TextBox;
;/td;
;td width=”33%” align=”left” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;asp:TextBox ID=”TextBox5″ runat=”server” CssClass=”style12″
placeholder=” Resting Electrographic” required=”Required” Width=”100%”;;/asp:TextBox;
;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;nbsp;;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;asp:TextBox ID=”TextBox6″ runat=”server” CssClass=”style12″
placeholder=” Exercise Induced Angina” required=”Required” TextMode=”SingleLine” Width=”100%”;;/asp:TextBox;
;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;nbsp;;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;/td;
;td;
;asp:TextBox ID=”TextBox7″ runat=”server” CssClass=”style12″
placeholder=” Slope” required=”Required” TextMode=”SingleLine” Width=”100%”;;/asp:TextBox;
;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;nbsp;;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;asp:TextBox ID=”TextBox8″ runat=”server” CssClass=”style12″
placeholder=” No. of Major Vessels(CA) ” required=”Required” TextMode=”SingleLine” Width=”100%”;;/asp:TextBox;
;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;nbsp;;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;asp:TextBox ID=”TextBox9″ runat=”server” CssClass=”style12″
placeholder=” Thal” required=”Required” TextMode=”SingleLine” Width=”100%”;;/asp:TextBox;
;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;nbsp;;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;asp:TextBox ID=”TextBox10″ runat=”server” CssClass=”style12″
placeholder=” Trest Blood Pressure” required=”Required” TextMode=”SingleLine” Width=”100%”;;/asp:TextBox;
;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;nbsp;;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;asp:TextBox ID=”TextBox11″ runat=”server” CssClass=”style12″
placeholder=” Serum Cholesterol” required=”Required” TextMode=”SingleLine” Width=”100%”;;/asp:TextBox;
;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;nbsp;;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;asp:TextBox ID=”TextBox12″ runat=”server” CssClass=”style12″
placeholder=” Maximum Heart Rate achieved(Thalach)” required=”Required” TextMode=”SingleLine” Width=”100%”;;/asp:TextBox;
;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;nbsp;;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;asp:TextBox ID=”TextBox13″ runat=”server” CssClass=”style12″
placeholder=” ST Depression Induced by Exercise(Oldpeak)” required=”Required” TextMode=”SingleLine” Width=”100%”;;/asp:TextBox;
;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;nbsp;;/td;
;td width=”33%” class=”style14″;
;nbsp;;/td;
;/tr;
;tr;
;td colspan=”3″ class=”auto-style1″;
;/td;
;/tr;
;tr;
;td align=”center” colspan=”3″;

;asp:Button ID=”btnAnalyse” runat=”server” Text=”Analyse Heart” CssClass=”style10″
Height=”38px” Width=”200px” Font-Size=”X-Large” ForeColor=”#333333″
BorderColor=”#009933″ OnClick=”btnAnalyse_Click”/;
;/td;
;/tr;
;tr;
;td align=”right” class=”style13″;
;nbsp;;/td;
;td;
;asp:Label ID=”lblAge” runat=”server” Visible=”False”;;/asp:Label;
;asp:Label ID=”lblSex” runat=”server” Visible=”False”;;/asp:Label;
;/td;
;td width=”20%”;
;nbsp;;/td;
;/tr;
;/table;
;/asp:Content;
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Data.SqlClient;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
public partial class CheckHeart : System.Web.UI.Page
{
SqlConnection con = new SqlConnection(ConfigurationManager.ConnectionStrings”Heart”.ConnectionString);
protected void Page_Load(object sender, EventArgs e)
{
string Uid = Session”Uid”.ToString();
string str = “select age,gender from register where id='” + Uid + “‘”;
SqlDataAdapter da = new SqlDataAdapter(str, con);
DataSet ds = new DataSet();
da.Fill(ds);
string age = ds.Tables0.Rows00.ToString();
lblAge.Text = age;
string sex = ds.Tables0.Rows01.ToString();
if(sex==”Male”)
{
lblSex.Text = “1”;
}
else
{
lblSex.Text = “0”;
}
Panel1.Visible = false;
}
protected void btnAnalyse_Click(object sender, EventArgs e)
{
DataTable table = new DataTable();
table.Columns.Add(“Dname”);
table.Columns.Add(“Age”, typeof(double));
table.Columns.Add(“Gender”, typeof(double));
table.Columns.Add(“ChestPain”, typeof(double));
table.Columns.Add(“BloodSugar”, typeof(double));
table.Columns.Add(“Restecg”, typeof(double));
table.Columns.Add(“Exang”, typeof(double));
table.Columns.Add(“Slope”, typeof(double));
table.Columns.Add(“CA”, typeof(double));
table.Columns.Add(“Thal”, typeof(double));
table.Columns.Add(“BloodPressure”, typeof(double));
table.Columns.Add(“Cholesterol”, typeof(double));
table.Columns.Add(“Thalach”, typeof(double));
table.Columns.Add(“Oldpeak”, typeof(double));
string str = “select * from TrainingData”;
SqlDataAdapter da = new SqlDataAdapter(str, con);
DataSet ds = new DataSet();
da.Fill(ds);
for (int i = 0; i ; ds.Tables0.Rows.Count; i++)
{
table.Rows.Add(ds.Tables0.Rowsi0.ToString(),
Convert.ToDouble(ds.Tables0.Rowsi1.ToString()),
Convert.ToDouble(ds.Tables0.Rowsi2.ToString()),
Convert.ToDouble(ds.Tables0.Rowsi3.ToString()),
Convert.ToDouble(ds.Tables0.Rowsi4.ToString()),
Convert.ToDouble(ds.Tables0.Rowsi5.ToString()),
Convert.ToDouble(ds.Tables0.Rowsi6.ToString()),
Convert.ToDouble(ds.Tables0.Rowsi7.ToString()),
Convert.ToDouble(ds.Tables0.Rowsi8.ToString()),
Convert.ToDouble(ds.Tables0.Rowsi9.ToString()),
Convert.ToDouble(ds.Tables0.Rowsi10.ToString()),
Convert.ToDouble(ds.Tables0.Rowsi11.ToString()),
Convert.ToDouble(ds.Tables0.Rowsi12.ToString()),
Convert.ToDouble(ds.Tables0.Rowsi13.ToString()));
}
Classifier classifier = new Classifier();
classifier.TrainClassifier(table);
string ans = “”;
try
{
ans = classifier.Classify
(new double
{
Convert.ToDouble(lblAge.Text),
Convert.ToDouble(lblSex.Text),
Convert.ToDouble(TextBox14.Text),
Convert.ToDouble(TextBox4.Text),
Convert.ToDouble(TextBox5.Text),
Convert.ToDouble(TextBox6.Text),
Convert.ToDouble(TextBox7.Text),
Convert.ToDouble(TextBox8.Text),
Convert.ToDouble(TextBox9.Text),
Convert.ToDouble(TextBox10.Text),
Convert.ToDouble(TextBox11.Text),
Convert.ToDouble(TextBox12.Text),
Convert.ToDouble(TextBox13.Text)
});
Label2.Text = ans.ToString();
Panel1.Visible = true;
}
catch (Exception ep)
{
ans = ep.ToString();
Label2.Text = ans.ToString();
Panel1.Visible = true;
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
/// ;summary;
/// Summary description for Helper
/// ;/summary;
public static class Helper
{
public static double Variance(this IEnumerable;double; source)
{
double avg = source.Average();
double d = source.Aggregate(0.0, (total, next) =; total += Math.Pow(next – avg, 2));
return d / (source.Count() – 1);
}
public static double Mean(this IEnumerable;double; source)
{
if (source.Count() ; 1)
return 0.0;
double length = source.Count();
double sum = source.Sum();
return sum / length;
}
public static double NormalDist(double x, double mean, double standard_dev)
{
double fact = standard_dev * Math.Sqrt(2.0 * Math.PI);
double expo = (x – mean) * (x – mean) / (2.0 * standard_dev * standard_dev);
return Math.Exp(-expo) / fact;
}
public static double NORMDIST(double x, double mean, double standard_dev, bool cumulative)
{
const double parts = 50000.0; //large enough to make the trapzoids small enough
double lowBound = 0.0;
if (cumulative) //do integration: trapezoidal rule used here
{
double width = (x – lowBound) / (parts – 1.0);
double integral = 0.0;
for (int i = 1; i ; parts – 1; i++)
{
integral += 0.5 * width * (NormalDist(lowBound + width * i, mean, standard_dev) +
(NormalDist(lowBound + width * (i + 1), mean, standard_dev)));
}
return integral;
}
else //return function value
{
return NormalDist(x, mean, standard_dev);
}
}
public static double SquareRoot(double source)
{
return Math.Sqrt(source);
}
}
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Web;
/// ;summary;
/// Summary description for Classifier
/// ;/summary;
public class Classifier
{
private DataSet dataSet = new DataSet();
public DataSet DataSet
{
get { return dataSet; }
set { dataSet = value; }
}
public void TrainClassifier(DataTable table)
{
dataSet.Tables.Add(table);
//table
DataTable GaussianDistribution = dataSet.Tables.Add(“Gaussian”);
GaussianDistribution.Columns.Add(table.Columns0.ColumnName);
//columns
for (int i = 1; i ; table.Columns.Count; i++)
{
GaussianDistribution.Columns.Add(table.Columnsi.ColumnName + “Mean”);
GaussianDistribution.Columns.Add(table.Columnsi.ColumnName + “Variance”);
}
//calc data
var results = (from myRow in table.AsEnumerable()
group myRow by myRow.Field;string;(table.Columns0.ColumnName) into g
select new { Name = g.Key, Count = g.Count() }).ToList();
for (int j = 0; j ; results.Count; j++)
{
DataRow row = GaussianDistribution.Rows.Add();
row0 = resultsj.Name;
int a = 1;
for (int i = 1; i ; table.Columns.Count; i++)
{
rowa = Helper.Mean(SelectRows(table, i, string.Format(“{0} = ‘{1}'”, table.Columns0.ColumnName, resultsj.Name)));
row++a = Helper.Variance(SelectRows(table, i, string.Format(“{0} = ‘{1}'”, table.Columns0.ColumnName, resultsj.Name)));
a++;
}
}
}
public string Classify(double obj)
{
Dictionary;string, double; score = new Dictionary;string, double;();
var results = (from myRow in dataSet.Tables0.AsEnumerable()
group myRow by myRow.Field;string;(dataSet.Tables0.Columns0.ColumnName) into g
select new { Name = g.Key, Count = g.Count() }).ToList();
for (int i = 0; i ; results.Count; i++)
{
List;double; subScoreList = new List;double;();
int a = 1, b = 1;
for (int k = 1; k ; dataSet.Tables”Gaussian”.Columns.Count; k = k + 2)
{
double mean = Convert.ToDouble(dataSet.Tables”Gaussian”.Rowsia);
double variance = Convert.ToDouble(dataSet.Tables”Gaussian”.Rowsi++a);
double result = Helper.NormalDist(objb – 1, mean, Helper.SquareRoot(variance));
subScoreList.Add(result);
a++; b++;
}
double finalScore = 0;
List;double; ScoreList = new List;double;();
for (int p = 0; p ; subScoreList.Count; p++)
{
if (subScoreListp.ToString() != “NaN”)
{
ScoreList.Add(subScoreListp);
}
}
for (int z = 0; z ; ScoreList.Count; z++)
{
if (finalScore == 0)
{
finalScore = ScoreListz;
continue;
}
finalScore = finalScore * ScoreListz;
}
score.Add(resultsi.Name, finalScore * 0.5);
}
double maxOne = score.Max(c =; c.Value);
var name = (from c in score
where c.Value == maxOne
select c.Key).FirstOrDefault();
return name;
}
#region Helper Function
public IEnumerable;double; SelectRows(DataTable table, int column, string filter)
{
List;double; _doubleList = new List;double;();
DataRow rows = table.Select(filter);
for (int i = 0; i ; rows.Length; i++)
{
_doubleList.Add((double)rowsicolumn);
}
return _doubleList;
}
public void Clear()
{
dataSet = new DataSet();
}
#endregion
}
SCREENSHOTS

CONCLUSION
The Heart Disease Prediction, historically viewed as a necessary burden in medical offices, healthcare facilities and wellness centers, can be completely automated through an inefficient online software program. The benefits of implementing this technology touch everyone involved in the scheduling process, as administrators and users can conduct their tasks more efficiently and accurately. The system extracts hidden knowledge from a historical heart disease database. This system can be further enhanced and expanded.

REFERENCES
1 Lakshmi Devasena. CPerformance Evaluation Of Memory Based Classifiers With Correlation Based Feature Selection Subset Evaluator For Heart Disease Predictionmay-2016- IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308
2 K. Manimekalai Dr. A. Kavitha Dr. A. Marimuthu . Intelligent Heart Disease Prediction System Using Data Mining Techniques-IJSRD – International Journal for Scientific Research ; Development| Vol. 5, Issue 06, 2017 | ISSN (online): 2321-0613.

3 Rupali R.patel., Heart disease prediction system using naïve Bayes and jelinek-mercer smoothing
4 Data Mining Concepts and Technique by Jiawei Han and Micheline Kamber.