Info
Diese Frage ist geschlossen. Öffnen Sie sie erneut, um sie zu bearbeiten oder zu beantworten.
How to find Y value that corresponds to the maximum X value in these graphs?
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Hi,
I need to find the Y value that corresponds to the maximum X value for the curves attached herewith.
I tried to use interp1, but I am not sure how to make it for several files.
Can anyone please help me with this?
Thank you.
Antworten (1)
KSSV
am 19 Feb. 2019
files = dir('*.txt') ;
N = length(files) ;
iwant = zeros(N,2) ;
for i = 1:N
data = load(files(i).name) ;
[val,idx] = max(data(:,1)) ;
iwant(i,:) = [val data(idx,2)] ;
end
8 Kommentare
KSSV
am 19 Feb. 2019
Okay.....try this https://in.mathworks.com/matlabcentral/fileexchange/10959-sort_nat-natural-order-sort to read the file sin order.
Diese Frage ist geschlossen.
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!