Can I remove outlier lines from a large plot?
Mostra commenti meno recenti
Thank you in advance for any help you're able to give me.
I'm currently working with a large data set of battery ageing from Nasa and I've been able to pull the data out of the structure and plot it. However looking at the plots I can see some lines that are clearly wrong.
I was wondering if it would be possible to remove these lines from the plot, or alternatively filter them out from the cell array I create to hold them all (myData). I’ve been looking at outlier removal methods or de-noising but I can’t seem to find a way that would remove entire lines from the plot. I think my code may be written in a somewhat roundabout way so please let me know if there’s anything I can do to change it.
load('C:\Users\Harry\Documents\4th Year\Diss Work\Data\BatteryAgingARC-FY08Q4\B0005.mat');
L = length(B0005.cycle);
for i = 1:L
type = {B0005.cycle.type}.';
s1 = 'charge';
s2 = 'discharge';
C = strcmp(type, s1);
D = strcmp(type, s2);
hold on;
if C(i,:) == 1
figure(1);
title('Charge');
myData(:, i) = {B0005.cycle(i).data.Time}.';
myData(:, i+1) = {B0005.cycle(i).data.Voltage_measured}.';
cellfun(@plot,myData(:,i),myData(:, i+1));
i = i+1;
end
end
The file for the dataset is quite large so I can't attach it, but it's contained here, under Dataset 5, 'Download Battery Data Set 1'.
Thank you again.
1 Commento
Jesus Sanchez
il 21 Nov 2019
When speaking about "wrong lines", which ones do you mean?
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Labels and Annotations in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!



