I'd like to know how to make histogram with matlab raw data file.

조회 수: 6 (최근 30일)
HYUK BIN KWON
HYUK BIN KWON 2022년 11월 21일
답변: William Rose 2022년 11월 21일
I'd like to know how to make histogram with matlab raw data file.
this is my raw data file.
I have 10,000 raw data file and i'd like to make a histogram with this data.
I tried //histogram(my_file.raw)// but it doesn't work. the error message is my data is complx, instead function need real data.
to sum it up,
I'd like to know how to import my raw data to my matlab variable and how to make a histogram with my complex raw data.
Thank you very much.

답변 (1개)

William Rose
William Rose 2022년 11월 21일
I recommend that you read the help for load and for importdata, and try the examples provided.
histogram(x) does not work with complex x. A histogram of complex data would be a 3D plot.
You can do
histogram(real(x))
histogram(imag(x))
histogram(abs(x));
There are functions to make a histogram of complex data, in the Matlab File Exchange, such as this package.
Good luck.

카테고리

Help CenterFile Exchange에서 Histograms에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by