Download as pdf or txt
Download as pdf or txt
You are on page 1of 18

LAPORAN PRAKTIKUM STATISTIKA

TRANSFORMASI DATA

Disusun Oleh:

Nama : Ratna Khoirun Nisa

Nim : 23.02.1001

Kelas : D3 MI02

Dosen : Dina Maulina, M.Kom

MANAJEMEN INFORMATIKA - FAKULTAS ILMU KOMPUTER


UNIVERSITAS AMIKOM YOGYAKARTA
YOGYAKARTA
2023/2024
Soal No 1
1. Membuat variabel Kategori dengan ketentuan range:
a. Menggunakan Menu Transform | Record Into Deffrent Variables
b. Lalu inputkan Numeric variable dan output variable yaitu Gaji Kategori

c. Setelah itu masuk ke menu Old and New Values dan masukkan OLD VALUE sesuai
dengan ketentuan terendah menggunakan Range LOWEST dan untuk NEW VALUE,
inputkan Rendah, OLD VALUE antara menggunakan Range dan untuk NEW VALUE
inputkan Sedang , dan untuk tertinggi menggunakan Range Highest NEW VALUE
inputkan Tinggi

1
Soal No 2
2. Buat variabel tunjangan untuk karyawan yang statusnya sudah menikah dan punya anak.
Pada variabel tersebut akan muncul kata DAPAT, bagi yang memenuhi syarat
a. Menggunakan Menu Transform | Compute Variable

b. Masukkan Rumus Tersebut

2
Soal No 3
3. Munculkan kata Dibantu pada variabel Bantuan dengan ketentuan sudah menikah
gajinya termasuk kategori rendah dan anaknya lebih dari 1.
a. Menggunakkan Menu Transform | Compute Variable

b. Masukkan Rumus Tersebut

3
Soal No 4
4. Membuat Variable Tunj-Anak, dengan ketentuan per anak mendapatkan tunjangan
sebesar Rp. 135.000
a. Menggunakan Menu Transform | Compute Variable

b. Lalu Untuk If nya menggunakan Include All Case

4
Soal No 5
1. Buat variabel Masa Kerja dengan mengubah variabel Kategori dengan ketentuan
sbb: Kategori Rendah masa kerjanya kurang dari 1 tahun
Kategori Sedang masa kerja lebih dari 1 tahun sampai dengan 3 tahun
Kategori Tinggi masa kerja lebih dari 3 tahun

a. Menggunakan Menu Transform | Record Into Deffrent Variables


b. Lalu inputkan String Variable dan Output Variable Kategori Masa_Kerja

c. Masuk ke menu Old and New Values, dan inputkan old value dan new value
nya

5
Soal No 6
1.Buatlah variabel bonus gaji dengan ketentuan sbb:
untuk yang masa kerja 1 sampai dengan 3 tahun dapat bonus 25% dari gaji
untuk yang masa kerja lebih dari 3 tahun dapat bonus 50% dari gaji
untuk yang masa kurang dari 1 tahun belum mendapat bonus gaji

a. Menggunakan Menu Transform | Compute Variable


b. Masukkan Target Variabel Bonus_Gaji, dan Numeric Expresion dengan Rumus
tersebut dan juga masukkan IF sesui dengan Kategori nya
c. Masukkan ketentuan selanjutnya dengan cara mereset terlebih dahlu data yang ada
agar rumus tidak menumpuk

6
7
Soal No 7
1. Buatl variabel total gaji kotor dengan menjumlahkan gaji dengan tunjangan anak dan
bonus.
a. Menggunakan Menu Transform | Compute Variable

Soal No 8
1. Buatlah variabel potong pajak dengan ketentuan semua gaji dikurangi pajak PPh 5%
a. Menggunakan Menu Transform | Compute Variable

8
Soal No 9
1. Buatlah variabel Gaji diterima setelah dipotong pajak 5%.
a. Menggunakan Menu Transform | Compute Variable

9
DATASET NAME DataSet1 WINDOW=FRONT.
IF (Gaji*0) Bonus_Gaji=Kategori ="Rendah".
EXECUTE.
IF (Gaji*0.25) Bonus_Gaji=Kategori ="Sedang".
EXECUTE.

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 40 Current case: 1 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 40 Current case: 2 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 40 Current case: 3 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 40 Current case: 4 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 40 Current case: 5 Current splitfile group: 1

Page 1
>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 40 Current case: 6 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 40 Current case: 7 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 40 Current case: 8 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 40 Current case: 9 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 40 Current case: 10 Current splitfile group: 1

>Warning # 92
>The limit for MXWARNS warnings in this data pass has been exceeded. Further
>warnings have been suppressed. To change the limit use SET MXWARNS.
IF (Gaji*0.25) Bonus_Gaji=Kategori ="Sedang".
EXECUTE.

Page 2
>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 44 Current case: 1 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 44 Current case: 2 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 44 Current case: 3 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 44 Current case: 4 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 44 Current case: 5 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 44 Current case: 6 Current splitfile group: 1

Page 3
>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 44 Current case: 7 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 44 Current case: 8 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 44 Current case: 9 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 44 Current case: 10 Current splitfile group: 1

>Warning # 92
>The limit for MXWARNS warnings in this data pass has been exceeded. Further
>warnings have been suppressed. To change the limit use SET MXWARNS.
IF (Gaji*0.25) Bonus_Gaji=Kategori ="Sedang".
EXECUTE.

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 48 Current case: 1 Current splitfile group: 1

>Warning # 510
Page 4
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 48 Current case: 2 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 48 Current case: 3 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 48 Current case: 4 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 48 Current case: 5 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 48 Current case: 6 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 48 Current case: 7 Current splitfile group: 1

>Warning # 510
Page 5
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 48 Current case: 8 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 48 Current case: 9 Current splitfile group: 1

>Warning # 510
>During execution of the indicated command, an expression which should have
>yielded a logical value produced a value other than 0, 1, or missing. The
>result has been set to the system-missing value.
>Command line: 48 Current case: 10 Current splitfile group: 1

>Warning # 92
>The limit for MXWARNS warnings in this data pass has been exceeded. Further
>warnings have been suppressed. To change the limit use SET MXWARNS.
IF (Kategori = "Rendah") Bonus_Gaji=Bonus_Gaji * 0.
EXECUTE.
IF (Kategori = "Sedang") Bonus_Gaji=Bonus_Gaji * 0.25.
EXECUTE.
IF (Kategori = "Sedang") Bonus_Gaji=Bonus_Gaji * 0.25.
EXECUTE.
IF (Kategori = "Sedang") Bonus_Gaji=Gaji * 0.25.
EXECUTE.
IF (Kategori = "Tinggi") Bonus_Gaji=Gaji * 0.5.
EXECUTE.
COMPUTE Gaji_Kotor=Gaji + Tunjangan_Anak + Bonus_Gaji.
EXECUTE.
COMPUTE Potong_Pajak=Gaji_Kotor * 0.05.
EXECUTE.
COMPUTE Gaji_Diterima=Gaji_Kotor - Potong_Pajak.
EXECUTE.
DATASET ACTIVATE DataSet1.

SAVE OUTFILE='C:\Users\user\Downloads\Pertemuan3 (1).sav'


Page 6
/COMPRESSED.

GET
FILE='C:\Users\user\Documents\Ratna\Statistika\Pertemuan3 (1).sav'.
DATASET NAME DataSet2 WINDOW=FRONT.
GET
FILE='C:\Users\user\Documents\Ratna\Statistika\Pertemuan3 (1).sav'.

RECODE Gaji (Lowest thru 1000000='Rendah') (1000000 thru 1500000='Sedang') (15


00000 thru
='Tinggi') INTO Kategori.
EXECUTE.

EXECUTE.
DATASET ACTIVATE DataSet2.
NEW FILE.
DATASET NAME DataSet4 WINDOW=FRONT.

EXECUTE.
STRING Tunjangan (A20).
IF (Status = 1 & Jml_Anak > 0) Tunjangan="Dapat".
EXECUTE.

IF (Status =2) Tunjangan ="Tidak Dapat"


EXECUTE

IF (Status=1 & Jml_Anak=0) Tunjangan="Tidak Dapat".


VARIABLE LABELS Tunjangan 'Tunjangan Karawan'.
EXECUTE.

DATASET CLOSE DataSet3.


GET
STRING Bantuan (A8).

IF (Status = 1 & Kategori = "Rendah"& Jml_Anak > 1) Bantuan="Dibantu".


EXECUTE.

COMPUTE Tunj_Anak=Jml_Anak*135000.

Page 7
EXECUTE.

STRING Masa_Kerja (A30).


RECODE Kategori ('Rendah'='Kurang dari 1 Tahun') ('Sedang'='1 Sampai 3 Tahun')
('Tinggi'='Lebih '+
'dari 3 Tahun') INTO Masa_Kerja.
EXECUTE.
IF (Kategori = "Rendah") Bonus_Gaji=Gaji*0.
EXECUTE.
IF (Kategori="Sedang") Bonus_Gaji=Gaji * 0.25.
EXECUTE.
IF (Kategori = "Tinggi") Bonus_Gaji=Gaji * 0.5.
EXECUTE.
COMPUTE Gaji_Kotor=Gaji + Tunj_Anak + Bonus_Gaji.
EXECUTE.
COMPUTE pot_pajak=Gaji_Kotor * 0.05.
EXECUTE.
COMPUTE Gaji_Bersih=Gaji_Kotor - pot_pajak.
EXECUTE.
DATASET ACTIVATE DataSet1.

SAVE OUTFILE='C:\Users\user\Documents\Ratna\Statistika\23.02.1001_Ratna_Respon
si2.sav'
/COMPRESSED.

DATASET ACTIVATE DataSet1.

SAVE OUTFILE='C:\Users\user\Documents\Ratna\Statistika\23.02.1001_Ratna_Respon
si2.sav'
/COMPRESSED.

Page 8

You might also like