256
P. Guleria and M. Sood
(b) Lemmatize the words
(c) Erase Punctuation
(d) Remove stop words like “the”, “and”.
4.5 Results and Discussions
The result shown in Table 2 is obtained using the input dataset shown in Table 1
whereas the results of the test data are shown in Table 3. The test data sample i.e.
symptoms description attribute containing the data for training and analytical purpose
is shown below:
testdata = “The reasons for common cold may result into fever in kids and also
results into chest congestion”
The Fig. 7 displays the input raw data and the preprocessed, cleaned data.
Table 2 Tokenization of
dataset
ans = 8 × 1 tokenizedDocument
5 tokens
chill due fever sore throat
7 tokens
cold symptom running nose
cough sneeze bodyache headache
6 tokens
fatigue cause due symptom
common cold
6 tokens
bodyache tire ness due common
cold
2 tokens
prolong illness
5 tokens
chest congestion cough occur
cold
6 tokens
cold symptom run nose
bodyache headache
6 tokens
muscle ache due fever need
antibiotic
cleanedBag = bagOfWords with properties
Counts:
Vocabulary
NumWords NumDocuments
[13 × 37 double]
[1 × 37 string]
37
13
cleanedBag = bagOfWords with properties
Counts:
Vocabulary:
NumWords:
NumDocuments:
[13 × 7 double]
[1 × 7 string]
7
13
P. Guleria and M. Sood
(b) Lemmatize the words
(c) Erase Punctuation
(d) Remove stop words like “the”, “and”.
4.5 Results and Discussions
The result shown in Table 2 is obtained using the input dataset shown in Table 1
whereas the results of the test data are shown in Table 3. The test data sample i.e.
symptoms description attribute containing the data for training and analytical purpose
is shown below:
testdata = “The reasons for common cold may result into fever in kids and also
results into chest congestion”
The Fig. 7 displays the input raw data and the preprocessed, cleaned data.
Table 2 Tokenization of
dataset
ans = 8 × 1 tokenizedDocument
5 tokens
chill due fever sore throat
7 tokens
cold symptom running nose
cough sneeze bodyache headache
6 tokens
fatigue cause due symptom
common cold
6 tokens
bodyache tire ness due common
cold
2 tokens
prolong illness
5 tokens
chest congestion cough occur
cold
6 tokens
cold symptom run nose
bodyache headache
6 tokens
muscle ache due fever need
antibiotic
cleanedBag = bagOfWords with properties
Counts:
Vocabulary
NumWords NumDocuments
[13 × 37 double]
[1 × 37 string]
37
13
cleanedBag = bagOfWords with properties
Counts:
Vocabulary:
NumWords:
NumDocuments:
[13 × 7 double]
[1 × 7 string]
7
13
