Lines Matching refs:pl

277 	struct plot *pl;
279 pl = &plot;
280 pl->width = width;
281 pl->height = 0;
282 pl->data = NULL;
283 pl->bar = NULL;
284 pl->separate_bars = separate;
285 pl->num_datasets = num_datasets;
286 pl->min = 999e99;
287 pl->max = -999e99;
293 struct plot *pl;
295 pl = &plot;
296 if (a < pl->min)
297 pl->min = a;
298 if (a > pl->max)
299 pl->max = a;
300 pl->span = pl->max - pl->min;
301 pl->dx = pl->span / (pl->width - 1.0);
302 pl->x0 = pl->min - .5 * pl->dx;
317 struct plot *pl;
322 pl = &plot;
323 if (pl->span == 0)
326 if (pl->separate_bars)
331 if (pl->bar == NULL) {
332 pl->bar = malloc(sizeof(char *) * pl->num_datasets);
333 memset(pl->bar, 0, sizeof(char*) * pl->num_datasets);
335 if (pl->bar[bar] == NULL) {
336 pl->bar[bar] = malloc(pl->width);
337 memset(pl->bar[bar], 0, pl->width);
344 x = (ds->points[n] - pl->x0) / pl->dx;
355 if (m > pl->height) {
356 pl->data = realloc(pl->data, pl->width * m);
357 memset(pl->data + pl->height * pl->width, 0,
358 (m - pl->height) * pl->width);
360 pl->height = m;
363 x = (ds->points[n] - pl->x0) / pl->dx;
370 pl->data[j * pl->width + x] |= val;
373 x = ((Avg(ds) - Stddev(ds)) - pl->x0) / pl->dx;
374 m = ((Avg(ds) + Stddev(ds)) - pl->x0) / pl->dx;
375 pl->bar[bar][m] = '|';
376 pl->bar[bar][x] = '|';
378 if (pl->bar[bar][i] == 0)
379 pl->bar[bar][i] = '_';
381 x = (Median(ds) - pl->x0) / pl->dx;
382 pl->bar[bar][x] = 'M';
383 x = (Avg(ds) - pl->x0) / pl->dx;
384 pl->bar[bar][x] = 'A';
390 struct plot *pl;
393 pl = &plot;
394 if (pl->span == 0) {
400 for (i = 0; i < pl->width; i++)
404 for (i = 1; i < pl->height; i++) {
406 for (j = 0; j < pl->width; j++) {
407 k = pl->data[(pl->height - i) * pl->width + j];
416 for (i = 0; i < pl->num_datasets; i++) {
417 if (pl->bar[i] == NULL)
420 for (j = 0; j < pl->width; j++) {
421 k = pl->bar[i][j];
430 for (i = 0; i < pl->width; i++)