-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathExampleData_PAPO
More file actions
187 lines (161 loc) · 13.3 KB
/
ExampleData_PAPO
File metadata and controls
187 lines (161 loc) · 13.3 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
n_medios = 65
n_segmentos = 16
P = [
[0.0135, 0.0036, 0.0048, 0.0161, 0.006, 0.0119, 0.0611, 0.0049, 0.0209, 0.001, 0.0029, 0.0045, 0.0092, 0.0011, 0.0066, 0.0143, 0.0018, 0.0063, 0.0297, 0.0086, 0.0949, 0.0424, 0.0679, 0.049, 0.0046, 0.0146, 0.0127, 0.0031, 0.0056, 0.0128, 0.0056, 0.0098, 0.0012, 0.0029, 0.0047, 0.0019, 0.0059, 0.0009, 0.0034, 0.0016, 0.0035, 0.0017, 0.0004, 0.0006, 0.0007, 0.0048, 0.0392, 0.0159, 0.0435, 0.0036, 0.016, 0.0074, 0.0211, 0.0014, 0.007, 0.0035, 0.0076, 0.0001, 0.0005, 0.001, 0.003, 0.0003, 0.0003, 0.0005, 0.0008], #Hombres 14-19
[0.0349, 0.0105, 0.0144, 0.0334, 0.0011, 0.002, 0.0475, 0.0332, 0.0717, 0.0084, 0.003, 0.0052, 0.0023, 0.0012, 0.0061, 0.0154, 0.0019, 0.0072, 0.0095, 0.0029, 0.0876, 0.0368, 0.0084, 0.0105, 0.0064, 0.019, 0.0117, 0.0011, 0.0135, 0.0082, 0.0042, 0.0143, 0.0009, 0.0035, 0.0059, 0.0024, 0.0028, 0.0005, 0.0043, 0.0019, 0.0031, 0.0023, 0.0004, 0.0008, 0.0008, 0.0056, 0.0571, 0.0264, 0.0577, 0.0018, 0.0115, 0.006, 0.0156, 0.0008, 0.0065, 0.006, 0.0058, 0.0019, 0.0042, 0.0077, 0.0082, 0.0018, 0.0005, 0.0022, 0.0022], #Mujer 14-19
[0.0186, 0.0048, 0.0074, 0.0208, 0.0085, 0.0193, 0.0592, 0.0101, 0.0274, 0.0018, 0.0047, 0.006, 0.0117, 0.0022, 0.0105, 0.017, 0.0023, 0.0111, 0.0293, 0.0096, 0.1015, 0.0557, 0.0796, 0.0484, 0.0046, 0.0232, 0.015, 0.003, 0.0099, 0.0196, 0.007, 0.0113, 0.0015, 0.0027, 0.0037, 0.0023, 0.0069, 0.0008, 0.0033, 0.0018, 0.0039, 0.002, 0.0005, 0.0008, 0.0008, 0.0059, 0.0399, 0.0161, 0.0415, 0.0039, 0.015, 0.0075, 0.0211, 0.0021, 0.0073, 0.0045, 0.0085, 0.0001, 0.0008, 0.0008, 0.0025, 0.0003, 0.0002, 0.0004, 0.0003], #Hombre 20-24
[0.0441, 0.0147, 0.0174, 0.0483, 0.0029, 0.0032, 0.0421, 0.0379, 0.07, 0.0142, 0.0054, 0.0041, 0.0022, 0.0025, 0.0078, 0.0146, 0.0016, 0.009, 0.0087, 0.0023, 0.0965, 0.0534, 0.0104, 0.009, 0.0036, 0.0228, 0.0153, 0.0011, 0.0102, 0.0123, 0.0058, 0.014, 0.0013, 0.0049, 0.0065, 0.0017, 0.0026, 0.0003, 0.0047, 0.0024, 0.0029, 0.0024, 0.0005, 0.0005, 0.0008, 0.0074, 0.0546, 0.0287, 0.0565, 0.0023, 0.011, 0.0068, 0.0151, 0.001, 0.0066, 0.0054, 0.0059, 0.0018, 0.0043, 0.0065, 0.0083, 0.0009, 0.0002, 0.0017, 0.0014], #Mujer 20-24
[0.0116, 0.0031, 0.0045, 0.0176, 0.0073, 0.0175, 0.0416, 0.0051, 0.012, 0.0027, 0.0066, 0.0063, 0.0168, 0.0029, 0.0123, 0.0149, 0.0026, 0.0097, 0.0359, 0.0087, 0.1176, 0.0559, 0.1055, 0.0565, 0.0059, 0.0163, 0.0191, 0.0036, 0.0079, 0.0192, 0.0095, 0.0112, 0.0016, 0.0035, 0.0036, 0.0028, 0.0084, 0.0018, 0.0041, 0.002, 0.0042, 0.0022, 0.0004, 0.0011, 0.0011, 0.0045, 0.0384, 0.0158, 0.0442, 0.0042, 0.0161, 0.0073, 0.0232, 0.0016, 0.0057, 0.0027, 0.007, 0.0001, 0.0005, 0.0009, 0.0024, 0.0005, 0.0003, 0.0004, 0.0004], #Hombre 25-34
[0.0345, 0.0129, 0.0166, 0.0384, 0.0033, 0.0043, 0.0313, 0.0292, 0.0432, 0.0091, 0.0073, 0.0053, 0.0061, 0.0015, 0.0085, 0.014, 0.0018, 0.0083, 0.0102, 0.0032, 0.1043, 0.061, 0.0116, 0.0122, 0.0049, 0.0175, 0.0103, 0.0026, 0.0078, 0.0146, 0.0064, 0.0136, 0.0016, 0.0057, 0.0065, 0.002, 0.0036, 0.0003, 0.0047, 0.0023, 0.0033, 0.0028, 0.0005, 0.0007, 0.0009, 0.0066, 0.05, 0.0263, 0.0604, 0.0023, 0.0107, 0.0056, 0.0171, 0.0008, 0.0045, 0.0038, 0.0058, 0.0013, 0.003, 0.0065, 0.0103, 0.0006, 0.0004, 0.0016, 0.0017], #Mujer 25-34
[0.0102, 0.0044, 0.0058, 0.0191, 0.0124, 0.0133, 0.0381, 0.0052, 0.0082, 0.0021, 0.0082, 0.0075, 0.0176, 0.0018, 0.013, 0.0191, 0.0035, 0.0111, 0.0399, 0.0112, 0.1426, 0.0639, 0.1096, 0.0639, 0.0104, 0.0163, 0.0208, 0.0085, 0.0075, 0.0186, 0.0123, 0.01, 0.0025, 0.0045, 0.0052, 0.0052, 0.0137, 0.0026, 0.0037, 0.0026, 0.0051, 0.0029, 0.0005, 0.0008, 0.0009, 0.0051, 0.045, 0.0187, 0.0558, 0.0048, 0.0177, 0.0088, 0.0302, 0.0012, 0.005, 0.0029, 0.0069, 0.0001, 0.0006, 0.0013, 0.0032, 0.0004, 0.0004, 0.0008, 0.0007], #Hombres 35-44
[0.0374, 0.0154, 0.0185, 0.0488, 0.0043, 0.0026, 0.0258, 0.0221, 0.0246, 0.009, 0.0071, 0.0052, 0.0031, 0.0018, 0.008, 0.0148, 0.003, 0.0071, 0.0078, 0.0024, 0.1044, 0.0484, 0.0088, 0.0063, 0.0046, 0.0156, 0.0113, 0.0017, 0.0082, 0.0118, 0.0087, 0.0124, 0.0022, 0.0063, 0.0083, 0.0029, 0.0049, 0.0005, 0.004, 0.0029, 0.0039, 0.0033, 0.0005, 0.0012, 0.0013, 0.0068, 0.0488, 0.031, 0.0709, 0.0026, 0.0107, 0.0067, 0.0204, 0.0007, 0.0035, 0.0027, 0.0036, 0.0012, 0.0024, 0.0066, 0.0102, 0.0008, 0.0006, 0.0019, 0.0013], #Mujeres 35-44
[0.0123, 0.0054, 0.0063, 0.026, 0.007, 0.0079, 0.0414, 0.0058, 0.0068, 0.0015, 0.0085, 0.0112, 0.0141, 0.0015, 0.0172, 0.0216, 0.0042, 0.0105, 0.0338, 0.0099, 0.1384, 0.0573, 0.0875, 0.0467, 0.0175, 0.0153, 0.0196, 0.0116, 0.0063, 0.0188, 0.0163, 0.0075, 0.0039, 0.0052, 0.0054, 0.0093, 0.0179, 0.0022, 0.0024, 0.004, 0.0061, 0.0041, 0.0007, 0.0015, 0.0014, 0.0053, 0.048, 0.0265, 0.067, 0.0055, 0.0217, 0.0114, 0.0334, 0.0008, 0.0036, 0.0035, 0.0063, 0.0001, 0.0007, 0.0019, 0.004, 0.0002, 0.0002, 0.0005, 0.0006], #Hombres 45-54
[0.0454, 0.0175, 0.0212, 0.0571, 0.003, 0.0017, 0.0243, 0.0182, 0.0177, 0.012, 0.0088, 0.0075, 0.0023, 0.0011, 0.0095, 0.0169, 0.0026, 0.0086, 0.007, 0.0023, 0.0963, 0.0529, 0.0068, 0.004, 0.0082, 0.0167, 0.01, 0.0017, 0.0054, 0.0129, 0.0117, 0.0093, 0.0027, 0.0066, 0.0077, 0.0062, 0.0091, 0.0003, 0.0027, 0.0044, 0.0054, 0.0053, 0.0006, 0.0016, 0.0018, 0.008, 0.0602, 0.0459, 0.0872, 0.0027, 0.0139, 0.0093, 0.0257, 0.0006, 0.0031, 0.0032, 0.004, 0.0017, 0.0031, 0.0095, 0.0141, 0.0006, 0.0004, 0.001, 0.001], #Mujeres 45-54
[0.0131, 0.0076, 0.0088, 0.0274, 0.0046, 0.0046, 0.0399, 0.0039, 0.0055, 0.0026, 0.0082, 0.0151, 0.0169, 0.0016, 0.0218, 0.0304, 0.0049, 0.0122, 0.0361, 0.0115, 0.1309, 0.0476, 0.0805, 0.0341, 0.0152, 0.0139, 0.0197, 0.0114, 0.0057, 0.016, 0.0193, 0.005, 0.0026, 0.0046, 0.0037, 0.0084, 0.0169, 0.0011, 0.0018, 0.0036, 0.0068, 0.0054, 0.0009, 0.0022, 0.0015, 0.007, 0.0644, 0.033, 0.0798, 0.0068, 0.0271, 0.0142, 0.0364, 0.0011, 0.0041, 0.0035, 0.0056, 0.0002, 0.0009, 0.0026, 0.0045, 0.0003, 0.0001, 0.0003, 0.0004], #Hombres 55-64
[0.0419, 0.017, 0.0205, 0.0644, 0.0023, 0.0016, 0.0205, 0.012, 0.0165, 0.0107, 0.0074, 0.0067, 0.003, 0.0011, 0.0095, 0.019, 0.0031, 0.0112, 0.007, 0.0027, 0.0861, 0.0414, 0.0051, 0.0025, 0.0077, 0.0137, 0.0065, 0.0014, 0.0043, 0.0113, 0.0177, 0.005, 0.0015, 0.0053, 0.0045, 0.0064, 0.0103, 0.0002, 0.0013, 0.0034, 0.0069, 0.0069, 0.0009, 0.0022, 0.0018, 0.0092, 0.0767, 0.0612, 0.1017, 0.0034, 0.018, 0.0119, 0.0291, 0.0005, 0.0032, 0.0033, 0.0041, 0.0017, 0.0043, 0.0132, 0.0173, 0.0003, 0.0003, 0.0008, 0.0007], #Mujeres 55-64
[0.0124, 0.0078, 0.0076, 0.0326, 0.0029, 0.002, 0.0283, 0.0023, 0.0029, 0.0014, 0.009, 0.0141, 0.0171, 0.0012, 0.0168, 0.0313, 0.005, 0.0133, 0.0293, 0.0095, 0.1066, 0.0388, 0.056, 0.0264, 0.011, 0.0094, 0.0108, 0.0067, 0.0029, 0.0104, 0.0219, 0.0026, 0.0013, 0.0029, 0.0021, 0.0077, 0.0169, 0.0008, 0.0008, 0.0018, 0.0072, 0.0067, 0.001, 0.0031, 0.0017, 0.0081, 0.078, 0.0439, 0.0856, 0.0083, 0.0326, 0.0175, 0.0387, 0.0007, 0.0035, 0.0032, 0.0048, 0.0002, 0.001, 0.0029, 0.005, 0.0002, 0.0001, 0.0004, 0.0004], #Hombres 65-74
[0.0365, 0.0146, 0.02, 0.0794, 0.0008, 0.0008, 0.0145, 0.0058, 0.0086, 0.0058, 0.0056, 0.0096, 0.0024, 0.0003, 0.0089, 0.0159, 0.0031, 0.009, 0.0061, 0.0023, 0.0499, 0.0275, 0.0032, 0.0013, 0.0033, 0.0077, 0.0024, 0.001, 0.0019, 0.0072, 0.018, 0.0021, 0.0005, 0.0032, 0.0018, 0.0054, 0.0118, 0.0002, 0.0005, 0.0013, 0.0082, 0.0078, 0.0012, 0.0031, 0.0023, 0.0112, 0.0929, 0.0761, 0.108, 0.0036, 0.0204, 0.0145, 0.0305, 0.0007, 0.0036, 0.0033, 0.0037, 0.002, 0.006, 0.016, 0.0198, 0.0003, 0.0005, 0.001, 0.0006], #Mujeres 65-74
[0.0111, 0.0066, 0.0078, 0.0458, 0.0014, 0.0009, 0.0135, 0.0009, 0.0022, 0.0014, 0.0045, 0.0205, 0.0109, 0.0005, 0.0116, 0.0189, 0.0037, 0.0105, 0.0236, 0.0098, 0.0446, 0.0152, 0.0235, 0.0113, 0.0041, 0.0047, 0.004, 0.0025, 0.0014, 0.0044, 0.0136, 0.0011, 0.0004, 0.0016, 0.0012, 0.0043, 0.0154, 0.0005, 0.0004, 0.0006, 0.0074, 0.0082, 0.0014, 0.0044, 0.0013, 0.0096, 0.0889, 0.055, 0.0905, 0.0097, 0.037, 0.0212, 0.039, 0.0007, 0.0037, 0.0029, 0.0042, 0.0002, 0.0012, 0.0031, 0.0043, 0.0002, 0.0001, 0.0002, 0.0002], #Hombres 75+
[0.0387, 0.0173, 0.021, 0.0956, 0.0005, 0.0002, 0.0061, 0.0038, 0.0066, 0.0056, 0.0041, 0.0082, 0.0019, 0.0001, 0.0057, 0.0091, 0.0023, 0.0088, 0.0048, 0.0027, 0.0244, 0.0134, 0.0011, 0.0017, 0.0015, 0.0036, 0.0007, 0, 0.0008, 0.0026, 0.012, 0.0011, 0.0002, 0.0016, 0.0009, 0.0038, 0.0114, 0.0001, 0.0003, 0.0004, 0.0089, 0.0075, 0.0013, 0.0037, 0.0021, 0.0132, 0.1132, 0.0863, 0.11, 0.004, 0.0217, 0.0152, 0.0303, 0.0005, 0.0024, 0.0023, 0.0024, 0.0019, 0.0058, 0.016, 0.0172, 0.0005, 0.0002, 0.0008, 0.0004], #Mujeres 75+
]
c = [20125, 10745, 11725, 18430, 5775, 10500, 19050, 16625, 19900, 19850, #Costes Revistas
37875, 23811, 15350, 7200, 37200, 46775, 16680, 27500, 28100, 8225, #Costes Periodicos
37000, 25000, 37000, 25000, 5940, 16800, 25000, 18000, 3300, 6720, #Costes Webs
8500, 4616, 2292, 3711, 4086, 6823, 7645, 1082, 3251, 3091, #Costes Radio
4183, 3091, 454, 1226, 502, #Costes TV Regional
1833, 10150, 8000, 19143, 1290, 3500, 3100, 11000, 1250, 2100, 2000, 3600, 192, 1100, 1625, 2814, 560, 1050, 1195, 1870] #Costes TV Nacional (Franjas ordenadas)
#IGUAL HAY QUE CAMBIAR ESTO; MIRAR LAS 'inc'
t_jovenes = ['ind',
['ind',
['ind',
[31],[33],[34],['inc',[28],[38]]], #Música Pop
['exc',
[32],[39],[30],[36],[37],['inc',[24],[35]]], #NO Música Pop
], #Radio
['ind',
['exc',
[0],[1],[2],[3]], #Prensa Rosa
['ind',
[4],[5]], #Deportes y Fitness
[6], #Ciencia
['exc',
[7],[8],[9]]#Moda
], #Revistas
['ind',
[10], #Gratis
['exc',
[11],[14],[16],['inc',[15],[20]],['inc',[17],[21]]], #Actualidad
['exc',
[18],['inc',[12],[22]],['inc',[19],[23]]], #Deportes
['exc',
[27],['inc',[13],[26]]] #Economia
], #Periodico
['ind',
['exc',
[40],[41],[42],[43],[44]], #Autonómicas
['ind',
['exc',
['exc',[45],[49],[53],[57],[61]], #Mañana
['exc',[47],[51],[55],[59],[63]] #Tarde
],#Estudio
['exc', [46],[50],[54],[58],[62]], #Mediodía
['exc', ['inc',[25],[48]],['inc',[29],[52]],[56],[60],[64]] #Noche
]#Nacionales
] #TV
]
t_adultos = ['ind',
['ind',
['exc',
['exc',[31],[33],[34],['inc',[28],[38]]],#Música Pop
['exc',[32],[39]]#Música AC
], #Música
['exc',[30],[36],['inc',[24],[35]]],#Actualidad
[37]#Deporte
], #Radio
['ind',
['ind',
[0],[1],[2],[3]], #Prensa Rosa
['ind',
[4],[5]], #Deportes y Fitness
[6], #Ciencia
['ind',
[7],[8],[9]]#Moda
], #Revistas
['ind',
[10], #Gratis
['exc',
[11],[14],[16],['inc',[15],[20]],['inc',[17],[21]]], #Actualidad
['exc',
[18],['inc',[12],[22]],['inc',[19],[23]]], #Deportes
['exc',
[27],['inc',[13],[26]]] #Economia
], #Periodico
['ind',
['exc',
[40],[41],[42],[43],[44]], #Autonómicas
['ind',
['exc',
['exc',[45],[49],[53],[57],[61]], #Mañana
['exc',[47],[51],[55],[59],[63]] #Tarde
],#Trabajo
['exc', [46],[50],[54],[58],[62]], #Mediodía
['exc', ['inc',[25],[48]],['inc',[29],[52]],[56],[60],[64]] #Noche
]#Nacionales
] #TV
]
t_mayores = ['ind',
['ind',
['exc',
['exc',[31],[33],[34],['inc',[28],[38]]],#Música Pop
['exc',[32],[39]]#Música AC
], #Música
['exc',[30],[36],['inc',[24],[35]]],#Actualidad
[37]#Deporte
], #Radio
['ind',
['ind',
[0],[1],[2],[3]], #Prensa Rosa
['exc',
[4],[5]], #Deportes y Fitness
[6], #Ciencia
['exc',
[7],[8],[9]]#Moda
], #Revistas
['ind',
[10], #Gratis
['exc',
[11],[14],[16],['inc',[20],[15]],['inc',[21],[17]]], #Actualidad
['exc',
[18],['inc',[22],[12]],['inc',[23],[19]]], #Deportes
['exc',
[27],['inc',[26],[13]]] #Economia
], #Periodico
['ind',
['exc',
[40],[41],[42],[43],[44]], #Autonómicas
['ind',
['exc',[45],[49],[53],[57],[61]], #Mañana
['exc',[47],[51],[55],[59],[63]], #Tarde
['exc', [46],[50],[54],[58],[62]], #Mediodía
['exc', ['inc',[25],[48]],['inc',[29],[52]],[56],[60],[64]] #Noche
]#Nacionales
] #TV
]
t = [t_jovenes, t_jovenes, t_jovenes, t_jovenes, t_adultos, t_adultos, t_adultos, t_adultos, t_adultos, t_adultos, t_adultos, t_adultos, t_mayores, t_mayores, t_mayores, t_mayores]
#minimo de probabilidades que queremos conseguir en los diferentes segmentos de poblacion
mP = [0, #Hasta 0.5110382013983552 -> Hombres 14-19
0, #Hasta 0.5276064210482563 -> Mujeres 14-19
0, #Hasta 0.5524180857804493 -> Hombres 20-24
0, #Hasta 0.5632145398746187 -> Mujeres 20-24
0.05, #Hasta 0.5644620699317076 -> Hombres 25-34
0.05, #Hasta 0.5344877590698043 -> Mujeres 25-34
0.15, #Hasta 0.6138773218025437 -> Hombres 35-44
0.15, #Hasta 0.5267184180722825 -> Mujeres 35-44
0.25, #Hasta 0.612072634674912 -> Hombres 45-54
0.25, #Hasta 0.5655431454793736 -> Mujeres 45-54
0.35, #Hasta 0.6190851088405438 -> Hombres 55-64
0.35, #Hasta 0.5772683122568937 -> Mujeres 55-64
0.45, #Hasta 0.5006430315169351 -> Hombres 65-74
0.45, #Hasta 0.5369083201478808 -> Mujeres 65-74
0.45, #Hasta 0.48902087201371636 -> Hombres 75+
0.45] #Hasta 0.5434646699260789 -> Mujeres 75+