Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
KDATA_STDDEV_ALLOC(3)	    Library Functions Manual	 KDATA_STDDEV_ALLOC(3)

NAME
       kdata_stddev_alloc -- allocate standard deviation data for plotting

LIBRARY
       library "libkplot"

SYNOPSIS
       #include	<cairo.h>
       #include	<kplot.h>

       struct kdata *
       kdata_stddev_alloc(struct kdata *source);

DESCRIPTION
       The  kdata_stddev_alloc	creates	 a  reference-counted data sources for
       kplot(3).  It attaches to zero or more existing data sources and,  when
       they  update their values, tracks the standard deviation	(via the unbi-
       ased sample variance) of	sequence of updated values.

       It attaches to zero or more existing data sources and, when they	update
       their values per-index, tracks the standard deviation (via the unbiased
       sample variance)	of the sequence	of updated values.  Thus, if  a	 stan-
       dard  deviation data source is attached to two sources, its y-value for
       pair zero will reflect the standard deviation from the mean of all val-
       ues set to pair zero's y-value in the sources.  Note that the  indexing
       is  absolute:  if  attached  to	a bucket or histogram, pair index zero
       refers to the first internal data storage, not storage mapped from  the
       bucket or histogram.

       If  source  is not NULL,	the internal buffer is initialised to the size
       of the source and all of	its x values.  The standard deviation is  ini-
       tialised	 to zero with zero updates.  Otherwise,	the internal buffer is
       sized to	zero.

       Further data sources may	be attached with kdata_stddev_attach(3).

RETURN VALUES
       kdata_stddev_alloc returns NULL if memory allocation failed.

SEE ALSO
       kdata_stddev_attach(3), kplot(3)

       Donald  E.  Knuth,  The	Art  of	 Computer  Programming:	 Seminumerical
       Algorithms, 3rd Edition,	Addison-Wesley,	Volume 2, 232, Boston, 1998.

CAVEATS
       Each standard deviation bucket can process a maximum number of SIZE_MAX
       updates.

FreeBSD	ports 15.quarterly     January 22, 2015		 KDATA_STDDEV_ALLOC(3)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=kdata_stddev_alloc&sektion=3&manpath=FreeBSD+Ports+15.0.quarterly>

home | help