Description Usage Arguments Details Value Examples

This function can be used in order to construct a 3D histogram based on 3 variables and relative breaks directly provided as inputs.

1 2 3 4 5 6 7 8 9 10 11 |

`x` |
either a numerical vector to be partitioned or a matrix with 3 numerical columns to be partitioned. |

`y` |
a numerical vector to be partitioned. Not required if x is a matrix. |

`z` |
a numerical vector to be partitioned. Not required if x is a matrix |

`breaks_x` |
a numerical vector. Contains the breaks related to x for the histogram |

`breaks_y` |
a numerical vector. Contains the breaks related to y for the histogram |

`breaks_z` |
a numerical vector. Contains the breaks related to z for the histogram |

`same.scale` |
logical. Default to FALSE. If TRUE, breaks_x will be used for x, y and z |

`na.rm` |
logical. Default to TRUE. Indicates whether missing values should be removed |

`FUN` |
function used to summarize bin contents. |

The default function used for the argument FUN is the function length. When another function is used, it is applied on x or on the first column of x if this is a three-column matrix. The lower limit of each class interval is included in the class and the upper limit is not.

Using a given set of breaks per each variable, the function returns :

- Hist.Values
a 3 dimensional array. The 1st (respectively 2nd, 3rd) dimension is related to the class intervals of x (resp. y, z). Contingency table is returned if FUN=length

- breaks_x, breaks_y, breaks_z
same as the inputs of the function

- Midpoints.x, Midpoints.y, Midpoints.z
the midpoints for each bin per variable

- nobs.x , nobs.y, nobs.z
number of observations of x, y and z

- n.bins
vector of 3 elements containing the number of bins for x, y and z

1 2 3 4 5 6 7 |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.