How do I exclude data from statistics (Kruskal-Wallis test)?
Mostrar comentarios más antiguos
Hi everyone,
I have loaded a table into matlab using T = readtable(filename). The table contains two columns where data is grouped by five concentrations like this example:
data concentration
23 1
32 1
45 2
44 2
22 3
21 3
26 4
26 4
41 5
44 5
Lets say I only want to test the data of groups 3 - 5. How do I exclude data (1 and 2) from the statistical test?
I want to carry out a Kruskal-Wallis test for this.
How do i exclude data from a Kruskal-Wallis test?
Any help would be highly appreciated!
1 comentario
Tommy
el 28 de Mzo. de 2020
You could get a subset of your table with
subset = T(any(T.concentration==[3 4 5],2),:)
so that subset only contains the data in groups 3 through 5.
Then the test might be
p = kruskalwallis(subset.data, subset.concentration)
but not 100% sure on that.
Respuestas (0)
Categorías
Más información sobre Tables en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!