How do I make a 3D histogram for my data set?

14 vues (au cours des 30 derniers jours)
Garrett Shirley
Garrett Shirley le 29 Juin 2020
Hello, the dataset I am working with is a matrix where the contents of each row is 500 samples from a lab instrument and each row differs by the other by having the samples measured with one parameter within the instrument changed. What I am able to do now is to make histograms of each individual row so I can see the distribution of readings for a single value of the mentioned parameter. What I would like is a 3D plot where the x axis is the readings from the instrument, the y axis is the range of values of that parameter, and the z axis is the frequency of a given reading at a given parameter value. Is this possible in MATLAB or any other piece of software? Hopefully this makes sense, I can clarify anything if needed or provide the dataset as well.
  1 commentaire
darova
darova le 30 Juin 2020
Can you attach the data? What about hist3?

Connectez-vous pour commenter.

Réponses (1)

Pratheek Punchathody
Pratheek Punchathody le 22 Oct 2020
“hist3()” is a function in which the user should need a 2D Matrix in which 1st column is x value, and 2nd column is y value. Then the function plots number of occurrences of the pairs x, y as the z parameter.
By looking at the information you have provided regarding the data, you can consider
  • x axis is the readings from the instrument,
  • y axis is the range of values of that parameter and
  • In your case function will plot the frequency of the given reading as the Z axis.
Refer to the documentation on hist3() for further details.

Produits


Version

R2020a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by