unable to read time stamps from a csv file, unable to read the csv file in matlab

8 ビュー (過去 30 日間)
Hai all,
This is with regards to the csv data which i gathered from the raspberry pie. The notepad file which consists of 2500 rows and 8 columns, is difficult to be read in excel as well as in matlab due to some reasons,
  1. the file consists of timestamps (eg: 2020-02-05 15:21:51.659353) in this format which is(DD-MM-YYY HH:MM:SS:FF). once i convert this to excel file, the microseconds are trimmed or neglected giving me only HH:MM:SS(resulting in incorrect result when plotting).Since the microseconds are really vital in finding the sampling rate, using excel to read the csv data is turning out to be less useful.
  2. i alternatively tried reading the csv data in matlab wth the command 'readtable' which was found to be useful (read all the data including the time stamps), but unfortunately, i was unable to carryout other commands since it is not an array function. i even tried to convert the file using 'table2array' but turned out to show errors.
  3. i have tried the lab2mat function to convert the file to .tom function which also lead to errors.
I request any of you who are expert in matlab to solve this issue for me as it is urgent for my thesis work and i am stuck in the middle. i am attaching my acquired csv data alonw with the message. please go through.
  1 件のコメント
Shebin Rasheed
Shebin Rasheed 2020 年 8 月 10 日
my project is basically a motion measurement in a 2D narrow wave tank. the scale model which is a floating ball valve were the accelerometer is clamped to the valve to read its heave motion. The scale model is clamped to a T shaped wooden frame for stability. the x-direction of the accelerometer reads the heave motion which is obtained through the raspberry pi. This data is saved in the form of a csv file. what the aim is to plot the data for acceleration vs time, acceleration vs frequency as well as velocity vs time and displacement vs time. This graph is then compared with the graph obtained by using a filter especially kalman filter (i have got no idea how a kalman filter can be applied in this). I am not that expert in matlab, just a beginner, please, if someone could sort this out, i would really be grateful, please guide me thorugh.

サインインしてコメントする。

採用された回答

Cris LaPierre
Cris LaPierre 2020 年 8 月 4 日
編集済み: Cris LaPierre 2020 年 8 月 4 日
If you got it working with readtable, use that. You just need to learn how to access the data in a table. For that, see this documentation page.
  13 件のコメント
Cris LaPierre
Cris LaPierre 2020 年 8 月 13 日
It would be better to start a new question focused just on implementing the kalman filter.
Shebin Rasheed
Shebin Rasheed 2020 年 8 月 13 日
sure. as you say.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeTime Series Events についてさらに検索

製品


リリース

R2014a

Community Treasure Hunt

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

Start Hunting!

Translated by