converting string data to numbers

hi there, I've separated the oxygen data set from a matrix of other data sets (measurements)
i used
rmmissing(Oxygen)
to remove the blanks and now need to convert the string to integers. Is the following correct?
Oxygen= Measurements(:,1);
%removing the extra <missing> strings
Oxygen=rmmissing(Oxygen);
%Data converted to integers
Oxygen = cellfun(@str2num, Oxygen,'UniformOutput',false)
also, how do i determine the frequency of measurements for Oxygen for measurements that are taken over a 24-hour time period?
Thanks

답변 (1개)

Subhamoy Saha
Subhamoy Saha 2020년 3월 21일
편집: Subhamoy Saha 2020년 3월 21일

0 개 추천

Oxygen = cellfun(@str2num, Oxygen, 'UniformOutput',false)

카테고리

도움말 센터File Exchange에서 Data Type Conversion에 대해 자세히 알아보기

제품

릴리스

R2019b

태그

질문:

2020년 3월 21일

편집:

2020년 3월 21일

Community Treasure Hunt

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

Start Hunting!

Translated by