Create a graph from .mat file

Hello!
Need some help figuring out what i need to search in order to:
I wish to make a simple 2d graph from a .mat file i got from picoscope(a software for eletrical signals).
This file loads into matlab the following info:
What a want to do is:
The A variable is my Y axis and Instead of using those 490450 Y values i wish to only use a portion of them? ex: 10 000
The code i have so far is:
B= (sqrt(A.^2));
c = linspace(0,10,490450);
figure(1)
plot(c,B)
ylim([-1,1]);
I realize this is potentially a really simple issue however an answer would really speed up my reasearch and understanding
Thank you!

回答 (1 件)

José Capitão
José Capitão 2021 年 9 月 17 日

0 投票

Think i got it!
Code:
B= (sqrt(A.^2));
j= 400000 --> number of Y´s
D= B(1:j,:);
c = linspace(0,Tinterval*j,j);
figure(1)
plot(c,D)
ylim([-1,1]);

カテゴリ

ヘルプ センター および File ExchangeLarge Files and Big Data についてさらに検索

製品

リリース

R2021a

質問済み:

2021 年 9 月 17 日

回答済み:

2021 年 9 月 17 日

Community Treasure Hunt

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

Start Hunting!

Translated by