How can I round numbers from a column?

조회 수: 3 (최근 30일)
Cristian Martin
Cristian Martin 2020년 6월 14일
댓글: Cristian Martin 2020년 6월 14일
Hi,
I have:
load('work.mat');
C = T(:,2);%read second column
C{:, 1} = regexprep(C{:, 1}, '[(ms)]', '');%eliminate text after numbers
X = round(C)
How do I round the numbers after I delete the text ?
____________________________________________________
Undefined function 'round' for input arguments of type 'table'.
Error in Runscript (line 8)
X = round(C)

채택된 답변

madhan ravi
madhan ravi 2020년 6월 14일
편집: madhan ravi 2020년 6월 14일
  댓글 수: 10
madhan ravi
madhan ravi 2020년 6월 14일
Cristian Martin
Cristian Martin 2020년 6월 14일
Thank You Ravi !

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Data Type Conversion에 대해 자세히 알아보기

태그

제품


릴리스

R2016a

Community Treasure Hunt

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

Start Hunting!

Translated by