Importing histogram count and bin values into a matlab histogram object
Mostrar comentarios más antiguos
Hello,
I have a two vectors that describe a histogram.
I'd like to import those into a Matlab histogram object so that I can change parameters more easily.
For instance, this is basically what I have:
Center bin values:
BinValues = [-4 -3 -2 -1 0 1 2 3 4 ];
and count values per bin
CountValues = [7 8 2 6 0 3 4 6 1];
This is simplified of course, but in the future I might want to do something like reduce the number of bins from 9 to 5.
How do I create a matlab histogram object given what I have?
1 comentario
Tom Mozdzen
el 22 de Dic. de 2020
Respuesta aceptada
Más respuestas (1)
Steven Lord
el 23 de Dic. de 2020
0 votos
I'm analyzing timestamps from a single photon detector. I populate the bins as I go. In 1 second of data collection, I have nearly 25 million timestamps. My file is huge as it runs for about an hour. So I'd have around 20x10^9 items in my data file if I saved each data point. )-:
That sounds like it could be Big Data. Can you store the data as a tall array backed by a datastore array, perhaps a tabularTextDatastore or a spreadsheetDatastore? You can create a histogram using that tall array. See this documentation page for more information.
1 comentario
Tom Mozdzen
el 23 de Dic. de 2020
Categorías
Más información sobre Histograms en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!


