-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathanalyze_survey.py
More file actions
114 lines (94 loc) · 3.59 KB
/
analyze_survey.py
File metadata and controls
114 lines (94 loc) · 3.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
import csv
from collections import Counter
# CSV einlesen (mit latin-1 encoding)
with open('Mitgliederumfrage 2026 - Veranstaltungen & Mehrwert.csv', 'r', encoding='latin-1') as f:
reader = csv.DictReader(f, delimiter=';')
rows = [row for row in reader if row.get('Voter')] # Nur Zeilen mit Voter-ID
print(f"Anzahl Teilnehmer: {len(rows)}\n")
# 1. Unternehmensgrößen
company_sizes = Counter()
for row in rows:
size = row.get('Wie groß ist dein Unternehmen?:', '').strip()
if size:
company_sizes[size] += 1
print("=== UNTERNEHMENSGRÖ�EN ===")
for size, count in company_sizes.most_common():
print(f"{size}: {count}")
# 2. Branchen
industries = Counter()
for row in rows:
industry = row.get('In welcher Branche bist du tätig?:', '').strip()
if industry:
industries[industry] += 1
print("\n=== BRANCHEN ===")
for industry, count in industries.most_common():
print(f"{industry}: {count}")
# 3. Besuchshäufigkeit
frequency = Counter()
for row in rows:
freq = row.get('Wie viele Veranstaltungen der Wirtschaftsrunde besuchst du jährlich?:', '').strip()
if freq:
frequency[freq] += 1
print("\n=== BESUCHSHÄUFIGKEIT ===")
for freq, count in frequency.most_common():
print(f"{freq}: {count}")
# 4. Top 5 Veranstaltungen (alle 5 Spalten zusammen)
events = Counter()
for row in rows:
for i in range(1, 6):
event = row.get(f'Welche Veranstaltungen sprechen dich am meisten an?: {i}', '').strip()
if event:
events[event] += 1
print("\n=== TOP VERANSTALTUNGEN ===")
for event, count in events.most_common(15):
print(f"{event}: {count}")
# 5. Mehrwert-Kategorien (Top 3)
values = Counter()
for row in rows:
for i in range(1, 4):
value = row.get(f'Wann haben die Veranstaltungen der Buchholzer Wirtschaftsrunde für dich persönlich den größten Mehrwert?: {i}', '').strip()
if value:
values[value] += 1
print("\n=== MEHRWERT-KATEGORIEN ===")
for value, count in values.most_common():
print(f"{value}: {count}")
# 6. Kontakt-Präferenz
preference = Counter()
for row in rows:
pref = row.get('Was ist dir bei Veranstaltungen wichtiger?:', '').strip()
if pref:
preference[pref] += 1
print("\n=== KONTAKT-PRÄFERENZ ===")
for pref, count in preference.most_common():
print(f"{pref}: {count}")
# 7. Attraktivität Austauschformate
attractiveness = Counter()
for row in rows:
attr = row.get('Wie attraktiv findest du Veranstaltungsformate, bei denen der Fokus auf aktivem Austausch und Diskussion liegt?:', '').strip()
if attr:
attractiveness[attr] += 1
print("\n=== ATTRAKTIVITÄT AUSTAUSCHFORMATE ===")
for attr, count in attractiveness.most_common():
print(f"{attr}: {count}")
# 8. Beteiligungsformen (bis zu 4 möglich)
participation = Counter()
for row in rows:
for i in range(1, 5):
part = row.get(f'In welcher Form könntest du dir eine Beteiligung an der Weiterentwicklung der Wirtschaftsrunde vorstellen?: {i}', '').strip()
if part:
participation[part] += 1
print("\n=== BETEILIGUNGSFORMEN ===")
for part, count in participation.most_common():
print(f"{part}: {count}")
# 9. Verbesserungswünsche (Themen identifizieren)
improvements = []
for row in rows:
for i in range(1, 4):
imp = row.get(f'Was können wir verbessern? Welche konkreten Wünsche hast du?: {i}', '').strip()
if imp:
improvements.append(imp)
print(f"\n=== VERBESSERUNGSW�NSCHE ({len(improvements)} Nennungen) ===")
for imp in improvements[:10]: # Erste 10
print(f"- {imp[:100]}...")