plotting graph and mark points

조회 수: 6 (최근 30일)
Silpa K
Silpa K 2019년 9월 15일
댓글: Walter Roberson 2021년 2월 22일
Hi, I have a set A that contain 200 points and a subset of the set B.I need to graph the A and I need to mark the points in the set B in A.I can't mark those points correctly.Please help me.
  댓글 수: 3
dpb
dpb 2019년 9월 15일
Answer moved to Comment...dpb
I use a ucr time series data set.I extract some points based on a condition.The extracted points I need to mark in the original set.I use the plot function.
dpb
dpb 2019년 9월 15일
I don't know what "ucr" means, not do you say a thing useful to help us know what, specifically you have done nor what "a condition" is...POST CODE and DATA, not just words....

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

채택된 답변

Walter Roberson
Walter Roberson 2019년 9월 16일
d = xlsread('FaceFour_TRAIN.xlsx');
plot(d);
hold on
idx = find(d>0.04);
pointsize = 20;
scatter(idx, d(idx), pointsize, 'b', '*')
hold off
  댓글 수: 15
Walter Roberson
Walter Roberson 2019년 9월 18일
s = d(1:1,2:end);
fa = movstd(s,20,1);
secarray = movstd(fa,20,1) ;
secidx = find(secarray>.04);
f = secarray(secidx);
[maxvals, maxidx] = maxk(f,10);
sidx = secidx(maxidx);
x = 1:length(s);
plot(x, s, 'b-', sidx, s(sidx), 'go')
Silpa K
Silpa K 2019년 9월 18일
thank you very much sir.

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

추가 답변 (2개)

Silpa K
Silpa K 2019년 9월 16일
d = xlsread('FaceFour_TRAIN.xlsx')
f=d(d>.04);
plot(d)
I need to mark the f in d and the d I need to represent like a single plot.How it possible please help me.

inusah alhassan
inusah alhassan 2021년 2월 21일
s = d(1:1,2:end);
fa = movstd(s,20,1);
secarray = movstd(fa,20,1) ;
secidx = find(secarray>.04);
f = secarray(secidx);
[maxvals, maxidx] = maxk(f,10);
sidx = secidx(maxidx);
x = 1:length(s);
plot(x, s, 'b-', sidx, s(sidx), 'go')
  댓글 수: 1
Walter Roberson
Walter Roberson 2021년 2월 22일
This does not appear to be an answer to the user's question?

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

태그

Community Treasure Hunt

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

Start Hunting!

Translated by