Effacer les filtres
Effacer les filtres

Info

Cette question est clôturée. Rouvrir pour modifier ou répondre.

Group stats for only certain groups within all of them

1 vue (au cours des 30 derniers jours)
Brandon MacKinnon
Brandon MacKinnon le 10 Mar 2016
Clôturé : MATLAB Answer Bot le 20 Août 2021
I have this excel file. I want to do group stats on the second column. but only for ABBA and CCCC
clear
[~, ~, data] = xlsread('Book1.xls',1);
species = data(:, 1);
split = data(:, 2);
X = cell2mat(split);
[grp1,grp1c,grpMin1,grpMean1,grpMed1,grpSem1,grpMax1,s21,grpStd1,grp951,grpskew1,grpkurt1] = grpstats(X,species({'ABBA' 'CCCC'}),...
{'gname','numel','min','mean','median','sem','max','var','std','meanci',@skewness,@kurtosis},'Alpha',0.05);
Is there any way to do this? I keep getting error subindex not valid for this part
species({'ABBA' 'CCCC'})
My actual dataset is 10000 rows and all different ones are mixed in.
Any help would be appreciated! Thanks

Réponses (0)

Cette question est clôturée.

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by