Last modified: 12 December 2018

The lines are too thin (or thick); how can I change them?

Lines - whether they are drawn connecting points of a curve, the bins of a histogram, or the axes of a plot - have a thickness attribute, which controls how thick the lines are drawn. The attribute can take a value between 0.5 and 10, although the difference between 0.5 and 1 is only discernable in the vector output formats (i.e. postscript and PDF).

To make the line of a curve thicker than its default value (which is 1) you would say:

set_curve(["line.thickness", 2])

To change the axes of the current plot to use a thickness of 2 you would say either:

  1. From CIAO 4.2 onwards you can take advantage of the support for attribute names of the form "*.name":

    set_axis(["*.thickness", 2])

    Attributes called "*.name" act to change all entries for that object with that name; in this case we use it to change the thickness elements.

  2. Prior to CIAO 4.2 you had to say the following; it is still valid and can be useful for changing attributes of all elements of a plot, which can not be handled by the "*.name" syntax:

    set_cascading_property("all", chips_axis, "thickness", "2")

    The use of set_cascading_property() rather than set_axis() here is because there are multiple parts of an axis with a thickenss attribute, such as majortick.thickness and majorgrid.thickness. In this call the value has to be given as a string, hence the quotes around the value.


The ChIPS GUI makes it easy to modify a visualization using your mouse, rather than Python functions. The GUI can also be used to add annotations - such as labels, lines, points and regions - and to zoom or pan into plots.