ajhist.c

Datatypes: none AjPHist


Datatype: none

Histogram internals

Sections: modifiers


Section: modifiers

Controlling the internals

Functions: ajHistogramClose ajHistogramSetMark


Function ajHistogramClose

Closes the histograms window.

Synopsis

Prototype
void ajHistogramClose (
      void
);

TypeNameRead/WriteDescription
void RETURN

Returns
void:No return value

Description

Closes the histograms window.

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistogramSetMark

Set the histogram mark internal value

Synopsis

Prototype
void ajHistogramSetMark (
      ajint mark
);

TypeNameRead/WriteDescription
ajintmarkInputMark value
void RETURN

Input
mark:(Input)Mark value
Returns
void:No return value

Description

Set the histogram mark internal value

See Also

See other functions in this section

Availability

In release 6.4.0

Datatype: AjPHist

Histogram object

Sections: Constructors Destructors Display modifiers Histogram data management


Section: Constructors

Construct a new histogram object to be populated by other functions

Functions: ajHistNew ajHistNewG


Function ajHistNew

Create a histogram Object. Which can hold "numofsets" set of data of which all must have "numofpoints" data points in them.

Synopsis

Prototype
AjPHist ajHistNew (
      ajuint numofsets,
      ajuint numofpoints
);

TypeNameRead/WriteDescription
ajuintnumofsetsInputNumber of sets of data.
ajuintnumofpointsInputNumber of data points per set.
AjPHist RETURNhistogram structure.

Input
numofsets:(Input)Number of sets of data.
numofpoints:(Input)Number of data points per set.
Returns
AjPHist:histogram structure.

Description

Create a histogram Object. Which can hold "numofsets" set of data of which all must have "numofpoints" data points in them.

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistNewG

Create a histogram Object which has the histogram data and graph data storage capacity.

Synopsis

Prototype
AjPHist ajHistNewG (
      ajuint numofsets,
      ajuint numofpoints,
      AjPGraph graph
);

TypeNameRead/WriteDescription
ajuintnumofsetsInputNumber of sets of data.
ajuintnumofpointsInputNumber of data points per set.
AjPGraphgraphModifyGraph object, device, multi and name are set. The original AjPGraph object will be used by the AjPHist
AjPHist RETURNhistogram structure.

Input
numofsets:(Input)Number of sets of data.
numofpoints:(Input)Number of data points per set.
Input & Output
graph:(Modify)Graph object, device, multi and name are set. The original AjPGraph object will be used by the AjPHist
Returns
AjPHist:histogram structure.

Description

Create a histogram Object which has the histogram data and graph data storage capacity.

See Also

See other functions in this section

Availability

In release 6.4.0

Section: Destructors

Destructors for histogram objects

Functions: ajHistDel


Function ajHistDel

Delete and free all memory associated with the histogram. Does not delete the graph.

Synopsis

Prototype
void ajHistDel (
      AjPHist* phist
);

TypeNameRead/WriteDescription
AjPHist*phistDeleteHistogram to be deleted.
void RETURN

Output
phist:(Delete)Histogram to be deleted.
Returns
void:No return value

Description

Delete and free all memory associated with the histogram. Does not delete the graph.

See Also

See other functions in this section

Availability

In release 6.4.0

Section: Display

Functions to display or write the histogram

Functions: ajHistDisplay


Function ajHistDisplay

Display the histogram.

Synopsis

Prototype
void ajHistDisplay (
      const AjPHist thys
);

TypeNameRead/WriteDescription
const AjPHistthysInputHistogram Structure.
void RETURN

Input
thys:(Input)Histogram Structure.
Returns
void:No return value

Description

Display the histogram.

See Also

See other functions in this section

Availability

In release 6.4.0

Section: modifiers

Controlling the internals

Functions: ajHistSetMono ajHistSetRlabelC ajHistSetTitleC ajHistSetXlabelC ajHistSetYlabelC ajHistSetmultiColour ajHistSetmultiPattern ajHistSetmultiTitleC ajHistSetmultiTitleS ajHistSetmultiXlabelC ajHistSetmultiXlabelS ajHistSetmultiYlabelC ajHistSetmultiYlabelS


Function ajHistSetMono

Set patterns instead of colours for printing to B/W printers etc.

Synopsis

Prototype
void ajHistSetMono (
      AjPHist thys,
      AjBool set
);

TypeNameRead/WriteDescription
AjPHistthysModifyHistogram to have ptr set.
AjBoolsetInputSet to use patterns or colour for filling, false to reset to colour.
void RETURN

Input
set:(Input)Set to use patterns or colour for filling, false to reset to colour.
Input & Output
thys:(Modify)Histogram to have ptr set.
Returns
void:No return value

Description

Set patterns instead of colours for printing to B/W printers etc.

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistSetRlabelC

Store Y Axis Right Label for the histogram

Synopsis

Prototype
void ajHistSetRlabelC (
      AjPHist thys,
      const char* txt
);

TypeNameRead/WriteDescription
AjPHistthysModifyhistogram to set string in.
const char*txtInputtext to be copied.
void RETURN

Input
txt:(Input)text to be copied.
Input & Output
thys:(Modify)histogram to set string in.
Returns
void:No return value

Description

Store Y Axis Right Label for the histogram

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistSetTitleC

Copy Title for the histogram.

Synopsis

Prototype
void ajHistSetTitleC (
      AjPHist thys,
      const char* txt
);

TypeNameRead/WriteDescription
AjPHistthysModifyhistogram to set string in.
const char*txtInputtext to be copied.
void RETURN

Input
txt:(Input)text to be copied.
Input & Output
thys:(Modify)histogram to set string in.
Returns
void:No return value

Description

Copy Title for the histogram.

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistSetXlabelC

Store X axis label for the histogram

Synopsis

Prototype
void ajHistSetXlabelC (
      AjPHist thys,
      const char* txt
);

TypeNameRead/WriteDescription
AjPHistthysModifyhistogram to set string in.
const char*txtInputtext to be copied.
void RETURN

Input
txt:(Input)text to be copied.
Input & Output
thys:(Modify)histogram to set string in.
Returns
void:No return value

Description

Store X axis label for the histogram

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistSetYlabelC

Store Y Axis Left Label for the histogram

Synopsis

Prototype
void ajHistSetYlabelC (
      AjPHist thys,
      const char* txt
);

TypeNameRead/WriteDescription
AjPHistthysModifyhistogram to set string in.
const char*txtInputtext to be copied.
void RETURN

Input
txt:(Input)text to be copied.
Input & Output
thys:(Modify)histogram to set string in.
Returns
void:No return value

Description

Store Y Axis Left Label for the histogram

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistSetmultiColour

Set colour for bars in histogram for index'th set.

Synopsis

Prototype
void ajHistSetmultiColour (
      AjPHist thys,
      ajuint indexnum,
      ajint colour
);

TypeNameRead/WriteDescription
AjPHistthysModifyHistogram to have ptr set.
ajuintindexnumInputIndex for the set number.
ajintcolourInputColour for bar set.
void RETURN

Input
indexnum:(Input)Index for the set number.
colour:(Input)Colour for bar set.
Input & Output
thys:(Modify)Histogram to have ptr set.
Returns
void:No return value

Description

Set colour for bars in histogram for index'th set.

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistSetmultiPattern

Set colour for bars in histogram for one set.

Synopsis

Prototype
void ajHistSetmultiPattern (
      AjPHist thys,
      ajuint indexnum,
      ajint style
);

TypeNameRead/WriteDescription
AjPHistthysModifyHistogram to have ptr set.
ajuintindexnumInputIndex for the set number.
ajintstyleInputLine style number for bar set.
void RETURN

Input
indexnum:(Input)Index for the set number.
style:(Input)Line style number for bar set.
Input & Output
thys:(Modify)Histogram to have ptr set.
Returns
void:No return value

Description

Set colour for bars in histogram for one set.

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistSetmultiTitleC

Store title for the index'th set.

Synopsis

Prototype
void ajHistSetmultiTitleC (
      AjPHist thys,
      ajuint indexnum,
      const char* txt
);

TypeNameRead/WriteDescription
AjPHistthysModifyHistogram to have ptr set.
ajuintindexnumInputIndex for the set number.
const char*txtInputTitle.
void RETURN

Input
indexnum:(Input)Index for the set number.
txt:(Input)Title.
Input & Output
thys:(Modify)Histogram to have ptr set.
Returns
void:No return value

Description

Store title for the index'th set.

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistSetmultiTitleS

Set ptr for title for index'th set..

Synopsis

Prototype
void ajHistSetmultiTitleS (
      AjPHist thys,
      ajuint indexnum,
      const AjPStr str
);

TypeNameRead/WriteDescription
AjPHistthysModifyHistogram to have ptr set.
ajuintindexnumInputIndex for the set number.
const AjPStrstrInputTitle.
void RETURN

Input
indexnum:(Input)Index for the set number.
str:(Input)Title.
Input & Output
thys:(Modify)Histogram to have ptr set.
Returns
void:No return value

Description

Set ptr for title for index'th set..

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistSetmultiXlabelC

Store X axis title for the index'th set.

Synopsis

Prototype
void ajHistSetmultiXlabelC (
      AjPHist thys,
      ajuint indexnum,
      const char* txt
);

TypeNameRead/WriteDescription
AjPHistthysModifyHistogram to have ptr set.
ajuintindexnumInputIndex for the set number.
const char*txtInputx Title.
void RETURN

Input
indexnum:(Input)Index for the set number.
txt:(Input)x Title.
Input & Output
thys:(Modify)Histogram to have ptr set.
Returns
void:No return value

Description

Store X axis title for the index'th set.

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistSetmultiXlabelS

Set ptr for X axis title for index'th set..

Synopsis

Prototype
void ajHistSetmultiXlabelS (
      AjPHist thys,
      ajuint indexnum,
      const AjPStr str
);

TypeNameRead/WriteDescription
AjPHistthysModifyHistogram to have ptr set.
ajuintindexnumInputIndex for the set number.
const AjPStrstrInputx Title.
void RETURN

Input
indexnum:(Input)Index for the set number.
str:(Input)x Title.
Input & Output
thys:(Modify)Histogram to have ptr set.
Returns
void:No return value

Description

Set ptr for X axis title for index'th set..

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistSetmultiYlabelC

Store Y axis title for the index'th set.

Synopsis

Prototype
void ajHistSetmultiYlabelC (
      AjPHist thys,
      ajuint indexnum,
      const char* txt
);

TypeNameRead/WriteDescription
AjPHistthysModifyHistogram to have ptr set.
ajuintindexnumInputIndex for the set number.
const char*txtInputY Title.
void RETURN

Input
indexnum:(Input)Index for the set number.
txt:(Input)Y Title.
Input & Output
thys:(Modify)Histogram to have ptr set.
Returns
void:No return value

Description

Store Y axis title for the index'th set.

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistSetmultiYlabelS

Set ptr for Y axis title for index'th set..

Synopsis

Prototype
void ajHistSetmultiYlabelS (
      AjPHist thys,
      ajuint indexnum,
      const AjPStr str
);

TypeNameRead/WriteDescription
AjPHistthysModifyHistogram to have ptr set.
ajuintindexnumInputIndex for the set number.
const AjPStrstrInputY Title.
void RETURN

Input
indexnum:(Input)Index for the set number.
str:(Input)Y Title.
Input & Output
thys:(Modify)Histogram to have ptr set.
Returns
void:No return value

Description

Set ptr for Y axis title for index'th set..

See Also

See other functions in this section

Availability

In release 6.4.0

Section: Histogram data management

Functions to manage the data values associated with a histogram object

Functions: ajHistDataAdd ajHistDataCopy


Function ajHistDataAdd

Set internal pointer to data for a set of data points for one set.

Synopsis

Prototype
void ajHistDataAdd (
      AjPHist thys,
      ajuint indexnum,
      PLFLT* data
);

TypeNameRead/WriteDescription
AjPHistthysModifyHistogram to have ptr set.
ajuintindexnumInputIndex for the set number.
PLFLT*dataModifyData values to be owned by the histogram object
void RETURN

Input
indexnum:(Input)Index for the set number.
Input & Output
thys:(Modify)Histogram to have ptr set.
data:(Modify)Data values to be owned by the histogram object
Returns
void:No return value

Description

Set internal pointer to data for a set of data points for one set.

See Also

See other functions in this section

Availability

In release 6.4.0

Function ajHistDataCopy

Copy data from data array to histogram for one set.

Synopsis

Prototype
void ajHistDataCopy (
      AjPHist thys,
      ajuint indexnum,
      PLFLT const* srcdata
);

TypeNameRead/WriteDescription
AjPHistthysModifyHistogram to have ptr set.
ajuintindexnumInputIndex for the set number.
PLFLT const*srcdataInputData to be copied
void RETURN

Input
indexnum:(Input)Index for the set number.
srcdata:(Input)Data to be copied
Input & Output
thys:(Modify)Histogram to have ptr set.
Returns
void:No return value

Description

Copy data from data array to histogram for one set.

See Also

See other functions in this section

Availability

In release 6.4.0