20#ifndef jkqtpgraphsviolinplotstylingmixins_H
21#define jkqtpgraphsviolinplotstylingmixins_H
27#include "jkqtplotter/jkqtptools.h"
28#include "jkqtplotter/jkqtplotter_imexport.h"
29#include "jkqtplotter/jkqtplotter_configmacros.h"
30#include "jkqtplotter/jkqtpgraphsbase.h"
31#include "jkqtplotter/jkqtpgraphsbasestylingmixins.h"
44#ifndef JKQTPLOTTER_WORKAROUND_QGADGET_BUG
317 ViolinBottom=ViolinLeft,
319 ViolinTop=ViolinRight,
370 void plotVerticalViolinplot(
JKQTBasePlotter* parent,
JKQTPEnhancedPainter &painter,
double xp,
double xpleft,
double xpright,
const QVector<double> &violin_cat,
const QVector<double>& violin_freq,
double minp,
double medianp,
double maxp,
double meanp=
JKQTP_NAN)
const;
388 void plotHorizontalViolinplot(
JKQTBasePlotter* parent,
JKQTPEnhancedPainter &painter,
double yp,
double ypbottom,
double yptop,
const QVector<double>& violin_cat,
const QVector<double>& violin_freq,
double minp,
double medianp,
double maxp,
double meanp=
JKQTP_NAN)
const;
base class for 2D plotter classes (used by the plotter widget JKQTPlotter)
Definition jkqtpbaseplotter.h:394
this class extends the QPainter
Definition jkqtpenhancedpainter.h:33
This Mix-In class provides setter/getter methods, storage and other facilities for the graph filling ...
Definition jkqtpgraphsbasestylingmixins.h:529
This Mix-In class provides setter/getter methods, storage and other facilities for the graph line sty...
Definition jkqtpgraphsbasestylingmixins.h:49
Styling Mix-In for Violinplots.
Definition jkqtpviolinplotstylingmixins.h:43
JKQTPGraphSymbols m_meanSymbolType
which symbol to use for the datapoints
Definition jkqtpviolinplotstylingmixins.h:397
QPen getMedianPen(JKQTPEnhancedPainter &painter, JKQTBasePlotter *parent) const
build a pen to be used for drawing medians
void setWhiskerLineCapStyle(Qt::PenCapStyle style)
sets the cap style of whisker lines
QPen getMeanSymbolPen(JKQTPEnhancedPainter &painter, JKQTBasePlotter *parent) const
constructs a QPen from the line styling properties to draw the mean symbol
ViolinStyle
defines how to draw the violin graph
Definition jkqtpviolinplotstylingmixins.h:303
@ StepViolin
connect violin points by a steped line, but fully filled
Definition jkqtpviolinplotstylingmixins.h:305
@ SmoothViolin
connect all violin points by lines, resulting in a (nearly) smooth curve
Definition jkqtpviolinplotstylingmixins.h:304
@ BoxViolin
violin datapoints are drawn like a boxplot
Definition jkqtpviolinplotstylingmixins.h:306
double getMeanLineWidth() const
get the line width of the symbol for the mean outline, or mean line (in pt)
double whiskerLineWidth
line width (in pt) of the whisker lines
Definition jkqtpviolinplotstylingmixins.h:412
QBrush getMeanSymbolBrush(JKQTPEnhancedPainter &painter, JKQTBasePlotter *parent) const
constructs a QPen from the line styling properties
double relativeWhiskerWidth
width of the whiskers, relative to the box width (default: 0.5)
Definition jkqtpviolinplotstylingmixins.h:427
void setWhiskerLineWidth(double __value)
set the width [pt] of whisker lines
void setMeanLineDashOffset(qreal offset)
sets the dash offset for a custom dash style of Mean lines
QVector< qreal > getWhiskerCapLineDashPattern() const
gets the dash pattern for a custom dash style of whisker cap lines
ViolinPositionMode m_violinPositionMode
the position mode of the violin plot
Definition jkqtpviolinplotstylingmixins.h:433
void setWhiskerCapLineJoinStyle(Qt::PenJoinStyle style)
sets the join style of whisker cap lines
QPen getMeanLinePen(JKQTPEnhancedPainter &painter, JKQTBasePlotter *parent) const
constructs a QPen from the line styling properties to draw the mean line
void setViolinplotColor(QColor c, JKQTBasePlotter *parent)
set the color of the graph (colors all elements, based on the given color c )
QPen m_medianLinePen
line style of the median lines
Definition jkqtpviolinplotstylingmixins.h:418
void setWhiskerCapLineStyle(Qt::PenStyle __value)
set the line style of whisker cap lines
QPen getWhiskerCapPen(JKQTPEnhancedPainter &painter, JKQTBasePlotter *parent) const
build a pen to be used for drawing whisker caps
void setViolinStyle(ViolinStyle style)
set the style of the violin plot
QColor getMeanColor() const
set the color of the symbol for the mean, or mean line
JKQTPGraphViolinplotStyleMixin()
class constructor
QColor m_meanSymbolFillColor
color of the symbol filling
Definition jkqtpviolinplotstylingmixins.h:403
QColor getMedianLineColor() const
get the color of median lines
void setMeanSymbolFontName(const QString &__value)
set the font to be used for mean character symbols JKQTPCharacterSymbol+QChar('')....
void setViolinWidthAbsolute(double __value)
width of box in pt.
void setMeanColor(const QColor &__value)
set the color of the symbol for the mean, or mean line
void setMeanLineDashPattern(const QVector< qreal > &pattern)
sets the dash pattern for a custom dash style of Mean lines
QFont getMeanSymbolFont() const
generate a QFont for darwing symbols
QPen m_whiskerLinePen
line style of the whisker lines
Definition jkqtpviolinplotstylingmixins.h:410
void plotVerticalViolinplot(JKQTBasePlotter *parent, JKQTPEnhancedPainter &painter, double xp, double xpleft, double xpright, const QVector< double > &violin_cat, const QVector< double > &violin_freq, double minp, double medianp, double maxp, double meanp=JKQTP_NAN) const
draws a vertical boxplot, with all coordinates/sizes given in coordinates of the given painter,...
QColor getWhiskerLineColor() const
get the color of whisker lines
qreal getMedianLineDashOffset() const
returns the dash offset for a custom dash style of median lines
void setMedianLineColor(QColor __value)
set the color of median lines
void setMeanFillColor(const QColor &__value)
set the color of filling of the symbol for the mean
double getMedianLineWidth() const
get the width [pt] of median lines
QBrush getWhiskerLineBrush() const
gets the brush used to fill the line area of whisker lines
void setMedianLineDashOffset(qreal offset)
sets the dash offset for a custom dash style of median lines
QBrush getWhiskerCapLineBrush() const
gets the brush used to fill the line area of whisker cap lines
void setWhiskerLineColor(QColor __value)
set the color of whisker lines
qreal getWhiskerCapLineDashOffset() const
returns the dash offset for a custom dash style of whisker cap lines
void plotHorizontalKeyMarker(JKQTBasePlotter *parent, JKQTPEnhancedPainter &painter, const QRectF &rect) const
draw a small, stylized, horizontal symbol into rect that symbolizes a boxplot, e.g....
ViolinPositionMode
defines where to draw the violin graph with respect to the violin center position
Definition jkqtpviolinplotstylingmixins.h:315
@ ViolinRight
draw violin on the right hand side only (for vertical violins)
Definition jkqtpviolinplotstylingmixins.h:318
@ ViolinLeft
draw violin on the left hand side only (for vertical violins)
Definition jkqtpviolinplotstylingmixins.h:316
double getMeanSize() const
get the size (=diameter in pt) of the symbol for the mean (in pt)
QVector< qreal > getMedianLineDashPattern() const
gets the dash pattern for a custom dash style of median lines
void setMeanSymbolType(JKQTPGraphSymbols __value)
set the type of the symbol for the mean
QVector< qreal > getWhiskerLineDashPattern() const
gets the dash pattern for a custom dash style of whisker lines
void setWhiskerCapLineWidth(double __value)
set the width [pt] of whisker cap lines
QPen m_meanSymbolLinePen
outline color of the symbol or line pen of the mean-line
Definition jkqtpviolinplotstylingmixins.h:401
ViolinStyle getViolinStyle() const
returns the style of the violin plot
void setWhiskerCapLineDashOffset(qreal offset)
sets the dash offset for a custom dash style of whisker cap lines
void setMedianLineStyle(Qt::PenStyle __value)
set the line style of median lines
double m_meanSymbolLineWidth
width (in pt) of the lines used to plot the symbol for the data points, given in pt
Definition jkqtpviolinplotstylingmixins.h:405
double getRelativeWhiskerWidth() const
width of the whiskers, relative to the box width (default: 0.5)
QColor getWhiskerCapLineColor() const
get the color of whisker cap lines
void setWhiskerLineDashOffset(qreal offset)
sets the dash offset for a custom dash style of whisker lines
double getViolinWidthAbsolute() const
width of box in pt.
QBrush getMedianLineBrush() const
gets the brush used to fill the line area of median lines
void plotVerticalKeyMarker(JKQTBasePlotter *parent, JKQTPEnhancedPainter &painter, const QRectF &rect) const
draw a small, stylized, vertical symbol into rect that symbolizes a boxplot, e.g. in a plot legend
double whiskerCapLineWidth
line width (in pt) of the whisker cap lines
Definition jkqtpviolinplotstylingmixins.h:416
void setWhiskerLineDashPattern(const QVector< qreal > &pattern)
sets the dash pattern for a custom dash style of whisker lines
Qt::PenJoinStyle getMedianLineJoinStyle() const
returns the join style of median lines
double getWhiskerCapLineWidth() const
get the width [pt] of whisker cap lines
Qt::PenJoinStyle getWhiskerLineJoinStyle() const
returns the join style of whisker lines
Qt::PenJoinStyle getWhiskerCapLineJoinStyle() const
returns the join style of whisker cap lines
QColor getMeanFillColor() const
set the color of filling of the symbol for the mean
void setMeanLineWidth(double __value)
set the line width of the symbol for the mean outline, or mean line (in pt)
qreal getMeanLineDashOffset() const
returns the dash offset for a custom dash style of Mean lines
void setMedianLineCapStyle(Qt::PenCapStyle style)
sets the cap style of median lines
void setWhiskerLineBrush(const QBrush &style)
sets the brush used to fill the line area of whisker lines
double getWhiskerLineWidth() const
get the width [pt] of whisker lines
Qt::PenStyle getWhiskerLineStyle() const
get the line style of whisker lines
Qt::PenStyle getMedianLineStyle() const
get the line style of median lines
void setWhiskerCapLineDashPattern(const QVector< qreal > &pattern)
sets the dash pattern for a custom dash style of whisker cap lines
Qt::PenCapStyle getWhiskerLineCapStyle() const
gets the cap style of whisker lines
void setViolinplotColor(QColor c, QColor bc, JKQTBasePlotter *parent)
set the color of the graph (colors all elements, based on the given color c , sets background colors ...
JKQTPGraphSymbols getMeanSymbolType() const
get the type of the symbol for the mean
QString m_meanSymbolFontName
font to be used for character mean symbols JKQTPCharacterSymbol+QChar('').unicode()
Definition jkqtpviolinplotstylingmixins.h:407
void setMeanLineStyle(Qt::PenStyle __value)
set the line style of Mean lines
QVector< qreal > getMeanLineDashPattern() const
gets the dash pattern for a custom dash style of Mean lines
Qt::PenCapStyle getMedianLineCapStyle() const
gets the cap style of median lines
double m_meanSymbolSize
size (diameter in pt) of the symbol for the data points, given in pt
Definition jkqtpviolinplotstylingmixins.h:399
void setMedianLineWidth(double __value)
set the width [pt] of median lines
Qt::PenStyle getMeanLineStyle() const
get the line style of Mean lines
QPen m_whiskerCapLinePen
line style of the whisker cap lines
Definition jkqtpviolinplotstylingmixins.h:414
void setRelativeWhiskerWidth(double __value)
width of the whiskers, relative to the box width (default: 0.5)
Qt::PenCapStyle getWhiskerCapLineCapStyle() const
gets the cap style of whisker cap lines
double medianLineWidth
line width (in pt) of the median lines
Definition jkqtpviolinplotstylingmixins.h:420
void setWhiskerCapLineCapStyle(Qt::PenCapStyle style)
sets the cap style of whisker cap lines
Qt::PenStyle getWhiskerCapLineStyle() const
get the line style of whisker cap lines
void setMeanSize(double __value)
set the size (=diameter in pt) of the symbol for the mean (in pt)
qreal getWhiskerLineDashOffset() const
returns the dash offset for a custom dash style of whisker lines
QString getMeanSymbolFontName() const
get the font to be used for mean character symbols JKQTPCharacterSymbol+QChar('')....
void plotStyledMeanSymbol(JKQTBasePlotter *parent, JKQTPEnhancedPainter &painter, double x, double y) const
plot a symbol at location x,y (in painter coordinates), using the current style
ViolinStyle m_violinStyle
the style of the violin plot
Definition jkqtpviolinplotstylingmixins.h:430
void setMedianLineDashPattern(const QVector< qreal > &pattern)
sets the dash pattern for a custom dash style of median lines
void setViolinPositionMode(ViolinPositionMode positionMode)
set the position mode of the violin plot
void setWhiskerCapLineBrush(const QBrush &style)
sets the brush used to fill the line area of whisker cap lines
ViolinPositionMode getViolinPositionMode() const
returns the position mode of the violin plot
void plotHorizontalViolinplot(JKQTBasePlotter *parent, JKQTPEnhancedPainter &painter, double yp, double ypbottom, double yptop, const QVector< double > &violin_cat, const QVector< double > &violin_freq, double minp, double medianp, double maxp, double meanp=JKQTP_NAN) const
draws a horizontal boxplot, with all coordinates/sizes given in coordinates of the given painter,...
void setMedianLineBrush(const QBrush &style)
sets the brush used to fill the line area of median lines
double violinWidthAbsolute
width of box in pt.
Definition jkqtpviolinplotstylingmixins.h:425
QPen getWhiskerPen(JKQTPEnhancedPainter &painter, JKQTBasePlotter *parent) const
build a pen to be used for drawing whiskers
void setWhiskerLineStyle(Qt::PenStyle __value)
set the line style of whisker lines
void initViolinplotStyle(JKQTBasePlotter *parent, int &parentPlotStyle)
void setWhiskerCapLineColor(QColor __value)
set the color of whisker cap lines
void setWhiskerLineJoinStyle(Qt::PenJoinStyle style)
sets the join style of whisker lines
void setMedianLineJoinStyle(Qt::PenJoinStyle style)
sets the join style of median lines
#define JKQTPLOTTER_LIB_EXPORT
Definition jkqtplotter_imexport.h:89