-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstats_of_features.py
More file actions
531 lines (357 loc) · 23.7 KB
/
Copy pathstats_of_features.py
File metadata and controls
531 lines (357 loc) · 23.7 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
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
import pandas as pd
import numpy as np
import scipy
# WIP notes to self
# export the the final section features for all IPUs to another csv, to make the Population data
# the Target IPUs data is already complete, for IPU-final features
# Python script for performing speaker normalization and z-score calculations for each feature for each talker
# Input CSV file format:
# From Praat's output
# CSV file produced by Praat pertaining only to the Quiet Target IPUs
df_quiet_target = pd.read_csv("C:/Users/Ludens/Documents/GitHubProjects/Praat-IPUs/Praat_Quiet_TargetIPUs_Results.csv")
# CSV file produced by Praat pertaining only to all Quiet IPUs
df_quiet_population= pd.read_csv("C:/Users/Ludens/Documents/GitHubProjects/Praat-IPUs/Praat_Quiet_Population_Results.csv")
# CSV file produced by Praat pertaining only to the In-Noise Target IPUs
df_noise_target = pd.read_csv("C:/Users/Ludens/Documents/GitHubProjects/Praat-IPUs/Praat_Noise_TargetIPUs_Results.csv")
# CSV file produced by Praat pertaining only to all In-Noise IPUs
df_noise_population = pd.read_csv("C:/Users/Ludens/Documents/GitHubProjects/Praat-IPUs/Praat_Noise_Population_Results.csv")
# create a dictionary for each feature with keys being the talkers, and values for each key being the mean and standard deviation
def population_stats_dict(df, feature):
# talkers, as numbered in this study
talkers = [3, 4, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28 , 29, 30]
# initialize a dictionary to store results
population_stats = {}
# iterate through talkers, selecting only the chosen feature for this talker's IPUs
# if the feature has a value of 0 or is undefined, it is invalid for this IPU
# e.g. mean intensity in final 500 ms for an IPU with duration of 200 ms, or e.g. the final section is entirely unvoiced
for a_talker in talkers:
filtered = df.loc[(df["Talker"] == a_talker) & (df[feature] != "0") & (df[feature] != "--undefined--")][feature].astype(float).tolist()
mean = np.mean(filtered)
# population standard deviation
stdev = np.std(filtered, ddof=0)
# update dictionary, for this feature and this talker, here is its population mean and population standard deviation
population_stats[a_talker] = {"mean": mean, "stdev": stdev}
return population_stats
# for one feature, get the average z-score of each talker's Target IPUs normalized against all IPUs of the same talker
def z_score_dict(df, feature, population_stats):
# talkers, as numbered in this study
talkers = [3, 4, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28 , 29, 30]
# initialize a dictionary to store results
feature_z_scores = {}
# iterate through talkers, selecting only the chosen feature for this talker's IPUs
# if the feature has a value of 0 or is undefined, it is invalid for this IPU
# e.g. mean intensity in final 500 ms for an IPU with duration of 200 ms, or e.g. the final section is entirely unvoiced
for a_talker in talkers:
filtered = df.loc[(df["Talker"] == a_talker) & (df[feature] != "0") & (df[feature] != "--undefined--")][feature].astype(float).tolist()
# grab the population mean and population standard deviation for this talker for this feature
this_pop_mean = population_stats[a_talker]["mean"]
this_pop_stdev = population_stats[a_talker]["stdev"]
# initialize list to contain the z-scores of each Target IPU
# i.e. each Target IPU producing one random variable x, for z = (x - mean)/stdev
all_z_scores = []
# calculate the z-score for each Target IPU and add them to the list
for i in range(len(filtered)):
individual_z_score = (filtered[i] - this_pop_mean) / this_pop_stdev
all_z_scores.append(individual_z_score)
# print(a_talker, " length of all_z_scores: ", len(all_z_scores))
# get some statistics about the z-scores
z_min = np.min(all_z_scores)
z_max = np.max(all_z_scores)
z_mean = np.mean(all_z_scores)
z_stdev = np.std(all_z_scores, ddof=0)
# update dictionary
feature_z_scores[a_talker] = {"talker_zscore_mean": z_mean, "talker_zscore_stdev": z_stdev,
"talker_zscore_min": z_min, "talker_zscore_max": z_max,
"talker_zscore_full_list": all_z_scores}
return feature_z_scores
###################################################################################################
# MEAN INTENSITY
###################################################################################################
# "Mean_Inten_Final_500" in Quiet
# population mean and standard deviation
population_QMIf500 = population_stats_dict(df_quiet_population, feature="Mean_Inten_Final_500")
# z-scores of all talkers' Target IPUs for this feature
z_QMIf500 = z_score_dict(df_quiet_target, feature="Mean_Inten_Final_500", population_stats=population_QMIf500)
# take the average between talkers, for the talkers' mean z-score for this feature
z_QMIf500_mean_list = [value['talker_zscore_mean'] for value in z_QMIf500.values()]
z_talkers_mean_QMIf500 = np.mean(z_QMIf500_mean_list)
print("z_talkers_mean_QMIf500:", z_talkers_mean_QMIf500)
# "Mean_Inten_Final_500" in Noise
# population mean and standard deviation
population_NMIf500 = population_stats_dict(df_noise_population, feature="Mean_Inten_Final_500")
# z-scores of all talkers' Target IPUs for this feature
z_NMIf500 = z_score_dict(df_noise_target, feature="Mean_Inten_Final_500", population_stats=population_NMIf500)
# take the average between talkers, for the talkers' mean z-score for this feature
z_NMIf500_mean_list = [value['talker_zscore_mean'] for value in z_NMIf500.values()]
z_talkers_mean_NMIf500 = np.mean(z_NMIf500_mean_list)
print("z_talkers_mean_NMIf500: ", z_talkers_mean_NMIf500)
# "Mean_Inten_Final_1000" in Quiet
# population mean and standard deviation
population_QMIf1000 = population_stats_dict(df_quiet_population, feature="Mean_Inten_Final_1000")
# z-scores of all talkers' Target IPUs for this feature
z_QMIf1000 = z_score_dict(df_quiet_target, feature="Mean_Inten_Final_1000", population_stats=population_QMIf1000)
# take the average between talkers, for the talkers' mean z-score for this feature
z_QMIf1000_mean_list = [value['talker_zscore_mean'] for value in z_QMIf1000.values()]
z_talkers_mean_QMIf1000 = np.mean(z_QMIf1000_mean_list)
print("z_talkers_mean_QMIf1000:", z_talkers_mean_QMIf1000)
# "Mean_Inten_Final_1000" in Noise
# population mean and standard deviation
population_NMIf1000 = population_stats_dict(df_noise_population, feature="Mean_Inten_Final_1000")
# z-scores of all talkers' Target IPUs for this feature
z_NMIf1000 = z_score_dict(df_noise_target, feature="Mean_Inten_Final_1000", population_stats=population_NMIf1000)
# take the average between talkers, for the talkers' mean z-score for this feature
z_NMIf1000_mean_list = [value['talker_zscore_mean'] for value in z_NMIf1000.values()]
z_talkers_mean_NMIf1000 = np.mean(z_NMIf1000_mean_list)
print("z_talkers_mean_NMIf1000: ", z_talkers_mean_NMIf1000)
###################################################################################################
# MEAN PITCH
###################################################################################################
# "Mean_Pitch_Final_500" in Quiet
# population mean and standard deviation
population_QMPf500 = population_stats_dict(df_quiet_population, feature="Mean_Pitch_Final_500")
# z-scores of all talkers' Target IPUs for this feature
z_QMPf500 = z_score_dict(df_quiet_target, feature="Mean_Pitch_Final_500", population_stats=population_QMPf500)
# take the average between talkers, for the talkers' mean z-score for this feature
z_QMPf500_mean_list = [value['talker_zscore_mean'] for value in z_QMPf500.values()]
z_talkers_mean_QMPf500 = np.mean(z_QMPf500_mean_list)
print("z_talkers_mean_QMPf500:", z_talkers_mean_QMPf500)
# "Mean_Pitch_Final_500" in Noise
# population mean and standard deviation
population_NMPf500 = population_stats_dict(df_noise_population, feature="Mean_Pitch_Final_500")
# z-scores of all talkers' Target IPUs for this feature
z_NMPf500 = z_score_dict(df_noise_target, feature="Mean_Pitch_Final_500", population_stats=population_NMPf500)
# take the average between talkers, for the talkers' mean z-score for this feature
z_NMPf500_mean_list = [value['talker_zscore_mean'] for value in z_NMPf500.values()]
z_talkers_mean_NMPf500 = np.mean(z_NMPf500_mean_list)
print("z_talkers_mean_NMPf500: ", z_talkers_mean_NMPf500)
# "Mean_Pitch_Final_1000" in Quiet
# population mean and standard deviation
population_QMPf1000 = population_stats_dict(df_quiet_population, feature="Mean_Pitch_Final_1000")
# z-scores of all talkers' Target IPUs for this feature
z_QMPf1000 = z_score_dict(df_quiet_target, feature="Mean_Pitch_Final_1000", population_stats=population_QMPf1000)
# take the average between talkers, for the talkers' mean z-score for this feature
z_QMPf1000_mean_list = [value['talker_zscore_mean'] for value in z_QMPf1000.values()]
z_talkers_mean_QMPf1000 = np.mean(z_QMPf1000_mean_list)
print("z_talkers_mean_QMPf1000:", z_talkers_mean_QMPf1000)
# "Mean_Pitch_Final_1000" in Noise
# population mean and standard deviation
population_NMPf1000 = population_stats_dict(df_noise_population, feature="Mean_Pitch_Final_1000")
# z-scores of all talkers' Target IPUs for this feature
z_NMPf1000 = z_score_dict(df_noise_target, feature="Mean_Pitch_Final_1000", population_stats=population_NMPf1000)
# take the average between talkers, for the talkers' mean z-score for this feature
z_NMPf1000_mean_list = [value['talker_zscore_mean'] for value in z_NMPf1000.values()]
z_talkers_mean_NMPf1000 = np.mean(z_NMPf1000_mean_list)
print("z_talkers_mean_NMPf1000: ", z_talkers_mean_NMPf1000)
###################################################################################################
# JITTER
###################################################################################################
# "Jitter_Final_500" in Quiet
# population mean and standard deviation
population_QJf500 = population_stats_dict(df_quiet_population, feature="Jitter_Final_500")
# z-scores of all talkers' Target IPUs for this feature
z_QJf500 = z_score_dict(df_quiet_target, feature="Jitter_Final_500", population_stats=population_QJf500)
# take the average between talkers, for the talkers' mean z-score for this feature
z_QJf500_mean_list = [value['talker_zscore_mean'] for value in z_QJf500.values()]
z_talkers_mean_QJf500 = np.mean(z_QJf500_mean_list)
print("z_talkers_mean_QJf500:", z_talkers_mean_QJf500)
# "Jitter_Final_500" in Noise
# population mean and standard deviation
population_NJf500 = population_stats_dict(df_noise_population, feature="Jitter_Final_500")
# z-scores of all talkers' Target IPUs for this feature
z_NJf500 = z_score_dict(df_noise_target, feature="Jitter_Final_500", population_stats=population_NJf500)
# take the average between talkers, for the talkers' mean z-score for this feature
z_NJf500_mean_list = [value['talker_zscore_mean'] for value in z_NJf500.values()]
z_talkers_mean_NJf500 = np.mean(z_NJf500_mean_list)
print("z_talkers_mean_NJf500: ", z_talkers_mean_NJf500)
# "Jitter_Final_1000" in Quiet
# population mean and standard deviation
population_QJf1000 = population_stats_dict(df_quiet_population, feature="Jitter_Final_1000")
# z-scores of all talkers' Target IPUs for this feature
z_QJf1000 = z_score_dict(df_quiet_target, feature="Jitter_Final_1000", population_stats=population_QJf1000)
# take the average between talkers, for the talkers' mean z-score for this feature
z_QJf1000_mean_list = [value['talker_zscore_mean'] for value in z_QJf1000.values()]
z_talkers_mean_QJf1000 = np.mean(z_QJf1000_mean_list)
print("z_talkers_mean_QJf1000:", z_talkers_mean_QJf1000)
# "Jitter_Final_1000" in Noise
# population mean and standard deviation
population_NJf1000 = population_stats_dict(df_noise_population, feature="Jitter_Final_1000")
# z-scores of all talkers' Target IPUs for this feature
z_NJf1000 = z_score_dict(df_noise_target, feature="Jitter_Final_1000", population_stats=population_NJf1000)
# take the average between talkers, for the talkers' mean z-score for this feature
z_NJf1000_mean_list = [value['talker_zscore_mean'] for value in z_NJf1000.values()]
z_talkers_mean_NJf1000 = np.mean(z_NJf1000_mean_list)
print("z_talkers_mean_NJf1000: ", z_talkers_mean_NJf1000)
###################################################################################################
# SHIMMER
###################################################################################################
# "Shimmer_Final_500" in Quiet
# population mean and standard deviation
population_QSf500 = population_stats_dict(df_quiet_population, feature="Shimmer_Final_500")
# z-scores of all talkers' Target IPUs for this feature
z_QSf500 = z_score_dict(df_quiet_target, feature="Shimmer_Final_500", population_stats=population_QSf500)
# take the average between talkers, for the talkers' mean z-score for this feature
z_QSf500_mean_list = [value['talker_zscore_mean'] for value in z_QSf500.values()]
z_talkers_mean_QSf500 = np.mean(z_QSf500_mean_list)
print("z_talkers_mean_QSf500:", z_talkers_mean_QSf500)
# "Shimmer_Final_500" in Noise
# population mean and standard deviation
population_NSf500 = population_stats_dict(df_noise_population, feature="Shimmer_Final_500")
# z-scores of all talkers' Target IPUs for this feature
z_NSf500 = z_score_dict(df_noise_target, feature="Shimmer_Final_500", population_stats=population_NSf500)
# take the average between talkers, for the talkers' mean z-score for this feature
z_NSf500_mean_list = [value['talker_zscore_mean'] for value in z_NSf500.values()]
z_talkers_mean_NSf500 = np.mean(z_NSf500_mean_list)
print("z_talkers_mean_NSf500:", z_talkers_mean_NSf500)
# "Shimmer_Final_1000" in Quiet
# population mean and standard deviation
population_QSf1000 = population_stats_dict(df_quiet_population, feature="Shimmer_Final_1000")
# z-scores of all talkers' Target IPUs for this feature
z_QSf1000 = z_score_dict(df_quiet_target, feature="Shimmer_Final_1000", population_stats=population_QSf1000)
# take the average between talkers, for the talkers' mean z-score for this feature
z_QSf1000_mean_list = [value['talker_zscore_mean'] for value in z_QSf1000.values()]
z_talkers_mean_QSf1000 = np.mean(z_QSf1000_mean_list)
print("z_talkers_mean_QSf1000:", z_talkers_mean_QSf1000)
# "Shimmer_Final_1000" in Noise
# population mean and standard deviation
population_NSf1000 = population_stats_dict(df_noise_population, feature="Shimmer_Final_1000")
# z-scores of all talkers' Target IPUs for this feature
z_NSf1000 = z_score_dict(df_noise_target, feature="Shimmer_Final_1000", population_stats=population_NSf1000)
# take the average between talkers, for the talkers' mean z-score for this feature
z_NSf1000_mean_list = [value['talker_zscore_mean'] for value in z_NSf1000.values()]
z_talkers_mean_NSf1000 = np.mean(z_NSf1000_mean_list)
print("z_talkers_mean_NSf1000:", z_talkers_mean_NSf1000)
###################################################################################################
# NHR
###################################################################################################
# "NHR_Final_500" in Quiet
# population mean and standard deviation
population_QNHRf500 = population_stats_dict(df_quiet_population, feature="NHR_Final_500")
# z-scores of all talkers' Target IPUs for this feature
z_QNHRf500 = z_score_dict(df_quiet_target, feature="NHR_Final_500", population_stats=population_QNHRf500)
# take the average between talkers, for the talkers' mean z-score for this feature
z_QNHRf500_mean_list = [value['talker_zscore_mean'] for value in z_QNHRf500.values()]
z_talkers_mean_QNHRf500 = np.mean(z_QNHRf500_mean_list)
print("z_talkers_mean_QNHRf500:", z_talkers_mean_QNHRf500)
# "NHR_Final_500" in Noise
# population mean and standard deviation
population_NNHRf500 = population_stats_dict(df_noise_population, feature="NHR_Final_500")
# z-scores of all talkers' Target IPUs for this feature
z_NNHRf500 = z_score_dict(df_noise_target, feature="NHR_Final_500", population_stats=population_NNHRf500)
# take the average between talkers, for the talkers' mean z-score for this feature
z_NNHRf500_mean_list = [value['talker_zscore_mean'] for value in z_NNHRf500.values()]
z_talkers_mean_NNHRf500 = np.mean(z_NNHRf500_mean_list)
print("z_talkers_mean_NNHRf500:", z_talkers_mean_NNHRf500)
# "NHR_Final_1000" in Quiet
# population mean and standard deviation
population_QNHRf1000 = population_stats_dict(df_quiet_population, feature="NHR_Final_1000")
# z-scores of all talkers' Target IPUs for this feature
z_QNHRf1000 = z_score_dict(df_quiet_target, feature="NHR_Final_1000", population_stats=population_QNHRf1000)
# take the average between talkers, for the talkers' mean z-score for this feature
z_QNHRf1000_mean_list = [value['talker_zscore_mean'] for value in z_QNHRf1000.values()]
z_talkers_mean_QNHRf1000 = np.mean(z_QNHRf1000_mean_list)
print("z_talkers_mean_QNHRf1000:", z_talkers_mean_QNHRf1000)
# "NHR_Final_1000" in Noise
# population mean and standard deviation
population_NNHRf1000 = population_stats_dict(df_noise_population, feature="NHR_Final_1000")
# z-scores of all talkers' Target IPUs for this feature
z_NNHRf1000 = z_score_dict(df_noise_target, feature="NHR_Final_1000", population_stats=population_NNHRf1000)
# take the average between talkers, for the talkers' mean z-score for this feature
z_NNHRf1000_mean_list = [value['talker_zscore_mean'] for value in z_NNHRf1000.values()]
z_talkers_mean_NNHRf1000 = np.mean(z_NNHRf1000_mean_list)
print("z_talkers_mean_NNHRf1000:", z_talkers_mean_NNHRf1000)
###################################################################################################
# ONE-WAY ANOVA
###################################################################################################
# One-way ANOVA on "Mean_Inten_Final_500" between Quiet and Noise
z_MIf500_fstatistic, z_MIf500_pvalue = scipy.stats.f_oneway(z_QMIf500_mean_list, z_NMIf500_mean_list, nan_policy='propagate')
print("z_MIf500_fstatistic: ", z_MIf500_fstatistic)
print("z_MIf500_pvalue: ", z_MIf500_pvalue)
# One-way ANOVA on "Mean_Inten_Final_1000" between Quiet and Noise
z_MIf1000_fstatistic, z_MIf1000_pvalue = scipy.stats.f_oneway(z_QMIf1000_mean_list, z_NMIf1000_mean_list, nan_policy='propagate')
print("z_MIf1000_fstatistic: ", z_MIf1000_fstatistic)
print("z_MIf1000_pvalue: ", z_MIf1000_pvalue)
print()
# One-way ANOVA on "Mean_Pitch_Final_500" between Quiet and Noise
z_MPf500_fstatistic, z_MPf500_pvalue = scipy.stats.f_oneway(z_QMPf500_mean_list, z_NMPf500_mean_list, nan_policy='propagate')
print("z_MPf500_fstatistic: ", z_MPf500_fstatistic)
print("z_MPf500_pvalue: ", z_MPf500_pvalue)
# One-way ANOVA on "Mean_Pitch_Final_1000" between Quiet and Noise
z_MPf1000_fstatistic, z_MPf1000_pvalue = scipy.stats.f_oneway(z_QMPf1000_mean_list, z_NMPf1000_mean_list, nan_policy='propagate')
print("z_MPf1000_fstatistic: ", z_MPf1000_fstatistic)
print("z_MPf1000_pvalue: ", z_MPf1000_pvalue)
print()
# One-way ANOVA on "Jitter_Final_500" between Quiet and Noise
z_Jf500_fstatistic, z_Jf500_pvalue = scipy.stats.f_oneway(z_QJf500_mean_list, z_NJf500_mean_list, nan_policy='propagate')
print("z_Jf500_fstatistic: ", z_Jf500_fstatistic)
print("z_Jf500_pvalue: ", z_Jf500_pvalue)
# One-way ANOVA on "Jitter_Final_1000" between Quiet and Noise
z_Jf1000_fstatistic, z_Jf1000_pvalue = scipy.stats.f_oneway(z_QJf1000_mean_list, z_NJf1000_mean_list, nan_policy='propagate')
print("z_Jf1000_fstatistic: ", z_Jf1000_fstatistic)
print("z_Jf1000_pvalue: ", z_Jf1000_pvalue)
print()
# One-way ANOVA on "Shimmer_Final_500" between Quiet and Noise
z_Sf500_fstatistic, z_Sf500_pvalue = scipy.stats.f_oneway(z_QSf500_mean_list, z_NSf500_mean_list, nan_policy='propagate')
print("z_Sf500_fstatistic: ", z_Sf500_fstatistic)
print("z_Sf500_pvalue: ", z_Sf500_pvalue)
# One-way ANOVA on "Shimmer_Final_1000" between Quiet and Noise
z_Sf1000_fstatistic, z_Sf1000_pvalue = scipy.stats.f_oneway(z_QSf1000_mean_list, z_NSf1000_mean_list, nan_policy='propagate')
print("z_Sf1000_fstatistic: ", z_Sf1000_fstatistic)
print("z_Sf1000_pvalue: ", z_Sf1000_pvalue)
print()
# One-way ANOVA on "NHR_Final_500" between Quiet and Noise
z_NHRf500_fstatistic, z_NHRf500_pvalue = scipy.stats.f_oneway(z_QNHRf500_mean_list, z_NNHRf500_mean_list, nan_policy='propagate')
print("z_NHRf500_fstatistic: ", z_NHRf500_fstatistic)
print("z_NHRf500_pvalue: ", z_NHRf500_pvalue)
# One-way ANOVA on "NHR_Final_1000" between Quiet and Noise
z_NHRf1000_fstatistic, z_NHRf1000_pvalue = scipy.stats.f_oneway(z_QNHRf1000_mean_list, z_NNHRf1000_mean_list, nan_policy='propagate')
print("z_NHRf1000_fstatistic: ", z_NHRf1000_fstatistic)
print("z_NHRf1000_pvalue: ", z_NHRf1000_pvalue)
print()
###################################################################################################
# ALEXANDER-GOVERN FOR HETEROGENOUS VARIANCE, I.E. DOES NOT ASSUME HOMOSCEDASTICITY
###################################################################################################
print("\nAlexander-Govern...\n")
# Alexander-Govern on "Mean_Inten_Final_500" between Quiet and Noise
z_MIf500_res = scipy.stats.alexandergovern(z_QMIf500_mean_list, z_NMIf500_mean_list, nan_policy='propagate')
print("z_MIf1000_fstatistic: ", z_MIf500_res.statistic)
print("z_MIf1000_pvalue: ", z_MIf500_res.pvalue)
# Alexander-Govern on "Mean_Inten_Final_1000" between Quiet and Noise
z_MIf1000_res = scipy.stats.alexandergovern(z_QMIf1000_mean_list, z_NMIf1000_mean_list, nan_policy='propagate')
print("z_MIf500_fstatistic: ", z_MIf1000_res.statistic)
print("z_MIf500_pvalue: ", z_MIf1000_res.pvalue)
print()
# Alexander-Govern on "Mean_Pitch_Final_500" between Quiet and Noise
z_MPf500_res = scipy.stats.alexandergovern(z_QMPf500_mean_list, z_NMPf500_mean_list, nan_policy='propagate')
print("z_MPf500_fstatistic: ", z_MPf500_res.statistic)
print("z_MPf500_pvalue: ", z_MPf500_res.pvalue)
# Alexander-Govern on "Mean_Pitch_Final_1000" between Quiet and Noise
z_MPf1000_res = scipy.stats.alexandergovern(z_QMPf1000_mean_list, z_NMPf1000_mean_list, nan_policy='propagate')
print("z_MPf1000_fstatistic: ", z_MPf1000_res.statistic)
print("z_MPf1000_pvalue: ", z_MPf1000_res.pvalue)
print()
# Alexander-Govern on "Jitter_Final_500" between Quiet and Noise
z_Jf500_res = scipy.stats.alexandergovern(z_QJf500_mean_list, z_NJf500_mean_list, nan_policy='propagate')
print("z_Jf500_fstatistic: ", z_Jf500_res.statistic)
print("z_Jf500_pvalue: ", z_Jf500_res.pvalue)
# Alexander-Govern on "Jitter_Final_1000" between Quiet and Noise
z_Jf1000_res = scipy.stats.alexandergovern(z_QJf1000_mean_list, z_NJf1000_mean_list, nan_policy='propagate')
print("z_Jf1000_fstatistic: ", z_Jf1000_res.statistic)
print("z_Jf1000_pvalue: ", z_Jf1000_res.pvalue)
print()
# Alexander-Govern on "Shimmer_Final_500" between Quiet and Noise
z_Sf500_res = scipy.stats.alexandergovern(z_QSf500_mean_list, z_NSf500_mean_list, nan_policy='propagate')
print("z_Sf500_fstatistic: ", z_Sf500_res.statistic)
print("z_Sf500_pvalue: ", z_Sf500_res.pvalue)
# Alexander-Govern on "Shimmer_Final_1000" between Quiet and Noise
z_Sf1000_res = scipy.stats.alexandergovern(z_QSf1000_mean_list, z_NSf1000_mean_list, nan_policy='propagate')
print("z_Sf1000_fstatistic: ", z_Sf1000_res.statistic)
print("z_Sf1000_pvalue: ", z_Sf1000_res.pvalue)
print()
# Alexander-Govern on "NHR_Final_500" between Quiet and Noise
z_NHRf500_res = scipy.stats.alexandergovern(z_QNHRf500_mean_list, z_NNHRf500_mean_list, nan_policy='propagate')
print("z_NHRf500_fstatistic: ", z_NHRf500_res.statistic)
print("z_NHRf500_pvalue: ", z_NHRf500_res.pvalue)
# Alexander-Govern on "NHR_Final_1000" between Quiet and Noise
z_NHRf1000_res = scipy.stats.alexandergovern(z_QNHRf1000_mean_list, z_NNHRf1000_mean_list, nan_policy='propagate')
print("z_NHRf1000_fstatistic: ", z_NHRf1000_res.statistic)
print("z_NHRf1000_pvalue: ", z_NHRf1000_res.pvalue)