Disusun oleh:
Kelompok D Kelas A
Eko Subha (105060801111067)
Penulis
ii
DAFTAR ISI
KATA PENGANTAR............................................................................................................... ii
DAFTAR ISI .......................................................................................................................... iii
DAFTAR GAMBAR................................................................................................................vi
DAFTAR TABEL ...................................................................................................................vii
DAFTAR PERSAMAAN........................................................................................................ viii
BAB I PENDAHULUAN ......................................................................................................... 1
1.1 Latar Belakang............................................................................................................... 1
1.2 Rumusan Masalah ......................................................................................................... 2
1.3 Batasan Masalah ........................................................................................................... 3
1.4 Tujuan ........................................................................................................................... 3
1.5 Manfaat ......................................................................................................................... 4
1.6 Sistematika Penulisan ................................................................................................... 4
BAB II DASAR TEORI ............................................................................................................ 6
2.1 Pelayanan Rawat Inap ................................................................................................... 6
2.2 Sistem Pakar .................................................................................................................. 6
2.2.1 Ciri dan Karakteristik Sistem Pakar .................................................................... 7
2.2.2 Rule .................................................................................................................. 10
2.3 Logika Fuzzy ................................................................................................................ 11
2.3.1 Himpunan Fuzzy ............................................................................................... 12
2.3.2 Fungsi Keanggotaan Fuzzy ............................................................................... 14
2.4 Fuzzy Inference System (FIS) Tsukamoto .................................................................... 15
2.4.1 Forward Chaining ............................................................................................. 15
2.4.2 Backward Chaining .......................................................................................... 16
2.5 Bahasa Pemrograman Java ......................................................................................... 19
2.6 Metode SBAR .............................................................................................................. 21
BAB III METODOLOGI PENELITIAN .................................................................................... 24
3.1 Studi Literatur ............................................................................................................. 25
3.2 Pengumpulan Data...................................................................................................... 25
3.3 Analisa Kebutuhan ...................................................................................................... 25
iii
3.4 Analisa Perancangan ................................................................................................... 27
3.4.1 Deskripsi Sistem ............................................................................................... 27
3.5 Implementasi Sistem................................................................................................... 34
3.6 Uji Coba Sistem ........................................................................................................... 34
3.7 Penarikan Kesimpulan................................................................................................. 36
BAB IV PERANCANGAN ..................................................................................................... 37
4.1 Analisa Kebutuhan Perangkat Lunak .......................................................................... 38
4.1.1 Identifikasi Aktor .............................................................................................. 38
4.1.2 Daftar Kebutuhan Sistem ................................................................................. 38
4.1.3 Diagram Use Case ............................................................................................ 39
4.1.4 Skenario Use Case ............................................................................................ 40
4.2 Perancangan Sistem Pakar .......................................................................................... 41
4.2.1 Akuisisi Pengetahuan ....................................................................................... 41
4.2.2 Basis Pengetahuan ........................................................................................... 41
4.2.2.1 Himpunan Bahasa Variable ....................................................................... 42
4.2.2.2 Semesta Pembicaraan............................................................................... 42
4.2.2.3 Fungsi Derajat Keanggotaan Variabel Tekanan Darah (SBP) .................... 42
4.2.2.4 Fungsi Derajat Keanggotaan Variabel Heart Rate..................................... 45
4.2.2.5 Fungsi Derajat Keanggotaan Variabel Tingkat kejenuhan Oksigen pada
Darah (SPO2) ......................................................................................................... 47
4.2.2.6 Fungsi Derajat Keanggotaan Variabel Suhu .............................................. 49
4.2.2.7 Fungsi Derajat Keanggotaan Variabel Gula Darah .................................... 51
4.2.2.8 Fungsi Derajat Keanggotaan Output ......................................................... 53
4.2.2.9 Rule ........................................................................................................... 57
4.2.3 Mesin Inferensi ................................................................................................ 86
4.2.4 Subsistem Antarmuka Pengguna ..................................................................... 87
BAB V IMPLEMENTASI....................................................................................................... 88
5.1 Lingkungan Implementasi ........................................................................................... 88
5.1.1 Kebutuhan Perangkat Keras............................................................................. 88
5.1.2 Kebutuhan Perangkat Lunak ............................................................................ 88
5.2 Implementasi Aplikasi ................................................................................................. 89
5.2.1 Kode Sumber Aplikasi ...................................................................................... 89
5.2.1.1 BloodSugar.java ........................................................................................ 89
iv
5.2.1.2 HeartRate.java .......................................................................................... 93
5.2.1.3 SystolicBloodPressure.java ....................................................................... 97
5.2.1.4 OxygenSaturation.java ............................................................................ 101
5.2.1.5 Temperature.java.................................................................................... 104
5.2.1.6 Risk.java .................................................................................................. 107
5.2.1.7 RiskPrediction.java .................................................................................. 108
5.2.1.8 PCMFuzzy.java ........................................................................................ 113
5.2.1.9 DBConnection.java .................................................................................. 114
5.2.1.10 LoginWindow.java................................................................................. 115
5.2.1.11 MainWindow.java ................................................................................. 121
5.2.1.12 TestUnit.java ......................................................................................... 138
5.2.2 Antarmuka Aplikasi ........................................................................................ 139
BAB VI PENUTUP ............................................................................................................. 141
7.1 Kesimpulan................................................................................................................ 141
7.2 Saran ......................................................................................................................... 141
DAFTAR PUSTAKA ........................................................................................................... 142
v
DAFTAR GAMBAR
vi
DAFTAR TABEL
Tabel 3.1 Konsep pengetahuan sistem pakar pemantau kondisi pasien rawat inap
............................................................................................................................... 30
Tabel 4.1 Identifikasi Aktor .................................................................................. 38
Tabel 4.2 Daftar kebutuhan Sistem ....................................................................... 38
Tabel 4.3 Skenario Use Case ................................................................................ 40
Tabel 4.4 Semesta Pembicaraan ............................................................................ 42
Tabel 4.5 Range Fuzzy Set SBP ........................................................................... 43
Tabel 4.6 Range Fuzzy Set Heart Rate.................................................................. 45
Tabel 4.7 Range Fuzzy Set SPO2 .......................................................................... 48
Tabel 4.8 Range Fuzzy Set Suhu ........................................................................... 49
Tabel 4.9 Range Fuzzy Set Gula Darah ................................................................. 51
Tabel 4.10 Range fuzzy set risk group .................................................................. 53
vii
DAFTAR PERSAMAAN
viii
BAB I
PENDAHULUAN
2
1.3 Batasan Masalah
1.4 Tujuan
3
1.5 Manfaat
4
BAB II Dasar Teori
Bab ini terdiri membahas teori-teori yang mendukung dalam perancangan
dan pengembangan sistem pakar pemantau kondisi pasien rawat inap
menggunakan fuzzy inferensi Tsukamoto.
BAB III Metodologi
Membahas tentang metode yang digunakan dalam penelitian sistem pakar
pemantau kondisi pasien rawat inap menggunakan fuzzy inferensi
Tsukamoto yang berupa studi literatur.
BAB IVAnalisis Kebutuhan dan Perancangan
Membahas tentang analisa kebutuhan dari sistem pakar pemantau kondisi
pasien rawat inap menggunakan fuzzy inferensi Tsukamoto dan kemudian
merancang hal-hal yang berhubungan dengan analisa tersebut.
BAB V Implementasi
Membahas tentang hasil perancangan dari analisis kebutuhan dan
implementasi sistem pakar pemantau kondisi pasien rawat inap
menggunakan fuzzy inferensi Tsukamoto.
BAB VI Penutup
Memuat kesimpulan yang diperoleh dari pembuatan dan pengujian
perangkat lunak sistem pakar pemantau kondisi pasien rawat inap
menggunakan fuzzy inferensi Tsukamoto yang dikembangkan dalam
proyek akhir ini serta saran-saran untuk pengembangan lebih lanjut.
5
BAB II
DASAR TEORI
Pelayanan rawat inap merupakan salah satu bentuk pelayanan rumah sakit
yang memberikan pelayanan kepada pasien yang perlu menginap untuk keperluan
observasi, diagnosis, pengobatan, bagi individu dengan keadaan medis tertentu,
pada kasus bedah, kebidanan, penyakit kronis atau rehabilitasi yang memerlukan
perawatan dokter setiap hari. Sedangkan DepKes 1991 membatasi pelayanan
rawat inap adalah layanan terhadap pasien masuk rumah sakit yang menempati
tempat tidur untuk keperluan observasi, diagnosis, terapi, rehabilitasi medis dan
atau pelayanan medis lainnya (Antin Yohana. 2006)
6
keahlian. Dalam hal ini sistem pakar dirancang untuk menyimpan dan
menggunakan ilmu serta pengalaman dari satu atau beberapa tenaga ahli. Untuk
itu sustu sistem pakar yang mempunyai kapasitas besar diperkirakan mampu
memecahkan suatu persoalan yang tidak dapat dipecahkan oleh satu atau
sekelompok kecil tenaga ahli [10:12-13].
Ada berbagai ciri dan karakteristik yang membedakan sistem pakar dengan
sistem yang lain. Ciri dan karakteristik ini menjadi pedoman utama dalam
pengembangan sistem pakar. Ciri dan karakteristik yang dimaksud antara lain
[2:1-3]:
1. Pengetahuan sistem pakar merupakan suatu konsep, bukan berbentuk
numeris. Hal ini dikarenakan komputer melakukan proses pengolahan data
secara numerik sedangkan keahlian dari seorang pakar adalah fakta dan
aturan-aturan, bukan numerik.
2. Informasi dalam sistem pakar tidak selalu lengkap, subyektif, tidak
konsisten, subyek terus berubah dan tergantung pada kondisi lingkungan
sehingga keputusan yang diambil bersifat tidak pasti dan tidak mutlak ya
atau tidak akan tetapi menurut ukuran kebenaran tertentu. Oleh karena
itu dibutuhkan kemampuan sistem untuk belajar secara mandiri dalam
menyelesaikan masalah-masalah dengan pertimbangan-pertimbangan
khusus.
3. Kemungkinan solusi sistem pakar terhadap suatu permasalahan adalah
bervariasi dan mempunyai banyak pilihan jawaban yang dapat diterima,
semua faktor yang ditelusuri memiliki ruang masalah yang luas dan tidak
pasti. Oleh karena itu diperlukan sistem yang fleksibel dalam menangani
kemungkinan solusi dari berbagai permasalahan.
4. Perubahan atau pengembangan pengetahuan dalam sistem pakar dapat
terjadi setiap saat bahkan sepanjang waktu sehingga diperlukan
kemudahan dalam modifikasi sistem untuk menampung jumlah
pengetahuan yang semakin besar dan semakin bervariasi.
7
5. Pandangan dan pendapat setiap pakar tidak selalu sama, oleh karena itu
tidak ada jaminan bahwa solusi sistem pakar merupakan jawaban yang
pasti benar. Setiap pakar akan memberikan pertimbangan-pertimbangan
berdasarkan faktor subyektif.
6. Keputusan merupakan bagian terpenting dari sistem pakar. Sistem pakar
harus memberikan solusi yang akurat berdasarkan masukan pengetahuan
meskipun solusinya sulit sehingga fasilitas informasi sistem harus selalu
diperlukan.
Blok diagram sistem pakar bisa dilihat pada Gambar 2.2. Pada gambar
tersebut menjelaskan bahwa sistem pakar juga dapat dilihat dari sudut pandang
lingkungan (environment) dalam sistem. Terdapat dua lingkungan yaitu
lingkungan konsultasi dan lingkungan pengembangan. Lingkungan konsultasi
diperuntukkan bagi pengguna non pakar untuk melakukan konsultasi dengan
sistem yang tujuannya adalah mendapatkan nasehat pakar. Sedangkan lingkungan
pengembangan ditujukan bagi pembangun sistem pakar untuk membangun
komponen dan memasukkan pengetahuan hasil akuisisi pengetahuan ke dalam
basis pengetahuan.
8
LINGKUNGAN KONSULTASI LINGKUNGAN PENGEMBANGAN
Basis
Fakta tentang
Pemakai Pengetahuan :
kejadian tertentu
fakta dan aturan
Antarmuka Knowledge
Fasilitas Engineer
Penjelas
Mesin Inferensi
Pakar
Aksi yang
direkomendasikan
Perbaikan
Workplace Pengetahuan
9
untuk memikirkan (reasoning) dan memformulasi kesimpulan. Kerja mesin
inferensi meliputi [11]:
1. Menentukan aturan mana akan dipakai
2. Menyajikan pertanyaan kepada pemakai, ketika diperlukan.
3. Menambahkan jawaban ke dalam memori sistem pakar.
4. Menyimpulkan fakta baru dari sebuah aturan
5. Menambahkan fakta tadi ke dalam memori
2.2.2 Rule
10
3. Fasilitas penjelasan
Sub sistem yang berfungsi untuk menyediakan penjelesan dalam sistem
reasoning.
4. Program eksternal
5. Program seperti basis data, spreadsheet, yang bekerja dalam mendukung
keseluruhan sistem.
11
fluktuasi pada variabel masukan. Pendekatan logika fuzzy secara garis besar
diimplementasikan dalam tiga tahapan yaitu [10:15-16]:
1. Tahap pengaburan (fuzzification) yakni pemetaan dari masukan tegas ke
himpunan kabur.
2. Tahap inferensi, yakni pembangkitan aturan kabur.
3. Tahap penegasan (defuzzification), yakni tranformasi keluaran dari nilai
kabur ke nilai tegas.
Fuzzy Controller
Inference
Mechanism
Reference
Defuzification
Fuzification
Rule-base
12
dengan cara himpunan klasik. Akan tetapi, bagaimana mempresentasikan
himpunan pada manusia muda atau tua. Muda atau tua itu cukup relatif tidak
langsung terpisah hanya karena berbeda satu hal. Dalam hal ini himpunan fuzzy
dapat memberikan pengelompokan dengan memberi nilai dalam derajat tertentu.
Berbeda dengan himpunan klasik, keanggotaan himpunan fuzzy dapat bernilai
parsial [6:1].
(x)
Classical (crips) set A
Fuzzy set
1.0
Membership
function (x)
0.0
X
[0,1](2-1)
pada X) yang didefinisikan oleh himpunan fuzzy A memiliki ketentuan berikut:
himpunan A dan B dinyatakan sama jika dan hanya jika (x) = (x). Jika (x)
nilai [0,1] adalah interval bilangan real dari nol sampai dengan satu. Dua
bernilai nol, berarti x bukan anggota dari himpunan fuzzy A. Jika (x) bernilai
satu, menunjukkan x adalah himpunan fuzzy A. Sementara nilai antara nol hingga
13
satu menunjukkan bahwa x merupakan anggota dari himpunan fuzzy A secara
parsial [6:1-2].
0 ;
; <
[
]
; <
<
.(2-2)
14
2. Fungsi keanggotaan yang mempunyai parameter a,b,c, dan d dengan
formulasi Trapesium (x; a, b, c, d) = max{min{(x-a)/(b-a), 1, (d-x)/(d-c)},
0}.
0 ;
"
! ; <
[
]
1 ; <
!# ; <
< "
...(2-3)
#
15
yang diambil dari keadaan pertama bukan dari keadaan yang terakhir, maka ia
akan digunakan sebagai fakta untuk disesuaikan dengan kondisi aturan JIKA yang
lain untuk mendapatkan kesimpulan yang lebih baik. Proses ini berlanjut hingga
dicapai kesimpulan akhir.
16
Aturan-1
IF-THEN Fuzzy
Crips
Input Agregasi
Aturan-n
IF-THEN Fuzzy
Fuzzy
Defuzzy
Crips
Output
Sistem inferensi fuzzy menerima input crisp. Data input kemudian dikirim
ke basis pengetahuan yang berisi n aturan fuzzy dalam bentuk IF-THEN. Fire
strength (nilai keanggotaan anteseden atau ) akan dicari pada setiap aturan. Apabila
aturan lebih dari satu, maka akan dilakukan agregasi semua aturan. Selanjutnya
pada hasil agregasi akan dilakukan defuzzy untuk mendapatkan nilai crisp sebagai
output sistem. Salah satu metode FIS yang dapat digunakan untuk pengambilan
keputusan adalah metodeTsukamoto.
Pada metode Tsukamoto, implikasi setiap aturan berbentuk implikasi
"Sebab-Akibat"/Implikasi "Input-Output" yang antara anteseden dan konsekuen harus ada
berhubungan. Setiap aturan direpresentasikan menggunakan himpunan-himpunan
fuzzy, dengan fungsi keanggotaan yang monoton. Kemudian untuk menentukan
hasil tegas (crisp solution) digunakan rumus penegasan (defuzzifikasi) yang
disebut "Metode rata-rata terpusat" atau "Metode defuzzifikasi rata-rata terpusat
(center average deffuzzyfier). Untuk lebih memahami metodeTsukamoto,
perhatikan Contoh 2.1.
Contoh 2.1: Misalkan ada 2 variabel input, Var-1 (x) dan Var-2(x), serta variabel
output, Var-3(z), dimana Var-1 terbagi atas 2 himpunan yaitu A1 dan A2. Var-2
17
terbagi atas 2 himpunan B1 dan B2, Var-3 juga terbagi atas 2 himpunan yaitu C1
dan C2 (C1 dan C2 harus monoton). Ada 2 aturan yang digunakan, yaitu:
[R1] IF (x is A1) and (y is B2) THEN (z is C1)
[R2] IF (x is A2) and (y is B1) THEN (z is C2)
Pertama-tama dicari fungsi keanggotaan dari masing-masing himpunan
fuzzy dari setiap aturan, yaitu himpunan A1, B2 dan C1 dari aturan fuzzy [R1], dan
himpunan A2, B1 dan C2 dari aturan fuzzy [R2]. Aturan fuzzy R1 dan R2 dapat
direpresentasikan dalam Gambar 2.7 untuk mendapatkan suatu nilai crisp Z.
18
keanggotaan A1 dari Var-1 dan nilai keanggotaan B2 dari Var-2. Demikian pula
nilai keanggotaan anteseden dari aturan fuzzy [R2] adalah nilai minimum antara
nilai keanggotaan A2 dari Var-1 dengan nilai keanggotaan B1 dari Var-2.
Selanjutnya, nilai keanggotaan anteseden dari aturan fuzzy [R1] dan [R2]
masing-masing disebut dengan 1 dan 2. Nilai 1 dan 2 kemudian disubstitusikan
pada fungsi keanggotaan himpunan C1 dan C2 sesuai aturan fuzzy [R1] dan [R2]
untuk memperoleh nilai z1 dan z2, yaitu nilai z (nilai perkiraan produksi) untuk
aturan fuzzy [R1] dan [R2]. Nilai output crisp/nilai tegas Z dapat diperoleh
dengan cara mengubah input (berupa himpunan fuzzy yang diperoleh dari
komposisi aturan-aturan fuzzy) menjadi suatu bilangan pada domain himpunan
fuzzy tersebut. Cara ini disebut dengan metode defuzzifikasi(penegasan). Metode
defuzzifikasi yang digunakan dalam metode Tsukamoto adalah metode
defuzzifikasi rata-rata terpusat (center average defuzzyfier).
19
menggunakan teknologi seperti Enterprise JavaBeans. Dan Java adalah pilihan
platform untuk aplikasi terdistribusi modern.
Bibit Java ditanam pada tahun 1990 oleh kepala peneliti Sun
Microsystems yaitu Bill Joy. Sun telah mendorong suatu ide sejak permulaan Sun
di awal tahun 1980: Jaringan adalah computer. Sun berkompetisi dalam
workstation market yang relatif kecil pada waktu itu, sedangkan Microsoft
memulai dominasi dari dunia PC berbasis Intel. Saat Sun ketinggalan dalam
revolusi PC, Joy ditarik ke Aspen, Colorado, untuk bekerja pada penelitian yang
lebih lanjut. Ia berkomitmen untuk menyelesaikan tugas kompleks dengan
perangkat lunak sederhana, dan menemukan yang tepatnya disebut Sun Aspen
Smallworks.
Dari anggota asli tim programmer kecil yang dibentuk di Aspen, James
Gosling yang akan diingat sebagai bapak Java. Gosling pertama kali melejitkan
namanya di awal tahun 1980 sebagai penulis Gosling Emacs, versi pertama dari
editor Emacs populer yang ditulis bengan bahasa C dan dijalankan dibawah
Unix. Gosling Emacs menjadi populer, namun kemudian tertutup oleh versi
gratis, GNU Emacs, yang ditulis oleh desainer asli Emacs. Gosling telah pindah
untuk mendesain sistem window NeWS dari Sun pada waktu itu.
Mendesain NeWS mengajarkan Gosling kekuatan dari integrasi bahasa
ekspresif dengan network-aware windowing GUI. Hal tersebut juga mengajarkan
Sun bahwa komunitas pemrograman internet akan menolak untuk menerima
standar hak milik, tidak peduli seberapa bagus hal tersebut nantinya. Bibit dari
skema lisensi permissive disebarkan oleh kegagalan NeWS. Gosling membawa
apa yang telah ia pelajari ke proyek Aspen baru milik Bill Joy, dan pada 1992,
bekerja pada proyek memimpin ke penemuan cabang Sun, FirstPerson, Inc.
Misinya adalah untuk memimpin Sun menuju dunia elektronik consumer.
Tim FirstPerson bekerja pada mengembangkan perangkat lunak untuk alat
informasi, seperti telepon seluler dan personal digital assistants (PDAs).
Tujuannya adalah untuk meng-enable transfer informasi dan aplikasi real-time
melalui infrared murah dan jaringan berbasis paket. Limitasi memori dan
bandwidth mendiktekan kode kecil dan efisien. Basis dari aplikasi juga menuntut
mereka untuk menjadi aman dan kuat. Gosling dan anggota timnya memulai
20
memrogram di C++, namun mereka kemudian terkepung dalam bahasa yang
terlalu kompleks, berat, dan tidak aman untuk tugasnya. Mereka memutuskan
untuk memulai dari awal, dan Gosling memulai bekerja pada sesuatu yang ia
juluki C++ minus minus.
Telah menjadi kenyataan bahwa bahtera PDA belum sampai dengan
tenggelamnya Apple Newton, jadi Sun mengalihkan usaha FirstPerson ke TV
interaktif (ITV). Bahasa pemrograman terpilih untuk ITV merupakan nenek
moyang dekat dari Java, yaitu Oak. Oak tidak mampu menyelamatkan penyebab
hilangnya ITV bahkan dengan keeleganannya dan kemampuannya untuk
menyediakan interaktifitas aman. Pelanggan tidak menginginkannya, dan Sun
kemudian mengabaikan konsep tersebut.
Joy dan Gosling berkolaborasi untuk memutuskan strategi baru untuk
bahasa mereka pada waktu itu. Pada waktu itu di tahun 1993, terjadi ledakan
interest di internet, khususnya World Wide Web, yang mempersembahkan
kesempatan baru. Oak adalah bahasa pemrograman yang kecil, kuat,
architecture-independent, dan berorientasi obyek. Selama hal tersebut terjadi,
terdapat pula kebutuhan untuk bahasa pemrograman yang universal dan pandai-
jaringan (network-savvy). Sun dengan cepat mengubah fokus, dengan sedikit
melengkapi kembali, Oak menjadi Java [4 : 10]
21
kesehatan untuk memberikan masukan ke dalam situasi pasien termasuk
memberikan rekomendasi. SBAR memberikan kesempatan untuk diskusi antara
anggota tim kesehatan atau tim kesehatan lainnya.
Keuntungan dari penggunaan metode SBAR adalah[14:6-7]:
1. Kekuatan perawat berkomunikasi secara efektif.
2. Dokter percaya pada analisa perawat karena menunjukkan perawat paham
akan kondisi pasien.
3. Memperbaiki komunikasi sama dengan memperbaiki keamanan pasien.
Komunikasi efektif SBAR dapat diterapkan oleh semua tenaga kesehatan,
diharapkan semua tenaga kesehatan maka dokumentasi tidak terpecah sendiri-
sendiri. Diharapkan dokumentasi catatan perkembangan pasien terintegrasi
dengan baik. sehingga tenaga kesehatan lain dapat mengetahui perkembangan
pasien.
1. Situation: Bagaimana situasi yang akan dibicarakan/dilaporkan?
- Mengidentifikasi nama diri petugas dan pasien.
- Diagnosa medis
- Apa yang terjadi dengan pasien yang memprihatinkan
2. Background: Apa latar belakang informasi klinis yang berhubungan dengan
situasi?
- Obat saat ini dan alergi
- Tanda-tanda vital terbaru
- Hasil laboratorium: tanggal dan waktu tes dilakukan dan hasil tes
sebelumnya untuk perbandingan
- Riwayat medis
- Temuan klinis terbaru
3. Assessment: berbagai hasil penilaian klinis perawat
- Apa temuan klinis?
- Apa analisis dan pertimbangan perawat
- Apakah masalah ini parah atau mengancam kehidupan?
4. Recommendation: apa yang perawat inginkan terjadi dan kapan?
- Apa tindakan/rekomendasi yang diperlukan untuk memperbaiki masalah?
- Apa solusi yang bisa perawat tawarkan dokter?
22
- Apa yang perawat butuhkan dari dokter untuk memperbaiki kondisi
pasien?
- Kapan waktu yang perawat harapkan tindakan ini terjadi?
Sebelum serah terima pasien, perawat harus melakukan [14:8]:
1. Perawat mendapatkan pengkajian kondisi pasien terkini.
2. Perawat mengkumpulkan data-data yang diperlukan yang berhubungan
dengan kondisi pasien yang akan dilaporkan.
3. Perawat memastikan diagnosa medis pasien dan prioritas masalah
keperawatan yang harus dilanjutkan.
4. Perawat membaca dan pahami catatan perkembangan terkini & hasil
pengkajian perawat shift sebelumnya.
5. Perawat menyiapkan medical record pasien termasuk rencana perawat harian.
23
BAB III
METODOLOGI PENELITIAN
Pada bab ini akan dibahas tentang langkah-langkah yang akan dilakukan
dalam penyusunan proyek akhir mata kuliah Logika Fuzzy, yang meliputi: studi
literatur, pengumpulan data, analisa dan perancangan, implementasi, pengujian
sistem, pembuatan laporan. Berikut adalah diagram alir dari metode penelitian
yang dilakukan.
24
3.1 Studi Literatur
Lokasi penelitian proyek akhir ini adalah Rumah Sakit Umum Lavalette
Malang. Hipotesis penelitian ini merancang, membangun, dan
mengimplementasikan sistem pakar pemantau kondisi pasien rawat inap
menggunakan fuzzy inferensi Tsukamotto. Pengumpulan data pada penelitian ini
menggunakan data primer. Data primer adalah data yang didapatkan langsung dari
sumber penelitian. Pengumpulan data primer dapat dilakukan menggunakan
wawancara, kuisioner maupun observasi.
25
perspektif end-user. Analisis kebutuhan dilakukan dengan mengidentifikasi semua
kebutuhan (requirements) sistem.
Sumber data yang digunakan berasal rumah sakit Lavalette. Data yang
dimaksud adalah sistem pemantauan kondisi pasien rawat inap yang sudah ada di
rumah sakit Lavalette sebagai acuan dalam pengembangan aplikasi dan
perancangan sistem. Selain itu, diperlukan juga kuisioner, untuk menentukan
kebutuhan pasien dan tenaga medis dalam sistem yang diinginkan. Data-data
tersebut digunakan untuk menghitung tingkat keberhasilan dari sistem. Diagram
alir untuk pengambilan data sampel ditunjukkan pada Gambar 3.2.
26
2. Spesifikasi Kebutuhan Software
a. Linux distribusi Ubuntu 12.04 sebagai sistem operasi yang
digunakan.
b. MySql sebagai sistem manajemen database.
c. Bahasa Java dipilih untuk membangun aplikasi.
27
Gambar 3.3 Arsitektur Sistem Pakar Pemantau kondisi Rawat Inap
Sumber: Perancangan
Proses yang dapat dijelaskan dari arsitektur sistem pakar pemantau kondisi
pasien rawat inap yakni, pertama perawat akan memasukkan data PHR (Personal
Healt Record) yang meliputi tekanan darah, heart rate, suhu, gula darah dan
tingkat kejenuhan oksigen (SPO2) ke dalam sistem. Selanjutnya, masuan tersebut
akan menentukan rekomendasi tindakan dari tenaga medis yang sesuai.
Proses interaksi user dengan sistem dilakukan melalui antarmuka
pengguna. Pada antarmuka juga dilengkapi dengan fasilitas penjelas yang
memberikan penjelasan bagaimana hasil kesimpulan diperoleh sehingga dapat
meyakinkan pengguna. Kesimpulan yang diperoleh dari input yang diberikan
berupa rekomendasi tindakan yang harus dilakukan oleh tenaga medis yang sesuai
dengan kondisi pasien saat itu.
28
Pakar mengambil peranan sangat aktif dalam pembuatan basis
pengetahuan. Tempat kerja disediakan bagi pakar untuk membantu memberikan
solusi bagi permasalahan saat sistem dijalankan dan menyedikan fasilitas untuk
menulis agenda dan deskripsi terhadap permasalahan khusus yang belum
diprediksi. Knowledge engineer bertanggung jawab membuat kesan yang tepat,
secara positif mengomunikasikan informasi tentang proyek, memahami tipe
pakar, mempersiapkan sesi, dan seterusnya.
Metode akuisisi pengetahuan yang digunakan adalah metode manual, yang
terdiri dari:
1. Metode wawancara terstuktur
Teknik wawancara melibatkan dialog langsung antara pakar dan
knowledge engineer. Informasi dikumpulkan dengan bantuan instrumen
konvensional (misalnya tape recorder atau kuisioner) dan selanjutnya
ditranskip, dianalisis dan dikodekan. Metode wawancara terstruktur
adalah proses berorientasi tujuan yang sistematik. Proses berorientasi
tujuan menekankan komunikasi terorganisasi antara knowledge engineer
dan pakar. Struktur sistematik mengurangi persoalan interpretasi yang
inheren dan memungkinkan knowledge engineer mencegah distorsi yang
disebabkan oleh subjektivitas pakar domain.
2. Metode analisis kasus
Pada metode analisis kasus, pakar ditanya bagaimana mereka menangani
kasus khusus di masa sebelumnya. Biasanya metode ini melibatkan
analisis dokumentasi .
Basis pengetahuan sistem pakar ini berisi pengetahuan setara pakar yang
telah diisi oleh knowledge engineer. Basis pengetahuan berisi fakta tindakan-
tindakan yang harus dilakukan seorang tenaga medis yang sesuai dengan kondisi
pasien serta aturan yang berhubungan dengan metode fuzzy. Representasi yang
digunakan yaitu aturan produksi, karena pada basis pengetahuan digunakan aturan
pengetahuan sedangkan pada mesin inferensi dapat digunakan aturan inferensi
dengan menerapkan metode fuzzy.
29
Konsep pengetahuan yang dibangun terdiri dari atribut dan alternatif yang
dibutuhkan. Atribut yang diperlukan disesuaikan dengan data input PHR.
Alternatif yang dihasilkan sesuai dengan yang ditentukan pada batasan masalah.
Konsep pengetahuan yang dibangun, digambarkan pada Tabel 3.1.
Tabel 3.1 Konsep pengetahuan sistem pakar pemantau kondisi pasien rawat inap
Minimum
Total Score Observation Alert Response
Frequency
30
Note: Single score triggers
1. Perawat
31
Proses penggunaan aplikasi saat log in sebagai perawat harus melakukan
log in untuk bisa masuk ke sistem. Setelah masuk ke sistem perawat harus
memasukan data PHR. Pada tahap selanjutnya proses akan berlangsung
secara otomatis. Masukan akan diproses dengan metode fuzzy sehingga
akan ditampilkan penjelasan pengambilan kesimpulan dan analisis dari
pakar.
32
Proses inferensi dilakukan dengan menerapkan metode TOPSIS, sehingga
diperoleh kesimpulan dari fakta yang diketahui.
2. Pakar
Proses penggunaan aplikasi dari segi pakar dimulai dari pakar melakukan
log in. Setelah masuk sebagai pakar, akan muncul halaman utama. Pada
halaman utama, pakar dapat melihat data-data masukan PHR dan data
rekomendasi hasil analisis dari sistem. Selanjutnya terhadapa menu untuk
pakar mengedit data. Edit data dimaksudkan untuk mengubah data dan
atau menambahkan data hasil analisis dari sistem. Data yang telah
diakusisi oleh pakar akan ditampilkan sebagai hasil akhir.
33
3.5 Implementasi Sistem
1. Pengujian akurasi
Melakukan pengujian berdasarkan implementasi yang telah dibuat
melalui perhitungan akurasi. Perhitungan akurasi digambarkan pada
diagram alir berikut.
34
Pada Gambar 3.6, pertama dilakukan perhitungan antara data hasil
keluaran dari sistem dengan hasil keluaran yang diberikan oleh pakar
yang menggunakan proses manual. Proses manual pakar adalah proses
yang biasa dilakukan pakar untuk memberi keluaran dengan
subjektifitas pakar kesahatan. Hasil akurasi yang didapat akan
digunakan sebagai acuan sebagai hasil akhir akurasi.
2. Pengujian fungsional sistem
Pengujian fungsional sistem berfungsi untuk mengetahui kinerja sistem
sesuai dengan rancangan dan tujuan yang dibuat. Berikut ini adalah
diagram alir pengujian fungsional dari sistem pakar pemilihan bidang
studi.
35
Pengujian fungsional ini dilakukan dengan memeriksa keterpenuhan
fungsional sistem pada aplikasi sistem pakar yang dibuat.
36
BAB IV
PERANCANGAN
Pada bab ini akan dibahas tentang perancangan sistem pakar untuk
pemantau kondisi pasien rawat inap. Tahap perancangan sistem terdiri dari
analisis kebutuhan perangkat lunak dan perancangan sistem pakar. Tahap analisis
kebutuhan perangkat lunak meliputi identifikasi aktor, daftar kebutuhan sistem,
dan use case diagram serta skenario use case. Sedangkan tahap perancangan
sistem pakar meliputi akuisisi pengetahuan, basis pengetahuan, mesin inferensi,
dan sub sistem antarmuka. Berikut ilustrasi pohon perancangan Sistem Pakar
Pemantau Kondisi Pasien Rawat Inap Menggunakan Fuzzy Inferensi Tsukamoto.
4.2.4 Subsistem
Antarmuka
37
4.1 Analisa Kebutuhan Perangkat Lunak
38
Sistem harus User
User
User
User
Sumber: Perancangan
Use case diagram merupakan salah satu diagram yang digunakan untuk
menggambarkan kebutuhan-kebutuhan dan fungsionalitas dari sistem serta
digunakan untuk menunjukan aksi-aksi yang dilakukan oleh aktor dari sistem.
Gambar 4.2 merupakan diagram use case sistem pakar yang menunjukkan
spesifikasi fungsionalitas yang disediakan oleh sistem dari segi aktor Admin dan
User.
Calculate
Reset
Lihat Hasil
Lihat Rule
User
Remove Rule
39
Sumber: Perancangan
Dalam sistem ini aktor dapat memasukkan kondisi pasien. Selain itu aktor
juga dapat mengkalkulasi hasil dari inputan kondisi pasien. Secara otomatis
sistem akan menyimpan hasil-hasil analisa sistem pakar serta dapat melihat rule.
Disamping itu user dapat mengatur ulang input kondisi pasien serta menghapus
rule.
Use case yang telah digambarkan dalam diagram use case akan lebih
dijelaskan secara terperinci dalam skenario use case. Penggunaan skenario use
case ini bertujuan untuk mendapatkan deskripsi secara global mengenai use case,
kondisi awal dan akhir yang harus dipenuhi oleh use case setelah fungsionalitas
telah dijalankan. Dalam Tabel 4.3 akan menjelaskan bagaimana tanggapan sistem
terhadap aksi yang dilakukan oleh aktor.
40
Aktor melihat hasil data Sistem menampilkan hasil proses
sebelumnya. data yang dimasukkan sebelumnya.
Aktor mereset hasil data. Sistem mereset hasil data.
Sumber: Perancangan
Berikut ini dijelaskan tentang perancangan sistem pakar yang terdiri dari
akuisisi pengetahuan, basis pengetahuan, mesin inferensi, dan subsistem
antarmuka.
41
4.2.2.1 Himpunan Bahasa Variable
Himpunan bahasa variabel pada sistem pakar pemantau kondisi pasien
rawat inap adalah sebagai berikut
42
diukur. Untuk fuzzify variabel SBP, harus ditentukan range nilai untuk SBP.
Ditentukan nilai SBP menjadi 100 sampai 185mm Hg (mungkin, tidak semua
orang setuju dengan hal ini, pilihan ini berdasarkan pengalaman ahli). Dengan
demikian kita membuat himpunan fuzzy berlabel Normal-0 dan menetapkan nilai-
nilai SBP antara 101 dan 199 mm Hg ke tingkat keanggotaan dari 1,0 di set ini.
Selanjutnya kita mengatasi masalah lebih jelas dari apa yang kisaran nilai untuk
SBP mungkin bisa normal, tetapi juga menjadi abnormal. Setiap saran ahli,
kisaran 185-199 diputuskan untuk berada di ujung atas dan 95 sampai 100 di
ujung bawah pertama. Dengan kata lain, jika SBP di atas 199 mm Hg, itu terlalu
tinggi (yang diberi label High-2 pada fuzzy set), pilihan terbaik adalah rentang
nilai antara 185 dan 199 mm Hg. Tabel fungsi keanggotaan dan grafik fuzzy set
dan variabel SBP secara berturut-turut ditunjukkan pada Tabel 4.5 dan Gambar
4.3.
43
SBP
1.2
1
Low-3
0.8
Low-2
0.6
Low-1
0.4
Normal-0
0.2
High-2
0
0 50 100 150 200 250
$%&' [
] =
1,
< 70
)+,+- , 70
< 75 ...........................................................(4-1)
+,
0, 75
$%&/ [ ] =
+,+- , 70
< 75
+-
! 1, 75
< 80
, 80
< 85
1,
! 1,1-
........................................................(4-2)
0, 70 85
44
$%&2 [
] =
1,1- , 80
< 85
1-
! 1, 85
< 95
, 95
< 100
2--
!2--4,
.....................................................(4-3)
0, 80 100
5%678- [ ] =
0, 95 199
9:;</ [ ] =
)
24421,
1,
199
0,
< 185
.....................................................(4-5)
45
53 - 100 Normal-0
95 - 110 High-1
105 - 130 High-2
>125 High-3
Sumber: Perancangan
HR
1.2
Low-2
1
0.8 Low-1
0.6 Normal-0
0.4 High-1
0.2 High-3
0
High-2
0 50 100 150 200
$%&/ [
] =
1,
< 45
),->, , 45
< 50 .............................................................(4-6)
,-
0, 50
$%&2 [ ] =
,'>, , 45
< 50
>,
! 1, 50
< 53
, 53
< 60
@-
! @-,'
.........................................................(4-7)
0, 45 60
46
5%678- [
] =
@-,' , 53
< 60
,'
! 1, 60
< 95
, 95
< 100
2--
!2--4,
.................................................(4-8)
0, 53 100
9:;<2 [ ] =
0, 95 110
9:;</ [ ] =
9:;<' [ ] =
)
2'-2/,
1,
130
0,
< 125
..................................................(4-11)
47
sebagai Normal-0. Pada table ini fuzzy set didefinisikan. Fungsi keanggotaan dari
fuzzy set adalah trapesium dan ditunjukkan pada Gambar 4.5.
SPO2
1.2
1
0.8 Low-3
0.6 Low-2
0.4 Low-1
0.2 Normal-0
0
0 50 100 150
$%&' [
] =
1,
< 83
)1,1' , 83
< 85 ...........................................................(4-12)
1,
0, 85
48
$%&/ [
] =
1,1' , 83
< 85
1'
! 1, 85
< 87
, 87
< 90
4-
! 4-1+
.......................................................(4-13)
0, 83 90
$%&2 [ ] =
4-1+ , 87
< 90
1+
! 1, 90
< 93
, 93
< 95
4,
! 4,4'
.......................................................(4-14)
0, 87 95
5%678- [
] =
, 93
< 95
4'
)
4,4'
1,
95
0,
< 93
......................................................(4-15)
49
TEMP
1.2
0.8
Low-2
0.6
Normal-0
0.4 High-2
0.2
0
0 10 20 30 40 50
$%&/ [
] =
1,
< 36
)'@.,'@ , 36
< 36.5 .....................................................(4-16)
'@.,
0, 36.5
5%678- [ ] =
! 1, 36.5
< 38
, 38
< 38.5
'1.,
! '1.,'1
............................................(4-17)
0, 36 38.5
9:;</ [ ] =
, 38
< 38.5
'1
)
'1.,'1
1,
38.5
0,
< 38
.....................................................(4-18)
50
4.2.2.7 Fungsi Derajat Keanggotaan Variabel Gula Darah
Gula darah merupakan faktor yang sangat penting. Input field ini memiliki
lima fuzzy set (Low-3, Low-2, Normal-0, High-2, dan High-3). Dalam sistem ini,
Telah ditetapkan bahwa jika nilai jumlah gula darah lebih rendah dari 66 (<66)
maka pasien memiliki gula darag rendah (Low-3), jika lebih tinggi dari 140
(>140) maka pasien memiliki gula darah yang sangat tinggi (High-3), dan set
lainnya ditunjukkan pada tabel dibawah ini. Gambar 4.7 menunjukkan fungsi
keanggotaan gula darah. Fungsi keanggotaan dari fuzzy set ini adalah trapesium.
BS
1.2
1 Low-3
0.8 Low-2
0.6
Normal-0
0.4
0.2 High-2
0 High-3
0 100 200 300 400 500
51
Fungsi Derajat Keanggotaan Gula Darah
$%&' [
] =
1,
< 63
)@@@' , 63
< 66 ...........................................................(4-19)
@@
0, 66
$%&/ [ ] =
@@@' , 63
< 66
@'
! 1, 66
< 70
, 70
< 72
+/
! +/+-
.......................................................(4-20)
0, 63 72
5%678- [
] =
, 70
< 72
+-
!
+/+-
1, 72
< 106
, 106
< 110
22-
!22-2-@
...........................................(4-21)
0, 70 110
9:;</ [ ] =
9:;<' [ ] =
)
2,-2>-
1,
150
0,
< 140
..................................................(4-23)
52
4.2.2.8 Fungsi Derajat Keanggotaan Output
Pada subseksi ini menjelaskan output dari sistem logika fuzzy. Terdapat
satu output variabel Risk Group, yang mengarahkan ketingkat kemungkinan
kondisi pasien. Range-nya dari 0 sampai 14. Nilai tertinggi adalah nilai resiko
kesehatan tertinggi pasien. Sistem ini mempunyai 15 fuzzy set untuk output
variabel risk group yaitu NRM, LRG1, LRG2, LRG3, LRG4, HRG5, HRG6,
HRG7, HRG8, HRG9, HRG10, HRG11, HRG12, HRG13, dan HRG14.
Membership functions pada variabel ini adalah trapesium. Detail membership
Functions dapat dilihat pada Tabel 4.10 dan Gambar 4.8
53
Risk Group
1.2
NRM
1 LRG1
LRG2
0.8
LRG3
0.6 LRG4
HRG5
0.4
HRG6
0.2 HRG7
HRG8
0
HRG9
-1 4 9 14
, 0
< 0.5
-.,
5DE [
] = F -.,-
0,
0
0.5
...............................................(4-24)
$DG2 [ ] =
, 0.5
< 1
-.,
2-.,
H 2., , 1
< 1.5 .....................................................(4-25)
2.,2
0,
0.5
1.5
$DG/ [ ] =
, 1.5
< 2
2.,
/2.,
H /., , 2
< 2.5 .....................................................(4-26)
/.,/
0,
1.5
2.5
54
$DG' [
] =
, 2.5
< 3
/.,
'/.,
H '., , 3
< 3.5 .....................................................(4-27)
'.,'
0,
2.5
3.5
$DG> [ ] =
, 3.5
< 4
'.,
>'.,
H >., , 4
< 4.5 .....................................................(4-28)
>.,>
0,
3.5
4.5
9DG, [ ] =
, 4.5
< 5
>.,
,>.,
H ,., , 5
< 5.5 .....................................................(4-29)
,.,,
0,
4.5
5.5
9DG@ [ ] =
, 5.5
< 6
,.,
@,.,
H @., , 6
< 6.5 .....................................................(4-30)
@.,@
0,
5.5
6.5
9DG+ [ ] =
, 6.5
< 7
@.,
+@.,
H +., , 7
< 7.5 .....................................................(4-31)
+.,+
0,
6.5
7.5
55
9DG1 [
] =
, 7.5
< 8
+.,
1+.,
H 1., , 8
< 8.5 .....................................................(4-32)
1.,1
0,
7.5
8.5
9DG4 [ ] =
, 8.5
< 9
1.,
41.,
H 4., , 9
< 9.5 .....................................................(4-33)
4.,4
0,
8.5
9.5
9DG2- [
] =
, 9.5
< 10
4.,
2-4.,
H 2-., , 10
< 10.5 ................................................(4-34)
2-.,2-
0,
9.5
10.5
9DG22 [ ] =
, 10.5
< 11
2-.,
222-.,
H 22., , 11
< 11.5 .............................................(4-35)
22.,22
0,
10.5
11.5
9DG2/ [ ] =
, 11.5
< 12
22.,
2/22.,
H 2/., , 12
< 12.5 ............................................(4-36)
2/.,2/
0,
11.5
12.5
56
9DG2' [
] =
, 12.5
< 13
2/.,
2'2/.,
H 2'., , 13
< 13.5 .............................................(4-37)
2'.,2'
0,
12.5
13.5
9DG2> [ ] =
, 13.5
< 14
2'.,
F2>2'.,
0,
13.5
................................................(4-38)
4.2.2.9 Rule
Rule merupakan serangkaian aturan yang digunakan sebagai dasar
perhitungan yang akan dilakukan dalam metode fuzzy Tsukamoto. Dibawah ini
adalah rule yang dibuat oleh pakar untuk Sistem Pakar Pemantau Kondisi Pasien
Rawat Inap Menggunakan Fuzzy Inferensi Tsukamoto.
57
10. If SBP=low3 and HR=low2 and SPO2=low3 and TEMP=normal and
BS=high3 THEN EWS SCORE=11
11. If SBP=low3 and HR=low2 and SPO2=low3 and TEMP=high2 and
BS=low3 THEN EWS SCORE=13
12. If SBP=low3 and HR=low2 and SPO2=low3 and TEMP=high2 and
BS=low2 THEN EWS SCORE=12
13. If SBP=low3 and HR=low2 and SPO2=low3 and TEMP=high2 and
BS=normal THEN EWS SCORE=10
14. If SBP=low3 and HR=low2 and SPO2=low3 and TEMP=high2 and
BS=high2 THEN EWS SCORE=12
15. If SBP=low3 and HR=low2 and SPO2=low3 and TEMP=high2 and
BS=high3 THEN EWS SCORE=13
16. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=low2 and
BS=low3 THEN EWS SCORE=12
17. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=low2 and
BS=low2 THEN EWS SCORE=11
18. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=low2 and
BS=normal THEN EWS SCORE=9
19. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=low2 and
BS=high2 THEN EWS SCORE=11
20. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=low2 and
BS=high3 THEN EWS SCORE=12
21. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=normal and
BS=low3 THEN EWS SCORE=10
22. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=normal and
BS=low2 THEN EWS SCORE=9
23. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=normal and
BS=normal THEN EWS SCORE=7
24. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=normal and
BS=high2 THEN EWS SCORE=9
25. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=normal and
BS=high3 THEN EWS SCORE=10
26. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=high2 and
BS=low3 THEN EWS SCORE=12
27. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=high2 and
BS=low2 THEN EWS SCORE=11
28. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=high2 and
BS=normal THEN EWS SCORE=9
29. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=high2 and
BS=high2 THEN EWS SCORE=11
58
30. If SBP=low3 and HR=low2 and SPO2=low2 and TEMP=high2 and
BS=high3 THEN EWS SCORE=12
31. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=low2 and
BS=low3 THEN EWS SCORE=11
32. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=low2 and
BS=low2 THEN EWS SCORE=10
33. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=low2 and
BS=normal THEN EWS SCORE=8
34. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=low2 and
BS=high2 THEN EWS SCORE=10
35. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=low2 and
BS=high3 THEN EWS SCORE=11
36. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=normal and
BS=low3 THEN EWS SCORE=9
37. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=normal and
BS=low2 THEN EWS SCORE=8
38. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=normal and
BS=normal THEN EWS SCORE=6
39. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=normal and
BS=high2 THEN EWS SCORE=8
40. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=normal and
BS=high3 THEN EWS SCORE=9
41. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=high2 and
BS=low3 THEN EWS SCORE=11
42. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=high2 and
BS=low2 THEN EWS SCORE=10
43. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=high2 and
BS=normal THEN EWS SCORE=8
44. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=high2 and
BS=high2 THEN EWS SCORE=10
45. If SBP=low3 and HR=low2 and SPO2=low1 and TEMP=high2 and
BS=high3 THEN EWS SCORE=11
46. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=low2 and
BS=low3 THEN EWS SCORE=10
47. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=low2 and
BS=low2 THEN EWS SCORE=9
48. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=low2 and
BS=normal THEN EWS SCORE=7
49. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=low2 and
BS=high2 THEN EWS SCORE=9
59
50. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=low2 and
BS=high3 THEN EWS SCORE=10
51. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=normal and
BS=low3 THEN EWS SCORE=8
52. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=normal and
BS=low2 THEN EWS SCORE=7
53. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=normal and
BS=normal THEN EWS SCORE=5
54. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=normal and
BS=high2 THEN EWS SCORE=7
55. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=normal and
BS=high3 THEN EWS SCORE=8
56. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=high2 and
BS=low3 THEN EWS SCORE=10
57. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=high2 and
BS=low2 THEN EWS SCORE=9
58. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=high2 and
BS=normal THEN EWS SCORE=7
59. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=high2 and
BS=high2 THEN EWS SCORE=9
60. If SBP=low3 and HR=low2 and SPO2=normal and TEMP=high2 and
BS=high3 THEN EWS SCORE=10
61. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=low2 and
BS=low3 THEN EWS SCORE=12
62. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=low2 and
BS=low2 THEN EWS SCORE=11
63. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=low2 and
BS=normal THEN EWS SCORE=9
64. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=low2 and
BS=high2 THEN EWS SCORE=11
65. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=low2 and
BS=high3 THEN EWS SCORE=12
66. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=normal and
BS=low3 THEN EWS SCORE=10
67. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=normal and
BS=low2 THEN EWS SCORE=9
68. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=normal and
BS=normal THEN EWS SCORE=7
69. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=normal and
BS=high2 THEN EWS SCORE=9
60
70. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=normal and
BS=high3 THEN EWS SCORE=10
71. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=high2 and
BS=low3 THEN EWS SCORE=12
72. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=high2 and
BS=low2 THEN EWS SCORE=11
73. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=high2 and
BS=normal THEN EWS SCORE=9
74. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=high2 and
BS=high2 THEN EWS SCORE=11
75. If SBP=low3 and HR=low1 and SPO2=low3 and TEMP=high2 and
BS=high3 THEN EWS SCORE=12
76. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=low2 and
BS=low3 THEN EWS SCORE=11
77. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=low2 and
BS=low2 THEN EWS SCORE=10
78. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=low2 and
BS=normal THEN EWS SCORE=8
79. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=low2 and
BS=high2 THEN EWS SCORE=10
80. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=low2 and
BS=high3 THEN EWS SCORE=11
81. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=normal and
BS=low3 THEN EWS SCORE=9
82. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=normal and
BS=low2 THEN EWS SCORE=8
83. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=normal and
BS=normal THEN EWS SCORE=6
84. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=normal and
BS=high2 THEN EWS SCORE=8
85. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=normal and
BS=high3 THEN EWS SCORE=9
86. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=high2 and
BS=low3 THEN EWS SCORE=11
87. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=high2 and
BS=low2 THEN EWS SCORE=10
88. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=high2 and
BS=normal THEN EWS SCORE=8
89. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=high2 and
BS=high2 THEN EWS SCORE=10
61
90. If SBP=low3 and HR=low1 and SPO2=low2 and TEMP=high2 and
BS=high3 THEN EWS SCORE=11
91. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=low2 and
BS=low3 THEN EWS SCORE=10
92. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=low2 and
BS=low2 THEN EWS SCORE=9
93. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=low2 and
BS=normal THEN EWS SCORE=7
94. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=low2 and
BS=high2 THEN EWS SCORE=9
95. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=low2 and
BS=high3 THEN EWS SCORE=10
96. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=normal and
BS=low3 THEN EWS SCORE=8
97. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=normal and
BS=low2 THEN EWS SCORE=7
98. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=normal and
BS=normal THEN EWS SCORE=5
99. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=normal and
BS=high2 THEN EWS SCORE=7
100. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=normal
and BS=high3 THEN EWS SCORE=8
101. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=high2
and BS=low3 THEN EWS SCORE=10
102. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=high2
and BS=low2 THEN EWS SCORE=9
103. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=high2
and BS=normal THEN EWS SCORE=7
104. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=high2
and BS=high2 THEN EWS SCORE=9
105. If SBP=low3 and HR=low1 and SPO2=low1 and TEMP=high2
and BS=high3 THEN EWS SCORE=10
106. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=low2
and BS=low3 THEN EWS SCORE=9
107. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=low2
and BS=low2 THEN EWS SCORE=8
108. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=low2
and BS=normal THEN EWS SCORE=6
109. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=low2
and BS=high2 THEN EWS SCORE=8
62
110. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=low2
and BS=high3 THEN EWS SCORE=9
111. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=normal
and BS=low3 THEN EWS SCORE=7
112. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=normal
and BS=low2 THEN EWS SCORE=6
113. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=normal
and BS=normal THEN EWS SCORE=4
114. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=normal
and BS=high2 THEN EWS SCORE=6
115. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=normal
and BS=high3 THEN EWS SCORE=7
116. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=high2
and BS=low3 THEN EWS SCORE=9
117. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=high2
and BS=low2 THEN EWS SCORE=8
118. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=high2
and BS=normal THEN EWS SCORE=6
119. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=high2
and BS=high2 THEN EWS SCORE=8
120. If SBP=low3 and HR=low1 and SPO2=normal and TEMP=high2
and BS=high3 THEN EWS SCORE=9
121. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=low2
and BS=low3 THEN EWS SCORE=11
122. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=low2
and BS=low2 THEN EWS SCORE=10
123. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=low2
and BS=normal THEN EWS SCORE=8
124. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=low2
and BS=high2 THEN EWS SCORE=10
125. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=low2
and BS=high3 THEN EWS SCORE=11
126. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=normal
and BS=low3 THEN EWS SCORE=9
127. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=normal
and BS=low2 THEN EWS SCORE=8
128. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=normal
and BS=normal THEN EWS SCORE=6
129. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=normal
and BS=high2 THEN EWS SCORE=8
63
130. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=normal
and BS=high3 THEN EWS SCORE=9
131. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=high2
and BS=low3 THEN EWS SCORE=11
132. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=high2
and BS=low2 THEN EWS SCORE=10
133. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=high2
and BS=normal THEN EWS SCORE=8
134. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=high2
and BS=high2 THEN EWS SCORE=10
135. If SBP=low3 and HR=normal and SPO2=low3 and TEMP=high2
and BS=high3 THEN EWS SCORE=11
136. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=low2
and BS=low3 THEN EWS SCORE=10
137. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=low2
and BS=low2 THEN EWS SCORE=9
138. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=low2
and BS=normal THEN EWS SCORE=7
139. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=low2
and BS=high2 THEN EWS SCORE=9
140. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=low2
and BS=high3 THEN EWS SCORE=10
141. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=normal
and BS=low3 THEN EWS SCORE=8
142. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=normal
and BS=low2 THEN EWS SCORE=7
143. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=normal
and BS=normal THEN EWS SCORE=5
144. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=normal
and BS=high2 THEN EWS SCORE=7
145. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=normal
and BS=high3 THEN EWS SCORE=8
146. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=high2
and BS=low3 THEN EWS SCORE=10
147. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=high2
and BS=low2 THEN EWS SCORE=9
148. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=high2
and BS=normal THEN EWS SCORE=7
149. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=high2
and BS=high2 THEN EWS SCORE=9
64
150. If SBP=low3 and HR=normal and SPO2=low2 and TEMP=high2
and BS=high3 THEN EWS SCORE=10
151. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=low2
and BS=low3 THEN EWS SCORE=9
152. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=low2
and BS=low2 THEN EWS SCORE=8
153. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=low2
and BS=normal THEN EWS SCORE=6
154. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=low2
and BS=high2 THEN EWS SCORE=8
155. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=low2
and BS=high3 THEN EWS SCORE=9
156. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=normal
and BS=low3 THEN EWS SCORE=7
157. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=normal
and BS=low2 THEN EWS SCORE=6
158. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=normal
and BS=normal THEN EWS SCORE=4
159. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=normal
and BS=high2 THEN EWS SCORE=6
160. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=normal
and BS=high3 THEN EWS SCORE=7
161. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=high2
and BS=low3 THEN EWS SCORE=9
162. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=high2
and BS=low2 THEN EWS SCORE=8
163. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=high2
and BS=normal THEN EWS SCORE=6
164. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=high2
and BS=high2 THEN EWS SCORE=8
165. If SBP=low3 and HR=normal and SPO2=low1 and TEMP=high2
and BS=high3 THEN EWS SCORE=9
166. If SBP=low3 and HR=normal and SPO2=normal and TEMP=low2
and BS=low3 THEN EWS SCORE=8
167. If SBP=low3 and HR=normal and SPO2=normal and TEMP=low2
and BS=low2 THEN EWS SCORE=7
168. If SBP=low3 and HR=normal and SPO2=normal and TEMP=low2
and BS=normal THEN EWS SCORE=5
169. If SBP=low3 and HR=normal and SPO2=normal and TEMP=low2
and BS=high2 THEN EWS SCORE=7
65
170. If SBP=low3 and HR=normal and SPO2=normal and TEMP=low2
and BS=high3 THEN EWS SCORE=8
171. If SBP=low3 and HR=normal and SPO2=normal and
TEMP=normal and BS=low3 THEN EWS SCORE=6
172. If SBP=low3 and HR=normal and SPO2=normal and
TEMP=normal and BS=low2 THEN EWS SCORE=5
173. If SBP=low3 and HR=normal and SPO2=normal and
TEMP=normal and BS=normal THEN EWS SCORE=3
174. If SBP=low3 and HR=normal and SPO2=normal and
TEMP=normal and BS=high2 THEN EWS SCORE=5
175. If SBP=low3 and HR=normal and SPO2=normal and
TEMP=normal and BS=high3 THEN EWS SCORE=6
176. If SBP=low3 and HR=normal and SPO2=normal and
TEMP=high2 and BS=low3 THEN EWS SCORE=8
177. If SBP=low3 and HR=normal and SPO2=normal and
TEMP=high2 and BS=low2 THEN EWS SCORE=7
178. If SBP=low3 and HR=normal and SPO2=normal and
TEMP=high2 and BS=normal THEN EWS SCORE=5
179. If SBP=low3 and HR=normal and SPO2=normal and
TEMP=high2 and BS=high2 THEN EWS SCORE=7
180. If SBP=low3 and HR=normal and SPO2=normal and
TEMP=high2 and BS=high3 THEN EWS SCORE=8
181. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=low2
and BS=low3 THEN EWS SCORE=12
182. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=low2
and BS=low2 THEN EWS SCORE=11
183. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=low2
and BS=normal THEN EWS SCORE=9
184. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=low2
and BS=high2 THEN EWS SCORE=11
185. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=low2
and BS=high3 THEN EWS SCORE=12
186. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=normal
and BS=low3 THEN EWS SCORE=10
187. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=normal
and BS=low2 THEN EWS SCORE=9
188. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=normal
and BS=normal THEN EWS SCORE=7
189. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=normal
and BS=high2 THEN EWS SCORE=9
66
190. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=normal
and BS=high3 THEN EWS SCORE=10
191. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=high2
and BS=low3 THEN EWS SCORE=12
192. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=high2
and BS=low2 THEN EWS SCORE=11
193. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=high2
and BS=normal THEN EWS SCORE=9
194. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=high2
and BS=high2 THEN EWS SCORE=11
195. If SBP=low3 and HR=high1 and SPO2=low3 and TEMP=high2
and BS=high3 THEN EWS SCORE=12
196. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=low2
and BS=low3 THEN EWS SCORE=11
197. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=low2
and BS=low2 THEN EWS SCORE=10
198. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=low2
and BS=normal THEN EWS SCORE=8
199. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=low2
and BS=high2 THEN EWS SCORE=10
200. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=low2
and BS=high3 THEN EWS SCORE=11
201. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=normal
and BS=low3 THEN EWS SCORE=9
202. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=normal
and BS=low2 THEN EWS SCORE=8
203. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=normal
and BS=normal THEN EWS SCORE=6
204. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=normal
and BS=high2 THEN EWS SCORE=8
205. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=normal
and BS=high3 THEN EWS SCORE=9
206. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=high2
and BS=low3 THEN EWS SCORE=11
207. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=high2
and BS=low2 THEN EWS SCORE=10
208. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=high2
and BS=normal THEN EWS SCORE=8
209. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=high2
and BS=high2 THEN EWS SCORE=10
67
210. If SBP=low3 and HR=high1 and SPO2=low2 and TEMP=high2
and BS=high3 THEN EWS SCORE=11
211. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=low2
and BS=low3 THEN EWS SCORE=10
212. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=low2
and BS=low2 THEN EWS SCORE=9
213. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=low2
and BS=normal THEN EWS SCORE=7
214. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=low2
and BS=high2 THEN EWS SCORE=9
215. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=low2
and BS=high3 THEN EWS SCORE=10
216. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=normal
and BS=low3 THEN EWS SCORE=8
217. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=normal
and BS=low2 THEN EWS SCORE=7
218. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=normal
and BS=normal THEN EWS SCORE=5
219. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=normal
and BS=high2 THEN EWS SCORE=7
220. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=normal
and BS=high3 THEN EWS SCORE=8
221. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=high2
and BS=low3 THEN EWS SCORE=10
222. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=high2
and BS=low2 THEN EWS SCORE=9
223. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=high2
and BS=normal THEN EWS SCORE=7
224. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=high2
and BS=high2 THEN EWS SCORE=9
225. If SBP=low3 and HR=high1 and SPO2=low1 and TEMP=high2
and BS=high3 THEN EWS SCORE=10
226. If SBP=low3 and HR=high1 and SPO2=normal and TEMP=low2
and BS=low3 THEN EWS SCORE=9
227. If SBP=low3 and HR=high1 and SPO2=normal and TEMP=low2
and BS=low2 THEN EWS SCORE=8
228. If SBP=low3 and HR=high1 and SPO2=normal and TEMP=low2
and BS=normal THEN EWS SCORE=6
229. If SBP=low3 and HR=high1 and SPO2=normal and TEMP=low2
and BS=high2 THEN EWS SCORE=8
68
230. If SBP=low3 and HR=high1 and SPO2=normal and TEMP=low2
and BS=high3 THEN EWS SCORE=9
231. If SBP=low3 and HR=high1 and SPO2=normal and
TEMP=normal and BS=low3 THEN EWS SCORE=7
232. If SBP=low3 and HR=high1 and SPO2=normal and
TEMP=normal and BS=low2 THEN EWS SCORE=6
233. If SBP=low3 and HR=high1 and SPO2=normal and
TEMP=normal and BS=normal THEN EWS SCORE=4
234. If SBP=low3 and HR=high1 and SPO2=normal and
TEMP=normal and BS=high2 THEN EWS SCORE=6
235. If SBP=low3 and HR=high1 and SPO2=normal and
TEMP=normal and BS=high3 THEN EWS SCORE=7
236. If SBP=low3 and HR=high1 and SPO2=normal and TEMP=high2
and BS=low3 THEN EWS SCORE=9
237. If SBP=low3 and HR=high1 and SPO2=normal and TEMP=high2
and BS=low2 THEN EWS SCORE=8
238. If SBP=low3 and HR=high1 and SPO2=normal and TEMP=high2
and BS=normal THEN EWS SCORE=6
239. If SBP=low3 and HR=high1 and SPO2=normal and TEMP=high2
and BS=high2 THEN EWS SCORE=8
240. If SBP=low3 and HR=high1 and SPO2=normal and TEMP=high2
and BS=high3 THEN EWS SCORE=9
241. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=low2
and BS=low3 THEN EWS SCORE=13
242. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=low2
and BS=low2 THEN EWS SCORE=12
243. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=low2
and BS=normal THEN EWS SCORE=10
244. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=low2
and BS=high2 THEN EWS SCORE=12
245. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=low2
and BS=high3 THEN EWS SCORE=13
246. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=normal
and BS=low3 THEN EWS SCORE=11
247. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=normal
and BS=low2 THEN EWS SCORE=10
248. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=normal
and BS=normal THEN EWS SCORE=8
249. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=normal
and BS=high2 THEN EWS SCORE=10
69
250. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=normal
and BS=high3 THEN EWS SCORE=11
251. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=high2
and BS=low3 THEN EWS SCORE=13
252. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=high2
and BS=low2 THEN EWS SCORE=12
253. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=high2
and BS=normal THEN EWS SCORE=10
254. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=high2
and BS=high2 THEN EWS SCORE=12
255. If SBP=low3 and HR=high2 and SPO2=low3 and TEMP=high2
and BS=high3 THEN EWS SCORE=13
256. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=low2
and BS=low3 THEN EWS SCORE=12
257. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=low2
and BS=low2 THEN EWS SCORE=11
258. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=low2
and BS=normal THEN EWS SCORE=9
259. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=low2
and BS=high2 THEN EWS SCORE=11
260. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=low2
and BS=high3 THEN EWS SCORE=12
261. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=normal
and BS=low3 THEN EWS SCORE=10
262. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=normal
and BS=low2 THEN EWS SCORE=9
263. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=normal
and BS=normal THEN EWS SCORE=7
264. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=normal
and BS=high2 THEN EWS SCORE=9
265. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=normal
and BS=high3 THEN EWS SCORE=10
266. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=high2
and BS=low3 THEN EWS SCORE=12
267. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=high2
and BS=low2 THEN EWS SCORE=11
268. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=high2
and BS=normal THEN EWS SCORE=9
269. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=high2
and BS=high2 THEN EWS SCORE=11
70
270. If SBP=low3 and HR=high2 and SPO2=low2 and TEMP=high2
and BS=high3 THEN EWS SCORE=12
271. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=low2
and BS=low3 THEN EWS SCORE=11
272. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=low2
and BS=low2 THEN EWS SCORE=10
273. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=low2
and BS=normal THEN EWS SCORE=8
274. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=low2
and BS=high2 THEN EWS SCORE=10
275. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=low2
and BS=high3 THEN EWS SCORE=11
276. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=normal
and BS=low3 THEN EWS SCORE=9
277. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=normal
and BS=low2 THEN EWS SCORE=8
278. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=normal
and BS=normal THEN EWS SCORE=6
279. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=normal
and BS=high2 THEN EWS SCORE=8
280. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=normal
and BS=high3 THEN EWS SCORE=9
281. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=high2
and BS=low3 THEN EWS SCORE=11
282. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=high2
and BS=low2 THEN EWS SCORE=10
283. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=high2
and BS=normal THEN EWS SCORE=8
284. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=high2
and BS=high2 THEN EWS SCORE=10
285. If SBP=low3 and HR=high2 and SPO2=low1 and TEMP=high2
and BS=high3 THEN EWS SCORE=11
286. If SBP=low3 and HR=high2 and SPO2=normal and TEMP=low2
and BS=low3 THEN EWS SCORE=10
287. If SBP=low3 and HR=high2 and SPO2=normal and TEMP=low2
and BS=low2 THEN EWS SCORE=9
288. If SBP=low3 and HR=high2 and SPO2=normal and TEMP=low2
and BS=normal THEN EWS SCORE=7
289. If SBP=low3 and HR=high2 and SPO2=normal and TEMP=low2
and BS=high2 THEN EWS SCORE=9
71
290. If SBP=low3 and HR=high2 and SPO2=normal and TEMP=low2
and BS=high3 THEN EWS SCORE=10
291. If SBP=low3 and HR=high2 and SPO2=normal and
TEMP=normal and BS=low3 THEN EWS SCORE=8
292. If SBP=low3 and HR=high2 and SPO2=normal and
TEMP=normal and BS=low2 THEN EWS SCORE=7
293. If SBP=low3 and HR=high2 and SPO2=normal and
TEMP=normal and BS=normal THEN EWS SCORE=5
294. If SBP=low3 and HR=high2 and SPO2=normal and
TEMP=normal and BS=high2 THEN EWS SCORE=7
295. If SBP=low3 and HR=high2 and SPO2=normal and
TEMP=normal and BS=high3 THEN EWS SCORE=8
296. If SBP=low3 and HR=high2 and SPO2=normal and TEMP=high2
and BS=low3 THEN EWS SCORE=10
297. If SBP=low3 and HR=high2 and SPO2=normal and TEMP=high2
and BS=low2 THEN EWS SCORE=9
298. If SBP=low3 and HR=high2 and SPO2=normal and TEMP=high2
and BS=normal THEN EWS SCORE=7
299. If SBP=low3 and HR=high2 and SPO2=normal and TEMP=high2
and BS=high2 THEN EWS SCORE=9
300. If SBP=low3 and HR=high2 and SPO2=normal and TEMP=high2
and BS=high3 THEN EWS SCORE=10
301. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=low2
and BS=low3 THEN EWS SCORE=14
302. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=low2
and BS=low2 THEN EWS SCORE=13
303. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=low2
and BS=normal THEN EWS SCORE=11
304. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=low2
and BS=high2 THEN EWS SCORE=13
305. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=low2
and BS=high3 THEN EWS SCORE=14
306. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=normal
and BS=low3 THEN EWS SCORE=12
307. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=normal
and BS=low2 THEN EWS SCORE=11
308. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=normal
and BS=normal THEN EWS SCORE=9
309. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=normal
and BS=high2 THEN EWS SCORE=11
72
310. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=normal
and BS=high3 THEN EWS SCORE=12
311. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=high2
and BS=low3 THEN EWS SCORE=14
312. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=high2
and BS=low2 THEN EWS SCORE=13
313. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=high2
and BS=normal THEN EWS SCORE=11
314. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=high2
and BS=high2 THEN EWS SCORE=13
315. If SBP=low3 and HR=high3 and SPO2=low3 and TEMP=high2
and BS=high3 THEN EWS SCORE=14
316. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=low2
and BS=low3 THEN EWS SCORE=13
317. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=low2
and BS=low2 THEN EWS SCORE=12
318. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=low2
and BS=normal THEN EWS SCORE=10
319. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=low2
and BS=high2 THEN EWS SCORE=12
320. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=low2
and BS=high3 THEN EWS SCORE=13
321. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=normal
and BS=low3 THEN EWS SCORE=11
322. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=normal
and BS=low2 THEN EWS SCORE=10
323. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=normal
and BS=normal THEN EWS SCORE=8
324. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=normal
and BS=high2 THEN EWS SCORE=10
325. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=normal
and BS=high3 THEN EWS SCORE=11
326. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=high2
and BS=low3 THEN EWS SCORE=13
327. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=high2
and BS=low2 THEN EWS SCORE=12
328. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=high2
and BS=normal THEN EWS SCORE=10
329. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=high2
and BS=high2 THEN EWS SCORE=12
73
330. If SBP=low3 and HR=high3 and SPO2=low2 and TEMP=high2
and BS=high3 THEN EWS SCORE=13
331. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=low2
and BS=low3 THEN EWS SCORE=12
332. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=low2
and BS=low2 THEN EWS SCORE=11
333. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=low2
and BS=normal THEN EWS SCORE=9
334. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=low2
and BS=high2 THEN EWS SCORE=11
335. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=low2
and BS=high3 THEN EWS SCORE=12
336. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=normal
and BS=low3 THEN EWS SCORE=10
337. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=normal
and BS=low2 THEN EWS SCORE=9
338. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=normal
and BS=normal THEN EWS SCORE=7
339. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=normal
and BS=high2 THEN EWS SCORE=9
340. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=normal
and BS=high3 THEN EWS SCORE=10
341. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=high2
and BS=low3 THEN EWS SCORE=12
342. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=high2
and BS=low2 THEN EWS SCORE=11
343. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=high2
and BS=normal THEN EWS SCORE=9
344. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=high2
and BS=high2 THEN EWS SCORE=11
345. If SBP=low3 and HR=high3 and SPO2=low1 and TEMP=high2
and BS=high3 THEN EWS SCORE=12
346. If SBP=low3 and HR=high3 and SPO2=normal and TEMP=low2
and BS=low3 THEN EWS SCORE=11
347. If SBP=low3 and HR=high3 and SPO2=normal and TEMP=low2
and BS=low2 THEN EWS SCORE=10
348. If SBP=low3 and HR=high3 and SPO2=normal and TEMP=low2
and BS=normal THEN EWS SCORE=8
349. If SBP=low3 and HR=high3 and SPO2=normal and TEMP=low2
and BS=high2 THEN EWS SCORE=10
74
350. If SBP=low3 and HR=high3 and SPO2=normal and TEMP=low2
and BS=high3 THEN EWS SCORE=11
351. If SBP=low3 and HR=high3 and SPO2=normal and
TEMP=normal and BS=low3 THEN EWS SCORE=9
352. If SBP=low3 and HR=high3 and SPO2=normal and
TEMP=normal and BS=low2 THEN EWS SCORE=8
353. If SBP=low3 and HR=high3 and SPO2=normal and
TEMP=normal and BS=normal THEN EWS SCORE=6
354. If SBP=low3 and HR=high3 and SPO2=normal and
TEMP=normal and BS=high2 THEN EWS SCORE=8
355. If SBP=low3 and HR=high3 and SPO2=normal and
TEMP=normal and BS=high3 THEN EWS SCORE=9
356. If SBP=low3 and HR=high3 and SPO2=normal and TEMP=high2
and BS=low3 THEN EWS SCORE=11
357. If SBP=low3 and HR=high3 and SPO2=normal and TEMP=high2
and BS=low2 THEN EWS SCORE=10
358. If SBP=low3 and HR=high3 and SPO2=normal and TEMP=high2
and BS=normal THEN EWS SCORE=8
359. If SBP=low3 and HR=high3 and SPO2=normal and TEMP=high2
and BS=high2 THEN EWS SCORE=10
360. If SBP=low3 and HR=high3 and SPO2=normal and TEMP=high2
and BS=high3 THEN EWS SCORE=11
361. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=low2 and
BS=low3 THEN EWS SCORE=12
362. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=low2 and
BS=low2 THEN EWS SCORE=11
363. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=low2 and
BS=normal THEN EWS SCORE=9
364. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=low2 and
BS=high2 THEN EWS SCORE=11
365. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=low2 and
BS=high3 THEN EWS SCORE=12
366. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=normal
and BS=low3 THEN EWS SCORE=10
367. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=normal
and BS=low2 THEN EWS SCORE=9
368. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=normal
and BS=normal THEN EWS SCORE=7
369. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=normal
and BS=high2 THEN EWS SCORE=9
75
370. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=normal
and BS=high3 THEN EWS SCORE=10
371. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=high2
and BS=low3 THEN EWS SCORE=12
372. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=high2
and BS=low2 THEN EWS SCORE=11
373. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=high2
and BS=normal THEN EWS SCORE=9
374. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=high2
and BS=high2 THEN EWS SCORE=11
375. If SBP=low2 and HR=low2 and SPO2=low3 and TEMP=high2
and BS=high3 THEN EWS SCORE=12
376. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=low2 and
BS=low3 THEN EWS SCORE=11
377. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=low2 and
BS=low2 THEN EWS SCORE=10
378. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=low2 and
BS=normal THEN EWS SCORE=8
379. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=low2 and
BS=high2 THEN EWS SCORE=10
380. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=low2 and
BS=high3 THEN EWS SCORE=11
381. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=normal
and BS=low3 THEN EWS SCORE=9
382. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=normal
and BS=low2 THEN EWS SCORE=8
383. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=normal
and BS=normal THEN EWS SCORE=6
384. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=normal
and BS=high2 THEN EWS SCORE=8
385. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=normal
and BS=high3 THEN EWS SCORE=9
386. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=high2
and BS=low3 THEN EWS SCORE=11
387. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=high2
and BS=low2 THEN EWS SCORE=10
388. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=high2
and BS=normal THEN EWS SCORE=8
389. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=high2
and BS=high2 THEN EWS SCORE=10
76
390. If SBP=low2 and HR=low2 and SPO2=low2 and TEMP=high2
and BS=high3 THEN EWS SCORE=11
391. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=low2 and
BS=low3 THEN EWS SCORE=10
392. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=low2 and
BS=low2 THEN EWS SCORE=9
393. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=low2 and
BS=normal THEN EWS SCORE=7
394. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=low2 and
BS=high2 THEN EWS SCORE=9
395. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=low2 and
BS=high3 THEN EWS SCORE=10
396. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=normal
and BS=low3 THEN EWS SCORE=8
397. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=normal
and BS=low2 THEN EWS SCORE=7
398. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=normal
and BS=normal THEN EWS SCORE=5
399. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=normal
and BS=high2 THEN EWS SCORE=7
400. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=normal
and BS=high3 THEN EWS SCORE=8
401. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=high2
and BS=low3 THEN EWS SCORE=10
402. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=high2
and BS=low2 THEN EWS SCORE=9
403. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=high2
and BS=normal THEN EWS SCORE=7
404. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=high2
and BS=high2 THEN EWS SCORE=9
405. If SBP=low2 and HR=low2 and SPO2=low1 and TEMP=high2
and BS=high3 THEN EWS SCORE=10
406. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=low2
and BS=low3 THEN EWS SCORE=9
407. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=low2
and BS=low2 THEN EWS SCORE=8
408. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=low2
and BS=normal THEN EWS SCORE=6
409. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=low2
and BS=high2 THEN EWS SCORE=8
77
410. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=low2
and BS=high3 THEN EWS SCORE=9
411. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=normal
and BS=low3 THEN EWS SCORE=7
412. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=normal
and BS=low2 THEN EWS SCORE=6
413. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=normal
and BS=normal THEN EWS SCORE=4
414. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=normal
and BS=high2 THEN EWS SCORE=6
415. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=normal
and BS=high3 THEN EWS SCORE=7
416. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=high2
and BS=low3 THEN EWS SCORE=9
417. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=high2
and BS=low2 THEN EWS SCORE=8
418. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=high2
and BS=normal THEN EWS SCORE=6
419. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=high2
and BS=high2 THEN EWS SCORE=8
420. If SBP=low2 and HR=low2 and SPO2=normal and TEMP=high2
and BS=high3 THEN EWS SCORE=9
421. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=low2 and
BS=low3 THEN EWS SCORE=11
422. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=low2 and
BS=low2 THEN EWS SCORE=10
423. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=low2 and
BS=normal THEN EWS SCORE=8
424. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=low2 and
BS=high2 THEN EWS SCORE=10
425. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=low2 and
BS=high3 THEN EWS SCORE=11
426. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=normal
and BS=low3 THEN EWS SCORE=9
427. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=normal
and BS=low2 THEN EWS SCORE=8
428. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=normal
and BS=normal THEN EWS SCORE=6
429. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=normal
and BS=high2 THEN EWS SCORE=8
78
430. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=normal
and BS=high3 THEN EWS SCORE=9
431. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=high2
and BS=low3 THEN EWS SCORE=11
432. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=high2
and BS=low2 THEN EWS SCORE=10
433. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=high2
and BS=normal THEN EWS SCORE=8
434. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=high2
and BS=high2 THEN EWS SCORE=10
435. If SBP=low2 and HR=low1 and SPO2=low3 and TEMP=high2
and BS=high3 THEN EWS SCORE=11
436. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=low2 and
BS=low3 THEN EWS SCORE=10
437. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=low2 and
BS=low2 THEN EWS SCORE=9
438. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=low2 and
BS=normal THEN EWS SCORE=7
439. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=low2 and
BS=high2 THEN EWS SCORE=9
440. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=low2 and
BS=high3 THEN EWS SCORE=10
441. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=normal
and BS=low3 THEN EWS SCORE=8
442. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=normal
and BS=low2 THEN EWS SCORE=7
443. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=normal
and BS=normal THEN EWS SCORE=5
444. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=normal
and BS=high2 THEN EWS SCORE=7
445. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=normal
and BS=high3 THEN EWS SCORE=8
446. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=high2
and BS=low3 THEN EWS SCORE=10
447. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=high2
and BS=low2 THEN EWS SCORE=9
448. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=high2
and BS=normal THEN EWS SCORE=7
449. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=high2
and BS=high2 THEN EWS SCORE=9
79
450. If SBP=low2 and HR=low1 and SPO2=low2 and TEMP=high2
and BS=high3 THEN EWS SCORE=10
451. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=low2 and
BS=low3 THEN EWS SCORE=9
452. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=low2 and
BS=low2 THEN EWS SCORE=8
453. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=low2 and
BS=normal THEN EWS SCORE=6
454. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=low2 and
BS=high2 THEN EWS SCORE=8
455. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=low2 and
BS=high3 THEN EWS SCORE=9
456. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=normal
and BS=low3 THEN EWS SCORE=7
457. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=normal
and BS=low2 THEN EWS SCORE=6
458. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=normal
and BS=normal THEN EWS SCORE=4
459. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=normal
and BS=high2 THEN EWS SCORE=6
460. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=normal
and BS=high3 THEN EWS SCORE=7
461. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=high2
and BS=low3 THEN EWS SCORE=9
462. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=high2
and BS=low2 THEN EWS SCORE=8
463. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=high2
and BS=normal THEN EWS SCORE=6
464. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=high2
and BS=high2 THEN EWS SCORE=8
465. If SBP=low2 and HR=low1 and SPO2=low1 and TEMP=high2
and BS=high3 THEN EWS SCORE=9
466. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=low2
and BS=low3 THEN EWS SCORE=8
467. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=low2
and BS=low2 THEN EWS SCORE=7
468. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=low2
and BS=normal THEN EWS SCORE=5
469. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=low2
and BS=high2 THEN EWS SCORE=7
80
470. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=low2
and BS=high3 THEN EWS SCORE=8
471. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=normal
and BS=low3 THEN EWS SCORE=6
472. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=normal
and BS=low2 THEN EWS SCORE=5
473. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=normal
and BS=normal THEN EWS SCORE=3
474. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=normal
and BS=high2 THEN EWS SCORE=5
475. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=normal
and BS=high3 THEN EWS SCORE=6
476. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=high2
and BS=low3 THEN EWS SCORE=8
477. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=high2
and BS=low2 THEN EWS SCORE=7
478. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=high2
and BS=normal THEN EWS SCORE=5
479. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=high2
and BS=high2 THEN EWS SCORE=7
480. If SBP=low2 and HR=low1 and SPO2=normal and TEMP=high2
and BS=high3 THEN EWS SCORE=8
481. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=low2
and BS=low3 THEN EWS SCORE=10
482. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=low2
and BS=low2 THEN EWS SCORE=9
483. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=low2
and BS=normal THEN EWS SCORE=7
484. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=low2
and BS=high2 THEN EWS SCORE=9
485. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=low2
and BS=high3 THEN EWS SCORE=10
486. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=normal
and BS=low3 THEN EWS SCORE=8
487. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=normal
and BS=low2 THEN EWS SCORE=7
488. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=normal
and BS=normal THEN EWS SCORE=5
489. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=normal
and BS=high2 THEN EWS SCORE=7
81
490. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=normal
and BS=high3 THEN EWS SCORE=8
491. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=high2
and BS=low3 THEN EWS SCORE=10
492. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=high2
and BS=low2 THEN EWS SCORE=9
493. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=high2
and BS=normal THEN EWS SCORE=7
494. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=high2
and BS=high2 THEN EWS SCORE=9
495. If SBP=low2 and HR=normal and SPO2=low3 and TEMP=high2
and BS=high3 THEN EWS SCORE=10
496. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=low2
and BS=low3 THEN EWS SCORE=9
497. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=low2
and BS=low2 THEN EWS SCORE=8
498. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=low2
and BS=normal THEN EWS SCORE=6
499. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=low2
and BS=high2 THEN EWS SCORE=8
500. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=low2
and BS=high3 THEN EWS SCORE=9
501. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=normal
and BS=low3 THEN EWS SCORE=7
502. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=normal
and BS=low2 THEN EWS SCORE=6
503. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=normal
and BS=normal THEN EWS SCORE=4
504. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=normal
and BS=high2 THEN EWS SCORE=6
505. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=normal
and BS=high3 THEN EWS SCORE=7
506. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=high2
and BS=low3 THEN EWS SCORE=9
507. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=high2
and BS=low2 THEN EWS SCORE=8
508. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=high2
and BS=normal THEN EWS SCORE=6
509. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=high2
and BS=high2 THEN EWS SCORE=8
82
510. If SBP=low2 and HR=normal and SPO2=low2 and TEMP=high2
and BS=high3 THEN EWS SCORE=9
511. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=low2
and BS=low3 THEN EWS SCORE=8
512. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=low2
and BS=low2 THEN EWS SCORE=7
513. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=low2
and BS=normal THEN EWS SCORE=5
514. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=low2
and BS=high2 THEN EWS SCORE=7
515. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=low2
and BS=high3 THEN EWS SCORE=8
516. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=normal
and BS=low3 THEN EWS SCORE=6
517. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=normal
and BS=low2 THEN EWS SCORE=5
518. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=normal
and BS=normal THEN EWS SCORE=3
519. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=normal
and BS=high2 THEN EWS SCORE=5
520. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=normal
and BS=high3 THEN EWS SCORE=6
521. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=high2
and BS=low3 THEN EWS SCORE=8
522. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=high2
and BS=low2 THEN EWS SCORE=7
523. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=high2
and BS=normal THEN EWS SCORE=5
524. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=high2
and BS=high2 THEN EWS SCORE=7
525. If SBP=low2 and HR=normal and SPO2=low1 and TEMP=high2
and BS=high3 THEN EWS SCORE=8
526. If SBP=low2 and HR=normal and SPO2=normal and TEMP=low2
and BS=low3 THEN EWS SCORE=7
527. If SBP=low2 and HR=normal and SPO2=normal and TEMP=low2
and BS=low2 THEN EWS SCORE=6
528. If SBP=low2 and HR=normal and SPO2=normal and TEMP=low2
and BS=normal THEN EWS SCORE=4
529. If SBP=low2 and HR=normal and SPO2=normal and TEMP=low2
and BS=high2 THEN EWS SCORE=6
83
530. If SBP=low2 and HR=normal and SPO2=normal and TEMP=low2
and BS=high3 THEN EWS SCORE=7
531. If SBP=low2 and HR=normal and SPO2=normal and
TEMP=normal and BS=low3 THEN EWS SCORE=5
532. If SBP=low2 and HR=normal and SPO2=normal and
TEMP=normal and BS=low2 THEN EWS SCORE=4
533. If SBP=low2 and HR=normal and SPO2=normal and
TEMP=normal and BS=normal THEN EWS SCORE=2
534. If SBP=low2 and HR=normal and SPO2=normal and
TEMP=normal and BS=high2 THEN EWS SCORE=4
535. If SBP=low2 and HR=normal and SPO2=normal and
TEMP=normal and BS=high3 THEN EWS SCORE=5
536. If SBP=low2 and HR=normal and SPO2=normal and
TEMP=high2 and BS=low3 THEN EWS SCORE=7
537. If SBP=low2 and HR=normal and SPO2=normal and
TEMP=high2 and BS=low2 THEN EWS SCORE=6
538. If SBP=low2 and HR=normal and SPO2=normal and
TEMP=high2 and BS=normal THEN EWS SCORE=4
539. If SBP=low2 and HR=normal and SPO2=normal and
TEMP=high2 and BS=high2 THEN EWS SCORE=6
540. If SBP=low2 and HR=normal and SPO2=normal and
TEMP=high2 and BS=high3 THEN EWS SCORE=7
541. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=low2
and BS=low3 THEN EWS SCORE=11
542. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=low2
and BS=low2 THEN EWS SCORE=10
543. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=low2
and BS=normal THEN EWS SCORE=8
544. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=low2
and BS=high2 THEN EWS SCORE=10
545. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=low2
and BS=high3 THEN EWS SCORE=11
546. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=normal
and BS=low3 THEN EWS SCORE=9
547. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=normal
and BS=low2 THEN EWS SCORE=8
548. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=normal
and BS=normal THEN EWS SCORE=6
549. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=normal
and BS=high2 THEN EWS SCORE=8
84
550. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=normal
and BS=high3 THEN EWS SCORE=9
551. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=high2
and BS=low3 THEN EWS SCORE=11
552. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=high2
and BS=low2 THEN EWS SCORE=10
553. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=high2
and BS=normal THEN EWS SCORE=8
554. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=high2
and BS=high2 THEN EWS SCORE=10
555. If SBP=low2 and HR=high1 and SPO2=low3 and TEMP=high2
and BS=high3 THEN EWS SCORE=11
556. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=low2
and BS=low3 THEN EWS SCORE=10
557. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=low2
and BS=low2 THEN EWS SCORE=9
558. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=low2
and BS=normal THEN EWS SCORE=7
559. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=low2
and BS=high2 THEN EWS SCORE=9
560. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=low2
and BS=high3 THEN EWS SCORE=10
561. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=normal
and BS=low3 THEN EWS SCORE=8
562. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=normal
and BS=low2 THEN EWS SCORE=7
563. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=normal
and BS=normal THEN EWS SCORE=5
564. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=normal
and BS=high2 THEN EWS SCORE=7
565. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=normal
and BS=high3 THEN EWS SCORE=8
566. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=high2
and BS=low3 THEN EWS SCORE=10
567. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=high2
and BS=low2 THEN EWS SCORE=9
568. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=high2
and BS=normal THEN EWS SCORE=7
569. If SBP=low2 and HR=high1 and SPO2=low2 and TEMP=high2
and BS=high2 THEN EWS SCORE=9
85
4.2.3 Mesin Inferensi
Dalam mesin inferensi ini akan dimodelkan cara sistem memproses data
dengan menggunakan metode ini. Proses tersebut dimulai dengan memasukkan
data dari user, kemudian data masuan user dihitung sesuai dengan perumusan
Tsukamoto.
86
4.2.4 Subsistem Antarmuka Pengguna
87
BAB V
IMPLEMENTASI
Pada bab ini akan dijelaskan tentang implementasi rancangan Sistem Pakar
Pemantau Kondisi Pasien Rawat Inap Menggunakan Fuzzy Inferensi Tsukamoto.
Ruang lingkup implementasi dalam sistem pakar ini meliputi Lingkungan
Implementasi, dan Implementasi Aplikasi (Kode Sumber Aplikasi).
88
5.2 Implementasi Aplikasi
5.2.1.1 BloodSugar.java
package engine;
import ui.MainWindow;
import java.util.ArrayList;
public BloodSugar() {
}
89
public double GetBS (){
return bloodSugar;
}
90
mainWindow.setHasilText("BS :
"+this.convertToString(2)+"\n");
}
if(BS > 140){
this.linguistic.add(3);
mainWindow.setHasilText("BS :
"+this.convertToString(3)+"\n");
}
}
91
}
92
}else if(value==1){
return "high1";
}else if(value==2){
return "high2";
}else if(value==3){
return "high3";
}else return "";
}
5.2.1.2 HeartRate.java
package engine;
import ui.MainWindow;
import java.util.ArrayList;
public HeartRate() {
}
93
}
94
mainWindow.setHasilText("HR :
"+this.convertToString(3)+"\n");
}
}
95
if (heartRate >= 53 && heartRate <60){
return (heartRate-53)/7;
}else if(heartRate >= 60 && heartRate < 95){
return 1;
}else if (heartRate >=95 && heartRate <= 100){
return (100-heartRate)/5;
}else {
return 0;
}
}
96
private String convertToString(int value){
if(value==-3){
return "low3";
}else if(value==-2){
return "low2";
}else if(value==-1){
return "low1";
}else if(value==0){
return "normal";
}else if(value==1){
return "high1";
}else if(value==2){
return "high2";
}else if(value==3){
return "high3";
}else return "";
}
}
5.2.1.3 SystolicBloodPressure.java
package engine;
import ui.MainWindow;
import java.util.ArrayList;
public SystolicBloodPressure() {
}
97
public int[] getSbpLinguistic() {
return sbpLinguistic;
}
98
if(SBP > 185){
this.linguistic.add(2);
mainWindow.setHasilText("SBP :
"+this.convertToString(2)+"\n");
}
}
99
}
}
100
if(value==-3){
return "low3";
}else if(value==-2){
return "low2";
}else if(value==-1){
return "low1";
}else if(value==0){
return "normal";
}else if(value==1){
return "high1";
}else if(value==2){
return "high2";
}else if(value==3){
return "high3";
}else return "";
}
}
5.2.1.4 OxygenSaturation.java
package engine;
import ui.MainWindow;
import java.util.ArrayList;
public OxygenSaturation() {
}
101
public int[] getOxygenSaturationLinguistic() {
return oxygenSaturationLinguistic;
}
102
}
103
return 1;
}else if (oxygenSaturation >= 93 && oxygenSaturation
<= 95){
return (95-oxygenSaturation)/2;
}else {
return 0;
}
}
5.2.1.5 Temperature.java
package engine;
import ui.MainWindow;
104
import java.util.ArrayList;
public Temperature() {
}
105
"+this.temperature+"\n");
if(TEMP < 36.5){
this.linguistic.add(-2);
mainWindow.setHasilText("TEMP :
"+this.convertToString(-2)+"\n");
}
if(TEMP >= 36 && TEMP <= 38.5){
this.linguistic.add(0);
mainWindow.setHasilText("TEMP :
"+this.convertToString(0)+"\n");
}
if(TEMP > 38){
this.linguistic.add(2);
mainWindow.setHasilText("TEMP :
"+this.convertToString(2)+"\n");
}
}
106
){
return (38.5-temperature)/0.5;
}else{
return 0;
}
}
5.2.1.6 Risk.java
package engine;
107
}
public Risk() {
}
5.2.1.7 RiskPrediction.java
package engine;
import ui.MainWindow;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.text.DecimalFormat;
import java.util.logging.Level;
import java.util.logging.Logger;
108
this.bloodSugarValue = bloodSugar;
this.strconn = startConn;
this.pcm = mainWindow;
}
int count=0;
pcm.ClearHasilText();
pcm.setHasilText("***** Proses *****\n\n\n");
pcm.setHasilText("=== Fuzzifikasi ===\n");
SBP.setLinguistik(this.sbpValue);
Lsbp=SBP.convertLinguistik();
109
SBP.clearLinguistik();
pcm.setHasilText("\n");
HR.setLinguistik(this.heartRateValue);
Lhr=HR.convertLinguistik();
HR.clearLinguistik();
pcm.setHasilText("\n");
SPO2.setLinguistik(this.spo2Value);
Lspo2=SPO2.convertLinguistik();
SPO2.clearLinguistik();
pcm.setHasilText("\n");
TEMP.setLinguistik(this.tempValue);
Ltemp=TEMP.convertLinguistik();
TEMP.clearLinguistik();
pcm.setHasilText("\n");
BS.setLinguistik(this.bloodSugarValue);
Lbs=BS.convertLinguistik();
BS.clearLinguistik();
pcm.setHasilText("\n\n");
110
str[6]=rs.getInt(7);
}
} catch (SQLException ex) {
Logger.getLogger(RiskPrediction.class.getName()).log(Level.S
EVERE, null, ex);
}
pcm.setProsessText("Rule
No."+str[0]+" => If SBP="+this.convertToString(str[1])+" and
HR="+this.convertToString(str[2])+" and
SPO2="+this.convertToString(str[3])+" and
TEMP="+this.convertToString(str[4])+" and
BS="+this.convertToString(str[5])+" THEN EWS
SCORE="+str[6]+"\n");
pcm.setHasilText("Rule
No."+str[0]+" => If SBP="+this.convertToString(str[1])+" and
HR="+this.convertToString(str[2])+" and
SPO2="+this.convertToString(str[3])+" and
TEMP="+this.convertToString(str[4])+" and
BS="+this.convertToString(str[5])+" THEN EWS
SCORE="+str[6]+"\n");
pcm.setHasilText("miu SBP
"+this.convertToString(str[1])+" =
"+SBP.selectionRule(str[1])+"\n");
pcm.setHasilText("miu HR
"+this.convertToString(str[2])+" =
"+HR.selectionRule(str[2])+"\n");
pcm.setHasilText("miu SPO2
"+this.convertToString(str[3])+" =
"+SPO2.selectionRule(str[3])+"\n");
pcm.setHasilText("miu TEMP
"+this.convertToString(str[4])+" =
"+TEMP.selectionRule(str[4])+"\n");
pcm.setHasilText("miu BS
"+this.convertToString(str[5])+" =
"+BS.selectionRule(str[5])+"\n\n");
alpha[count]=findMin(SBP.selectionRule(str[1]),
HR.selectionRule(str[2]), SPO2.selectionRule(str[3]),
TEMP.selectionRule(str[4]), BS.selectionRule(str[5]));
Z[count]=str[6];
count++;
}
}
111
}
}
}
return count;
}
112
pcm.setHasilText("("+alpha[i]+"*"+Z[i]+")");
}
pcm.setHasilText(")/(");
for (int i = 0; i < count; i++) {
if(i != count-1)pcm.setHasilText(alpha[i]+"+");
else pcm.setHasilText(""+alpha[i]);
}
pcm.setHasilText("))\n");
hasil1 = temp1 / temp2;
hasil2 = Double.valueOf(bulat.format(hasil1));
pcm.setHasilText("EWS Score = "+hasil1);
return hasil1;
}
}
5.2.1.8 PCMFuzzy.java
package engine;
import ui.MainWindow;
113
}
5.2.1.9 DBConnection.java
package engine;
import com.mysql.jdbc.Connection;
import com.mysql.jdbc.Statement;
import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.SQLException;
114
public DBConnection(String host, String username, String
password){
try {
this.conn = (Connection)
DriverManager.getConnection(host,username,password);
System.out.println("Connected");
}
catch (SQLException ex) {
System.out.println("Not Connected");
}
}
5.2.1.10 LoginWindow.java
package ui;
import engine.DBConnection;
import java.awt.Dimension;
import java.awt.Toolkit;
import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
115
import javax.swing.JOptionPane;
public LoginWindow() {
initComponents();
initDB();
}
try {
Class.forName("com.mysql.jdbc.Driver");
} catch (Exception ex) {
System.err.println("Error (1): " + ex);
System.exit(1);
}
startConn = new
DBConnection("jdbc:mysql://"+hosttext+":3306/"+databasetext,
usernametext,passwordtext);
@SuppressWarnings("unchecked")
private void initComponents() {
116
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON
_CLOSE);
usernameLabel.setText("Username");
passwordLabel.setText("Password");
loginButton.setText("Log In");
loginButton.addActionListener(new
java.awt.event.ActionListener() {
public void
actionPerformed(java.awt.event.ActionEvent evt) {
loginButtonActionPerformed(evt);
}
});
layout.createParallelGroup(javax.swing.GroupLayout.Alignment
.LEADING)
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING,
layout.createSequentialGroup()
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout
.Alignment.TRAILING)
.addGroup(layout.createSequentialGroup()
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE,
Short.MAX_VALUE)
.addComponent(loginButton))
.addGroup(javax.swing.GroupLayout.Alignment.LEADING,
layout.createSequentialGroup()
.addGap(60, 60, 60)
117
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout
.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addComponent(usernameLabel)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.
RELATED, javax.swing.GroupLayout.DEFAULT_SIZE,
Short.MAX_VALUE)
.addComponent(usernameField,
javax.swing.GroupLayout.PREFERRED_SIZE, 130,
javax.swing.GroupLayout.PREFERRED_SIZE))
.addGroup(layout.createSequentialGroup()
.addComponent(passwordLabel)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.
RELATED, javax.swing.GroupLayout.DEFAULT_SIZE,
Short.MAX_VALUE)
.addComponent(passwordField,
javax.swing.GroupLayout.PREFERRED_SIZE, 130,
javax.swing.GroupLayout.PREFERRED_SIZE))
.addGroup(layout.createSequentialGroup()
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout
.Alignment.LEADING)
.addComponent(jLabel1)
.addGroup(layout.createSequentialGroup()
.addGap(25, 25, 25)
.addComponent(jLabel2)))
.addGap(0, 0,
Short.MAX_VALUE)))))
.addGap(69, 69, 69))
.addGroup(layout.createSequentialGroup()
.addGap(28, 28, 28)
.addComponent(jSeparator1,
javax.swing.GroupLayout.PREFERRED_SIZE, 372,
javax.swing.GroupLayout.PREFERRED_SIZE)
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE,
Short.MAX_VALUE))
);
118
layout.setVerticalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment
.LEADING)
.addGroup(layout.createSequentialGroup()
.addGap(24, 24, 24)
.addComponent(jLabel1)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.
RELATED)
.addComponent(jLabel2)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.
UNRELATED)
.addComponent(jSeparator1,
javax.swing.GroupLayout.PREFERRED_SIZE, 10,
javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.
RELATED, 31, Short.MAX_VALUE)
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout
.Alignment.LEADING)
.addComponent(usernameLabel,
javax.swing.GroupLayout.Alignment.TRAILING)
.addComponent(usernameField,
javax.swing.GroupLayout.Alignment.TRAILING,
javax.swing.GroupLayout.PREFERRED_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.PREFERRED_SIZE))
.addGap(18, 18, 18)
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout
.Alignment.BASELINE)
.addComponent(passwordField,
javax.swing.GroupLayout.PREFERRED_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(passwordLabel))
.addGap(33, 33, 33)
.addComponent(loginButton)
.addGap(44, 44, 44))
);
pack();
119
}
private void
loginButtonActionPerformed(java.awt.event.ActionEvent evt) {
String password = null;
String username = null;
password = new String(passwordField.getPassword());
username = usernameField.getText();
int countRow = 0;
try {
while (resultSet.next()){
countRow = resultSet.getInt(1);
}
} catch (SQLException e) {
JOptionPane.showMessageDialog(null, e);
}
if (countRow == 1) {
MainWindow mainWindow = new MainWindow();
mainWindow.setVisible(true);
Dimension dimension =
Toolkit.getDefaultToolkit().getScreenSize();
int x = (int) ((dimension.getWidth() -
mainWindow.getWidth()) / 2);
int y = (int) ((dimension.getHeight() -
mainWindow.getHeight()) / 2);
mainWindow.setLocation(x, y);
} else {
JOptionPane.showMessageDialog(null, "username
dan password tidak cocok");
}
120
private javax.swing.JPasswordField passwordField;
private javax.swing.JLabel passwordLabel;
private javax.swing.JTextField usernameField;
private javax.swing.JLabel usernameLabel;
}
5.2.1.11 MainWindow.java
package ui;
import engine.DBConnection;
import engine.BloodSugar;
import engine.HeartRate;
import engine.PCMFuzzy;
import engine.OxygenSaturation;
import engine.SystolicBloodPressure;
import engine.Temperature;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.swing.JOptionPane;
try {
Class.forName("com.mysql.jdbc.Driver");
} catch (Exception ex) {
System.err.println("Error (1): " + ex);
System.exit(1);
}
startConn = new
DBConnection("jdbc:mysql://"+hosttext+":3306/"+databasetext,
usernametext,passwordtext);
121
}
Logger.getLogger(MainWindow.class.getName()).log(Level.SEVER
E, null, ex);
}
if (countRow>0){
resultSet=startConn.query("select * from rule");
this.ProsessText.setText("");
try {
while (resultSet.next()){
countRow=resultSet.getInt(1);
str[0]=resultSet.getInt(1);
str[1]=resultSet.getInt(2);
str[2]=resultSet.getInt(3);
str[3]=resultSet.getInt(4);
str[4]=resultSet.getInt(5);
str[5]=resultSet.getInt(6);
str[6]=resultSet.getInt(7);
this.ProsessText.append(str[0]+". If
SBP="+this.convertToString(str[1])+" and
HR="+this.convertToString(str[2])+" and
SPO2="+this.convertToString(str[3])+" and
TEMP="+this.convertToString(str[4])+" and
BS="+this.convertToString(str[5])+" THEN EWS
SCORE="+str[6]+"\n");
}
} catch (SQLException ex) {
Logger.getLogger(MainWindow.class.getName()).log(Level.SEVER
E, null, ex);
}
this.BtnImportRule.setEnabled(false);
122
this.BtnRemoveRule.setEnabled(true);
}
else {
this.BtnImportRule.setEnabled(true);
this.BtnRemoveRule.setEnabled(false);
}
}
@SuppressWarnings("unchecked")
private void initComponents() {
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON
_CLOSE);
jTabbedPane1.setName("jTabbedPane1"); // NOI18N
jPanel1.setName("jPanel1"); // NOI18N
123
Textsbp.addActionListener(new
java.awt.event.ActionListener() {
public void
actionPerformed(java.awt.event.ActionEvent evt) {
TextsbpActionPerformed(evt);
}
});
Textsbp.addKeyListener(new
java.awt.event.KeyAdapter() {
public void keyPressed(java.awt.event.KeyEvent
evt) {
TextsbpKeyPressed(evt);
}
public void keyReleased(java.awt.event.KeyEvent
evt) {
TextsbpKeyReleased(evt);
}
});
jScrollPane1.setName("jScrollPane1"); // NOI18N
HasilText.setColumns(20);
HasilText.setEditable(false);
HasilText.setRows(5);
HasilText.setName("HasilText"); // NOI18N
jScrollPane1.setViewportView(HasilText);
jScrollPane2.setName("jScrollPane2"); // NOI18N
ProsessText.setColumns(20);
ProsessText.setEditable(false);
ProsessText.setRows(5);
ProsessText.setName("ProsessText"); // NOI18N
jScrollPane2.setViewportView(ProsessText);
Texthr.setToolTipText("Heart Rate");
Texthr.setName("Texthr"); // NOI18N
Texthr.addActionListener(new
java.awt.event.ActionListener() {
public void
actionPerformed(java.awt.event.ActionEvent evt) {
TexthrActionPerformed(evt);
}
});
Texthr.addKeyListener(new
124
java.awt.event.KeyAdapter() {
public void keyPressed(java.awt.event.KeyEvent
evt) {
TexthrKeyPressed(evt);
}
public void keyReleased(java.awt.event.KeyEvent
evt) {
TexthrKeyReleased(evt);
}
});
Textspo2.setToolTipText("Oxygen Saturation");
Textspo2.setName("Textspo2"); // NOI18N
Textspo2.addActionListener(new
java.awt.event.ActionListener() {
public void
actionPerformed(java.awt.event.ActionEvent evt) {
Textspo2ActionPerformed(evt);
}
});
Textspo2.addKeyListener(new
java.awt.event.KeyAdapter() {
public void keyPressed(java.awt.event.KeyEvent
evt) {
Textspo2KeyPressed(evt);
}
public void keyReleased(java.awt.event.KeyEvent
evt) {
Textspo2KeyReleased(evt);
}
});
Texttemp.setToolTipText("Temperature");
Texttemp.setName("Texttemp"); // NOI18N
Texttemp.addActionListener(new
java.awt.event.ActionListener() {
public void
actionPerformed(java.awt.event.ActionEvent evt) {
TexttempActionPerformed(evt);
}
});
Texttemp.addKeyListener(new
java.awt.event.KeyAdapter() {
public void keyPressed(java.awt.event.KeyEvent
evt) {
125
TexttempKeyPressed(evt);
}
public void keyReleased(java.awt.event.KeyEvent
evt) {
TexttempKeyReleased(evt);
}
});
Textbs.setToolTipText("Blood Sugar");
Textbs.setName("Textbs"); // NOI18N
Textbs.addActionListener(new
java.awt.event.ActionListener() {
public void
actionPerformed(java.awt.event.ActionEvent evt) {
TextbsActionPerformed(evt);
}
});
Textbs.addKeyListener(new
java.awt.event.KeyAdapter() {
public void keyPressed(java.awt.event.KeyEvent
evt) {
TextbsKeyPressed(evt);
}
public void keyReleased(java.awt.event.KeyEvent
evt) {
TextbsKeyReleased(evt);
}
});
BtnPrediksi.setText("CALCULATE");
BtnPrediksi.setName("BtnPrediksi"); // NOI18N
BtnPrediksi.addActionListener(new
java.awt.event.ActionListener() {
public void
actionPerformed(java.awt.event.ActionEvent evt) {
BtnPrediksiActionPerformed(evt);
}
});
BtnReset.setText("RESET");
BtnReset.setName("BtnReset"); // NOI18N
BtnReset.addActionListener(new
java.awt.event.ActionListener() {
public void
actionPerformed(java.awt.event.ActionEvent evt) {
126
BtnResetActionPerformed(evt);
}
});
Labelsbp.setText("SBP");
Labelsbp.setName("Labelsbp"); // NOI18N
Labelhr.setText("HR");
Labelhr.setName("Labelhr"); // NOI18N
Labelspo2.setText("SPO2");
Labelspo2.setName("Labelspo2"); // NOI18N
Labeltemp.setText("TEMP");
Labeltemp.setName("Labeltemp"); // NOI18N
Labelbs.setText("BS");
Labelbs.setName("Labelbs"); // NOI18N
BtnImportRule.setText("Import Rule");
BtnImportRule.setName("BtnImportRule"); // NOI18N
BtnImportRule.addActionListener(new
java.awt.event.ActionListener() {
public void
actionPerformed(java.awt.event.ActionEvent evt) {
BtnImportRuleActionPerformed(evt);
}
});
BtnRemoveRule.setText("Remove Rule");
BtnRemoveRule.setName("BtnRemoveRule"); // NOI18N
BtnRemoveRule.addActionListener(new
java.awt.event.ActionListener() {
public void
actionPerformed(java.awt.event.ActionEvent evt) {
BtnRemoveRuleActionPerformed(evt);
}
});
jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Al
127
ignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addContainerGap()
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.Grou
pLayout.Alignment.LEADING)
.addComponent(jScrollPane2,
javax.swing.GroupLayout.Alignment.TRAILING,
javax.swing.GroupLayout.DEFAULT_SIZE, 649, Short.MAX_VALUE)
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING,
jPanel1Layout.createSequentialGroup()
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.Grou
pLayout.Alignment.LEADING, false)
.addComponent(Labelsbp,
javax.swing.GroupLayout.DEFAULT_SIZE, 100, Short.MAX_VALUE)
.addComponent(Labelhr,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(Labelspo2,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(BtnPrediksi,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(Labeltemp,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(Labelbs,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
.addGap(36, 36, 36)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.Grou
pLayout.Alignment.LEADING, false)
.addComponent(BtnReset,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(Textsbp,
javax.swing.GroupLayout.DEFAULT_SIZE, 119, Short.MAX_VALUE)
.addComponent(Texthr)
.addComponent(Textspo2)
.addComponent(Texttemp)
.addComponent(Textbs))
128
.addGap(66, 66, 66)
.addComponent(jScrollPane1,
javax.swing.GroupLayout.PREFERRED_SIZE, 307,
javax.swing.GroupLayout.PREFERRED_SIZE))
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(BtnImportRule,
javax.swing.GroupLayout.PREFERRED_SIZE, 113,
javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.
UNRELATED)
.addComponent(BtnRemoveRule)))
.addContainerGap())
);
jPanel1Layout.setVerticalGroup(
jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Al
ignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addContainerGap()
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.Grou
pLayout.Alignment.LEADING)
.addComponent(jScrollPane1)
.addGroup(jPanel1Layout.createSequentialGroup()
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.Grou
pLayout.Alignment.BASELINE)
.addComponent(Textsbp,
javax.swing.GroupLayout.PREFERRED_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(Labelsbp))
.addGap(18, 18, 18)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.Grou
pLayout.Alignment.BASELINE)
.addComponent(Texthr,
javax.swing.GroupLayout.PREFERRED_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(Labelhr))
.addGap(18, 18, 18)
129
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.Grou
pLayout.Alignment.BASELINE)
.addComponent(Textspo2,
javax.swing.GroupLayout.PREFERRED_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(Labelspo2))
.addGap(18, 18, 18)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.Grou
pLayout.Alignment.BASELINE)
.addComponent(Texttemp,
javax.swing.GroupLayout.PREFERRED_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(Labeltemp))
.addGap(18, 18, 18)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.Grou
pLayout.Alignment.BASELINE)
.addComponent(Textbs,
javax.swing.GroupLayout.PREFERRED_SIZE,
javax.swing.GroupLayout.DEFAULT_SIZE,
javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(Labelbs))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.
RELATED, javax.swing.GroupLayout.DEFAULT_SIZE,
Short.MAX_VALUE)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.Grou
pLayout.Alignment.BASELINE)
.addComponent(BtnPrediksi)
.addComponent(BtnReset))
.addGap(9, 9, 9)))
.addGap(36, 36, 36)
.addComponent(jScrollPane2,
javax.swing.GroupLayout.PREFERRED_SIZE, 139,
javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(7, 7, 7)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.Grou
pLayout.Alignment.BASELINE)
.addComponent(BtnImportRule)
130
.addComponent(BtnRemoveRule))
.addContainerGap())
);
jTabbedPane1.addTab("main", jPanel1);
jMenuBar1.setName("jMenuBar1"); // NOI18N
jMenu1.setText("File");
jMenu1.setName("jMenu1"); // NOI18N
jMenuBar1.add(jMenu1);
jMenu2.setText("Edit");
jMenu2.setName("jMenu2"); // NOI18N
jMenuBar1.add(jMenu2);
setJMenuBar(jMenuBar1);
layout.createParallelGroup(javax.swing.GroupLayout.Alignment
.LEADING)
.addComponent(jTabbedPane1,
javax.swing.GroupLayout.Alignment.TRAILING)
);
layout.setVerticalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment
.LEADING)
.addComponent(jTabbedPane1,
javax.swing.GroupLayout.PREFERRED_SIZE, 477,
Short.MAX_VALUE)
);
pack();
}
private void
TextsbpActionPerformed(java.awt.event.ActionEvent evt) {
// TODO add your handling code here:
}
131
private void
TexthrActionPerformed(java.awt.event.ActionEvent evt) {
// TODO add your handling code here:
}
private void
Textspo2ActionPerformed(java.awt.event.ActionEvent evt) {
// TODO add your handling code here:
}
private void
TexttempActionPerformed(java.awt.event.ActionEvent evt) {
// TODO add your handling code here:
}
private void
TextbsActionPerformed(java.awt.event.ActionEvent evt) {
// TODO add your handling code here:
}
132
evt) {
if (evt.getKeyCode() == 10 || evt.getKeyCode() ==
11) {
Texttemp.requestFocus();
}
}
133
JOptionPane.showMessageDialog(null, "Inputan
berupa angka!!");
Texttemp.setText("");
}
}
private void
BtnPrediksiActionPerformed(java.awt.event.ActionEvent evt) {
if (Textsbp.getText().equals("")) {
JOptionPane.showMessageDialog(null, "Inputan
belum lengkap");
Textsbp.requestFocus();
} else if (Texthr.getText().equals("")) {
JOptionPane.showMessageDialog(null, "Inputan
belum lengkap");
Texthr.requestFocus();
} else if (Textspo2.getText().equals("")) {
JOptionPane.showMessageDialog(null, "Inputan
belum lengkap");
Textspo2.requestFocus();
} else if (Texttemp.getText().equals("")) {
JOptionPane.showMessageDialog(null, "Inputan
belum lengkap");
Texttemp.requestFocus();
} else if (Textbs.getText().equals("")) {
JOptionPane.showMessageDialog(null, "Inputan
belum lengkap");
Textbs.requestFocus();
} else {
HasilText.setText("");
ProsessText.setText("");
double Risk = new
PCMFuzzy(Double.valueOf(Textsbp.getText()),
Double.valueOf(Texthr.getText()),
Double.valueOf(Textspo2.getText()),
134
Double.valueOf(Texttemp.getText()),
Double.valueOf(Textbs.getText()),startConn,
this).getRiskPrediction();
HasilText.append("\n\n\n***** FINISHED *****");
}
}
private void
BtnResetActionPerformed(java.awt.event.ActionEvent evt) {
Textsbp.setText("");
Texthr.setText("");
Textspo2.setText("");
Texttemp.setText("");
Textbs.setText("");
HasilText.setText("");
initRule();
Textsbp.requestFocus();
}
private void
BtnImportRuleActionPerformed(java.awt.event.ActionEvent evt)
{
int sbp[]=systolicBloodPressure.getSbpLinguistic();
int hr[]=heartRate.getHeartRateLinguistic();
int
spo2[]=oxygenSaturation.getOxygenSaturationLinguistic();
int temp[]=temperature.getTemperatureLinguistic();
int bs[]=bloodSugar.getBloodSugarLinguistic();
int total=0, jumlah=0, jumlahRule=0;
String sql=null;
//jumlahRule=sbp.length*hr.length*spo2.length*temp.length*bs
.length;
for(int a=0;a<sbp.length;a++){
for(int b=0;b<hr.length;b++){
for(int c=0;c<spo2.length;c++){
for(int d=0;d<temp.length;d++){
for(int e=0;e<bs.length;e++){
jumlah=Math.abs(sbp[a])+Math.abs(hr[b])+Math.abs(spo2[
c])+Math.abs(temp[d])+Math.abs(bs[e]);
startConn.dmlQuery("insert
into rule (SBP,HR,SPO2,TEMP,BS,risk) values
135
("+sbp[a]+","+hr[b]+","+spo2[c]+","+temp[d]+","+bs[e]+","+ju
mlah+")");
//this.ProsessText.append((total+1)+". If
SystolicBloodPressure="+this.convertToString(sbp[a])+" and
HeartRate="+this.convertToString(hr[b])+" and
OxygenSaturation="+this.convertToString(spo2[c])+" and
Temperature="+this.convertToString(temp[d])+" and
BloodSugar="+this.convertToString(bs[e])+" THEN EWS
SCORE="+jumlah+"\n");
private void
BtnRemoveRuleActionPerformed(java.awt.event.ActionEvent evt)
{
int dialogButton = JOptionPane.NO_OPTION;
JOptionPane.showConfirmDialog (null, "Would You Like
to Delete All Rule ?","Warning",dialogButton);
} else {
return false;
}
136
}
137
private javax.swing.JLabel Labeltemp;
private javax.swing.JTextArea ProsessText;
private javax.swing.JTextField Textbs;
private javax.swing.JTextField Texthr;
private javax.swing.JTextField Textsbp;
private javax.swing.JTextField Textspo2;
private javax.swing.JTextField Texttemp;
private javax.swing.JMenu jMenu1;
private javax.swing.JMenu jMenu2;
private javax.swing.JMenuBar jMenuBar1;
private javax.swing.JPanel jPanel1;
private javax.swing.JScrollPane jScrollPane1;
private javax.swing.JScrollPane jScrollPane2;
private javax.swing.JTabbedPane jTabbedPane1;
5.2.1.12 TestUnit.java
package ui;
import java.awt.Dimension;
import java.awt.Toolkit;
Dimension dimension =
Toolkit.getDefaultToolkit().getScreenSize();
int x = (int) ((dimension.getWidth() -
loginForm.getWidth()) / 2);
int y = (int) ((dimension.getHeight() -
138
loginForm.getHeight()) / 2);
loginForm.setLocation(x, y);
}
});
}
}
Antarmuka aplikasi terdiri dari dua bagian yaitu antarmuka log in dan
antarmuka utama. Antarmuka log in digunakan untuk autentikasi pengguna
aplikasi. Hanya pengguna dengan level admininistrator yang dapat menggunakan
aplikasi ini, misal perawat dan dokter. Antarmuka utama terditi dari beberapa field
input dan output yaitu field input kondisi pasien berdasarkan tekanan darah
sistolik (SBP), jetak jantung (HR), tingkat kejenuhan oksigen darah (SPO2), suhu
tubuh (TEMP), dan gula darah (BS). Field output terdari dari dua bagian yaitu
field output hasil perhitungan fuzzy dengan metode FIS Tsukamoto dan field
output rule. Gambar
139
Gambar 5.2 Antarmuka Window Utama
Sumber: Perancangan
140
BAB VI
PENUTUP
7.1 Kesimpulan
7.2 Saran
- Aplikasi ini memberikan deteksi dini untuk pemantauan pasien rawat inap.
- Untuk dapat mengembangkan Fuzzy Tsukamoto untuk mengetahui faktor-
faktor pada kondisi pasien.
- Untuk menyertakan faktor jenis kelamin dan usia dalam proses
pengambilan keputusan.
Hasil dari sistem yang diusulkan mengkonfirmasi efektivitas logika fuzzy
dalam pemantauan pasien, tetapi masih perlu diuji dalam lingkungan real-time
untuk menunjukkan nilai klinis penuh.
141
DAFTAR PUSTAKA
[1] Yohana, Antin. 2009. Analisis Harapan Dan Kepuasan Pasien Rawat Inap
Penyakit Dalam Terhadap Mutu Pelayanan Dokter Spesialis Di Rsi Sunan
Kudus. Semarang: Universitas Diponegoro.
[2] Teori Penunjang Sistem Pakar. URL: http://www.informatika.web.id,
diakses pada tanggal 7 April 2014.
[3] Abdurrahman, Ginanjar. 2011. Penerapan Metode Tsukamoto (Logika
Fuzzy) dalam Sistem Pendukung Keputusan untuk Menentukan Jumlah
Produksi Barang Berdasarkan Data Persediaan dan Jumlah Permintaan.
Yogyakarta: Universitas Negeri Yogyakarta.
[4] Niemeyer, Pat dan Jonathan Knudsen. 2010. Learning Java. O'Reilly.
[5] Al-Dmour, J.A. 2013. Fuzzy Logic Based Patients Monitoring System.
Thesis tidak diterbitkan, United Arab Emirates, Faculty of American
University of Sharjah College of Engineering.
[6] Purwanto, Ikhlas. 2009. Studi Pengukuran Kemiripan Rantai DNA Virus
H5N1 Berbasis Himpunan Fuzzy. Depok: Universitas Indonesia.
[7] Dalgleish, Jordanne and Beatrice Mpamugo Colleen Kearney. 2010.
Adapting and Implementing SBAR in a Home Care Setting.
[8] KepMenKes RI no. 159b/MENKES/PER/II/1988 .Rumah Sakit. Jakarta:
DepKes RI.
[9] The National Early Warning Score Project Governance and Advisory
Groups as a work stream of the Acute Medicine Progamme. 2012. Guiding
Framework and Policy for the National Early Warning Score System to
Recognise and Respond to Clinical Deterioration. Ireland:
Feidhmearnnacht ma Smirbhise Stainte Health Service Execullve.
[10] Thamrin, Fanoeel. Studi Inferensi Fuzzy Tsukamoto untuk Penentuan
Faktor Pembebasan Trafo PLN. Semarang.
[11] Sistem Pakar. URL: http://birtandp.wordpress.com/tag/manfaat-sistem-
pakar/, diakses pada tanggal 29 Mei 2014.
142
[12] Broto, A.S. 2010. Perancangan Dan Implementasi Sistem Pakar Untuk
Analisa Penyakit Dalam. Semarang: Universitas Diponegoro.
[13] Tahap Pemodelan Dalam Fuzzy Logic. URL:
http://fahmizaleeits.wordpress.com/category/kuliah-kontrol/fuzzy-
logic/page/2/, diakses pada tanggal 29 Mei 2014.
[14] Rochmat, Noer. 2014. Implementasi Sasaran Keselamatan Pasien:
Komunikasi Efektif Di Instalasi Rawat Inap. Pemerintah Propinsi Jawa
Tengah RSUD Tugurejo Semarang.
143