Hi All, How to solve this Error .........."Error using horzcat Dimensions of matrices being concatenated are not consistent."

1 visualización (últimos 30 días)
I'm trying to do a boxplot from a structure data, each cell of the structure have different size row. I want to draw 26 boxplots in the same figure using the structure data. My code is the following:
for k=1:col boxplot(dataPBL.Smooth{:,k}) end
But does not work, help me, please. Thank you.
  2 comentarios
Jonnathan  Cespedes
Jonnathan Cespedes el 19 de Oct. de 2018
Editada: Guillaume el 19 de Oct. de 2018
clear; close all; clc;
[FileName,DirName] = uigetfile('*.*','Select the PBL Files','MultiSelect','on');
M = zeros(size(FileName));
for k=length(FileName):-1:1
fid = fopen(FileName{k},'r');
[filepath, Name, ext] = fileparts(FileName{k});
Name = strcat(Name,ext);
dataPBL.FileName{:,k} = FileName{:,k};
dataPBL.Ptop{:,k} = dlmread(fullfile(DirName,FileName{:,k}));
% [dataPBL.Envelope{1,k}, dataPBL.Envelope{2,k}]= envelope(dataPBL.Ptop{:,k}(:,2));
dataPBL.Smooth{1,k} = smooth(dataPBL.Ptop{:,k}(:,1),dataPBL.Ptop{:,k}(:,2),0.03,'rloess');
end
clearvars -except dataPB
I'm using this code, and i attached two files of data.

Iniciar sesión para comentar.

Respuestas (0)

Categorías

Más información sobre Structures en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by