@@ -155,21 +155,43 @@ const percentiles = Object.entries(SparkMinerRsrSummaries).flatMap(
155
155
${ Plot .plot ({
156
156
title: ' # of Filecoin SPs with a non-zero Spark Retrieval Success Rate' ,
157
157
x: { label: null },
158
- y: { grid: true , label: null },
158
+ y: { grid: true , label: ' # Non-Zero SPs ' },
159
159
color: { legend: true },
160
160
marks: [
161
161
Plot .ruleY ([0 ]),
162
- Plot .line (nonZeroMinersOverTime, {
162
+ Plot .lineY (nonZeroMinersOverTime, {
163
163
x: ' day' ,
164
164
y: ' count_succes_rate' ,
165
165
stroke: " type" ,
166
166
curve: ' catmull-rom' ,
167
+ tip: {
168
+ format: {
169
+ x : d => new Date (d).toLocaleDateString (' en-US' , {
170
+ year: ' numeric' ,
171
+ month: ' short' ,
172
+ day: ' numeric'
173
+ }),
174
+ y : v => ` ${ v} SPs` ,
175
+ type: true
176
+ }
177
+ }
167
178
}),
168
- Plot .line (nonZeroMinersOverTime, {
179
+ Plot .lineY (nonZeroMinersOverTime, {
169
180
x: ' day' ,
170
181
y: ' count_succes_rate_http' ,
171
182
stroke: " type" ,
172
183
curve: ' catmull-rom' ,
184
+ tip: {
185
+ format: {
186
+ x : d => new Date (d).toLocaleDateString (' en-US' , {
187
+ year: ' numeric' ,
188
+ month: ' short' ,
189
+ day: ' numeric'
190
+ }),
191
+ y : v => v ? ` ${ v} SPs` : ' N/A' ,
192
+ type: true
193
+ }
194
+ }
173
195
})
174
196
]
175
197
})}
@@ -178,7 +200,7 @@ const percentiles = Object.entries(SparkMinerRsrSummaries).flatMap(
178
200
${ Plot .plot ({
179
201
title: ' # of Filecoin SPs with Spark Retrieval Success Rate above x%' ,
180
202
x: { label: null },
181
- y: { grid: true , label: null },
203
+ y: { grid: true , label: ' # SPs above x% ' },
182
204
color: {
183
205
scheme: " Paired" ,
184
206
legend: " swatches"
@@ -189,7 +211,18 @@ const percentiles = Object.entries(SparkMinerRsrSummaries).flatMap(
189
211
x: ' day' ,
190
212
y: ' count_succes_rate' ,
191
213
stroke: ' label' ,
192
- curve: ' catmull-rom'
214
+ curve: ' catmull-rom' ,
215
+ tip: {
216
+ format: {
217
+ x : d => new Date (d).toLocaleDateString (' en-US' , {
218
+ year: ' numeric' ,
219
+ month: ' short' ,
220
+ day: ' numeric'
221
+ }),
222
+ y : v => ` ${ v} SPs` ,
223
+ label: true
224
+ }
225
+ }
193
226
})
194
227
]
195
228
})}
@@ -275,7 +308,7 @@ const tidy = clone(SparkRetrievalResultCodes).flatMap(({ day, rates }) => {
275
308
color: {
276
309
scheme: " Accent" ,
277
310
legend: " swatches" ,
278
- label: " Codes "
311
+ label: " code "
279
312
},
280
313
marks: [
281
314
Plot .rectY (tidy, {
@@ -284,7 +317,18 @@ const tidy = clone(SparkRetrievalResultCodes).flatMap(({ day, rates }) => {
284
317
fill: " code" ,
285
318
offset: " normalize" ,
286
319
sort: {color: null , x: " -y" },
287
- interval: ' day'
320
+ interval: ' day' ,
321
+ tip: {
322
+ format: {
323
+ x : d => new Date (d).toLocaleDateString (' en-US' , {
324
+ year: ' numeric' ,
325
+ month: ' short' ,
326
+ day: ' numeric'
327
+ }),
328
+ y : v => v .toFixed (2 ),
329
+ code: true
330
+ }
331
+ }
288
332
})
289
333
]
290
334
})}
@@ -297,12 +341,22 @@ const tidy = clone(SparkRetrievalResultCodes).flatMap(({ day, rates }) => {
297
341
${ Plot .plot ({
298
342
title: ' Time to First Byte (ms)' ,
299
343
x: { type: ' utc' , ticks: ' month' },
300
- y: { grid: true , zero: true },
344
+ y: { grid: true , zero: true , label : ' ttfb (ms) ' },
301
345
marks: [
302
346
Plot .lineY (SparkRetrievalTimes, {
303
347
x: ' day' ,
304
348
y: ' ttfb_ms' ,
305
349
stroke: " #FFBD3F" ,
350
+ tip: {
351
+ format: {
352
+ x : d => new Date (d).toLocaleDateString (' en-US' , {
353
+ year: ' numeric' ,
354
+ month: ' short' ,
355
+ day: ' numeric'
356
+ }),
357
+ y : v => v .toFixed (0 )
358
+ }
359
+ }
306
360
})
307
361
]
308
362
})}
0 commit comments