SPSS — WPO 1
(Deel 1)
Examenvoorbereiding
gapminder_2023.csv
SPSS & Statistiek — WPO 1 —Introductie | Sude Derya
, Vraag 1 — CSV inlezen in SPSS
Wat wordt gevraagd?
Bestand importeren en datatypes controleren (numeriek vs. string).
SPSS stappen
Instelling Waarde
Scheidingsteken Komma ,
Decimaalteken Punt .
Eerste rij = variabelenamen Ja
Missing values NA
GET DATA /TYPE=TXT /FILE="gapminder_2023.csv"
/DELIMITERS="," /QUALIFIER='"'
/FIRSTCASE=2
/VARIABLES= country A50 hap_2005 F8.2 ... life_exp_2023 F8.2.
CACHE. EXECUTE.
Controleer: Variable View → kolom Type → numerieke vars = Numeric, tekstvars = String
Belangrijk
• A50 = String (tekst, max 50 tekens) | F8.2 = Numeriek (8 breed, 2 decimalen)
• FIRSTCASE=2 → rij 1 = kolomnamen, data begint op rij 2
Valkuil: Als NA niet als missing wordt ingesteld → kolom wordt als String ingelezen i.p.v.
Numeric.
Oplossing: NA invullen bij missing values in de importwizard.
Tip: Europese pc's gebruiken soms puntkomma ; als scheidingsteken — kijk altijd eerst in
Notepad!
SPSS & Statistiek — WPO 1 —Introductie | Sude Derya
, Vraag 2 — Bevolkingsgrootte (pop_2023)
2a — Histogram & boxplot
2b — Rangvariabele & top 10
RANK VARIABLES=pop_2023 (D) /RANK /TIES=MEAN.
SELECT IF (Rpop_2023 <= 10). EXECUTE.
2c — Totale bevolking per continent
Data → Aggregate → Break: world_4region → Aggregated: SUM(pop_2023) → OK
GRAPH /BAR(SIMPLE)=SUM(pop_2023) BY world_4region.
groups of cases vs. separate variables:
SPSS & Statistiek — WPO 1 —Introductie | Sude Derya
(Deel 1)
Examenvoorbereiding
gapminder_2023.csv
SPSS & Statistiek — WPO 1 —Introductie | Sude Derya
, Vraag 1 — CSV inlezen in SPSS
Wat wordt gevraagd?
Bestand importeren en datatypes controleren (numeriek vs. string).
SPSS stappen
Instelling Waarde
Scheidingsteken Komma ,
Decimaalteken Punt .
Eerste rij = variabelenamen Ja
Missing values NA
GET DATA /TYPE=TXT /FILE="gapminder_2023.csv"
/DELIMITERS="," /QUALIFIER='"'
/FIRSTCASE=2
/VARIABLES= country A50 hap_2005 F8.2 ... life_exp_2023 F8.2.
CACHE. EXECUTE.
Controleer: Variable View → kolom Type → numerieke vars = Numeric, tekstvars = String
Belangrijk
• A50 = String (tekst, max 50 tekens) | F8.2 = Numeriek (8 breed, 2 decimalen)
• FIRSTCASE=2 → rij 1 = kolomnamen, data begint op rij 2
Valkuil: Als NA niet als missing wordt ingesteld → kolom wordt als String ingelezen i.p.v.
Numeric.
Oplossing: NA invullen bij missing values in de importwizard.
Tip: Europese pc's gebruiken soms puntkomma ; als scheidingsteken — kijk altijd eerst in
Notepad!
SPSS & Statistiek — WPO 1 —Introductie | Sude Derya
, Vraag 2 — Bevolkingsgrootte (pop_2023)
2a — Histogram & boxplot
2b — Rangvariabele & top 10
RANK VARIABLES=pop_2023 (D) /RANK /TIES=MEAN.
SELECT IF (Rpop_2023 <= 10). EXECUTE.
2c — Totale bevolking per continent
Data → Aggregate → Break: world_4region → Aggregated: SUM(pop_2023) → OK
GRAPH /BAR(SIMPLE)=SUM(pop_2023) BY world_4region.
groups of cases vs. separate variables:
SPSS & Statistiek — WPO 1 —Introductie | Sude Derya