how to extract data in the structure to individual vector variable?

1 回表示 (過去 30 日間)
sivalogan satchithanandamoorthy
sivalogan satchithanandamoorthy 2016 年 2 月 18 日
コメント済み: Jonathan Duncan 2017 年 10 月 6 日
i have 1x1 data obtained from time vs signal graph. i want to separate time and signal and assign them into different varable.
  2 件のコメント
Walter Roberson
Walter Roberson 2016 年 2 月 18 日
Which routine did you call to obtain your data?
sivalogan satchithanandamoorthy
sivalogan satchithanandamoorthy 2016 年 2 月 18 日
i don't know how to approach the problem

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

回答 (1 件)

Moe_2015
Moe_2015 2016 年 2 月 18 日
編集済み: Moe_2015 2016 年 2 月 18 日
This should be pretty straight forward. You can do this:
%Assuming a structure name of Structure
Time=Structure.time;
Signal=Structure.signal;
EDIT: I realized that this might be some data you're getting from simulink as a structure with time from the way you phrased it. So it would be something like this:
Time=simout.time;
Signal=simout.signals.values;
  3 件のコメント
Moe_2015
Moe_2015 2016 年 2 月 18 日
編集済み: Moe_2015 2016 年 2 月 18 日
You are welcome. If this helped you with your problem please accept the answer for the benefit of others.
Jonathan Duncan
Jonathan Duncan 2017 年 10 月 6 日
if you wanted to extract more than 1 value how would you do that ?

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

カテゴリ

Help Center および File ExchangeDescriptive Statistics についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by