how to convert the mutiple colum into single colum using colon :

조회 수: 1 (최근 30일)
MONICA RAWAT
MONICA RAWAT 2020년 1월 28일
댓글: MONICA RAWAT 2020년 2월 23일
the table given above is the three column represent hour minute second in separate column i want to combine into single column separated by colon(:) given below format
output:
0:0:0.0180
0:0:0.0380
0:0:0.0580
0:0:0.0780
0:0:0.0980
0:0:0.1180
0:0:0.1380
0:0:0.1580
0:0:0.1780

채택된 답변

Walter Roberson
Walter Roberson 2020년 1월 28일
duration(YourData(:,4), YourData(:,5), YourData(:,6), 'format', 'hh:mm:ss.SSSS')
  댓글 수: 8
Walter Roberson
Walter Roberson 2020년 2월 22일
IST_Duration = UTC_Duration + hours(5) + minutes(30)
However, it makes no sense to do so. Durations are for elapsed time relative to some starting point. TimeZone corrections only make sense relative to a date. If you have a date as well as a time of day then you would put everything together using datetime() instead of duration(). At the time you use datetime() you would use the option 'TimeZone', 'UTC' . Then once you had the resulting datetime object, you would set the TimeZone property of it to 'Asia/Calcutta' .
MONICA RAWAT
MONICA RAWAT 2020년 2월 23일
got it walter thank you so much for clearing out my doubt

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

추가 답변 (1개)

Selva Karna
Selva Karna 2020년 1월 28일
clc
clear all;
close all;
data=your_data;
con_singl_col=data(:);

카테고리

Help CenterFile Exchange에서 Dates and Time에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by