Questions tagged [rstatix]

for questions relating to the `rstatix` R package ("Pipe-Friendly Framework for Basic Statistical Tests")

89 questions
0
votes
1 answer

How to add compact letter dispaly to dunn_test while using group_by in R?

Create some data # Generate species species <- rep (c("Oak", "Elm", "Ash"), each = 10) # Generate treatments dose_1 <- rep (c("Ctrl"), 30) dose_2 <- rep (c ("L"), 30) # Generate results result_1 <- c((runif(10, 9, 12)), runif(10, 14, 16),…
UseR10085
  • 7,120
  • 3
  • 24
  • 54
0
votes
0 answers

Rstatix anova_test doesn't recognize "correction" argument

Without the argument, it seems to work. >anova_test(data=Plantaris_Morpho_and_WB,dv=Plantaris_body,wid="Mouse_#",between=Day,within=Treatment) ANOVA Table (type II tests) Effect DFn DFd F p p<.05 ges 1 Day 3 28 …
0
votes
2 answers

how to set string argument in a function within map function

I have this nested dataset dput(head(nest2, 2)) structure(list(grp = c("Avoiding", "Savoring"), data = list(structure(list( Gender = c("Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women",…
12666727b9
  • 1,133
  • 1
  • 8
  • 22
0
votes
1 answer

cannot use the map function on nested dataset

I have the following dataset # dput(head(dat, 130)) dat <- structure(list( Gender = c("Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women", "Women",…
12666727b9
  • 1,133
  • 1
  • 8
  • 22
0
votes
1 answer

I have no NAs in my dataset but I still get the error missing value where TRUE/FALSE needed?

I want to calculate the effect size of my variables. I am getting ther error "missing value wher TRUE/FALSE needed" even though I purged my data.frame of NAs before. Any idea why this is happening? I am using the cohens_d() function of rstatix . R…
mr.raccoon
  • 47
  • 7
0
votes
2 answers

How to extract pvalue for each column in r?

I have a dataframe as follows: df = structure(list(aa = c(1L, 5L, 8L, 10L, 1L, 10L, 8L, 6L, 7L, 4L, 1L, 5L, 7L, 7L, 5L, 8L), bb = c(2L, 9L, 1L, 10L, 8L, 7L, 10L, 8L, 1L, 7L, 2L, 10L, 3L, 5L, 2L, 10L), cc = c(1L, 5L, 9L, 4L, 9L, 1L, 8L, 3L, 2L,…
user2110417
0
votes
0 answers

anova_test in rstatix in R not reporting sphericity

I've now tried for a while to find out why my repeated measures anova_test does not return sphericity results like it's supposed to do according to everything I've read. I know it doesn't return the Mauchly's with independent variables with only two…
JoLe
  • 1
  • 1
0
votes
0 answers

Performing rstatix t_test on grouped data for facetted plotting with stat_pvalue_manual

I'd like to perform a t_test on each group within my data. I'd like to be able to plot the results in ggplot, with each group and t_test in separate facets of facet_grid. Here's some example data data <- structure(list(line = c("low", "low", "low",…
Mike
  • 921
  • 7
  • 26
0
votes
1 answer

Error when trying to run pairwise comparison in a loop in R

This error throws when I try to run this code. The anova and anova results function without issuse. Why is the column in the pairwise_t_test not the same as the dv= column in the anova. Error in pull(): ! Can't extract columns that don't exist. ✖…
swats15
  • 15
  • 3
0
votes
1 answer

rstatix::wilcox_test doesn't take formula as variable

I am trying to do boxplots and add p-values from rstatix::wilcox_test(). But I want to do this in a loop. so the column names for the formula for wilcox_test is stored in a variable. When I use the variable name in the wilcox_test, it throws…
arshad
  • 393
  • 1
  • 11
0
votes
0 answers

Error in app$vspace(new_style$`margin-top` %||% 0) : attempt to apply non-function in rstatix command

I don't understand what I am doing wrong: I would like to test for pairwise differences in my data: leber_test <- structure(list(ID = c("TG5", "YLG22", "SR3", "KBU15", "YGL31", "TG6", "KBO21", "KBU15", "YLG19", "FB9"), sub_group = structure(c(2L,…
Nadiine El Nino
  • 339
  • 1
  • 6
0
votes
0 answers

Why do the results of Dunn's test in GraphPad Prism and R differ?

I have three sets of data, to which I want to apply Dunn's test. However, the test shows different results when performed in GraphPad Prism and R. I've been reading a little bit about the test here, but I couldn't understand why there is a…
Daniel Valencia C.
  • 2,159
  • 2
  • 19
  • 38
0
votes
1 answer

R for loop stopping at 27 of 67 variables(columns) in for-loop Dunn Test

I've been doing Dunns tests as post-hoc and corrections for my thesis data and I've run into an issue. I have 67 variables and 3 groupings that I'm running through, so loops just easily solve the tons of data…
mcChris
  • 23
  • 4
0
votes
1 answer

Error with t_test() function when trying to group the data and run multiple t-test at a time

I am trying to run t-tests on my data using the following code: stat.test <- mydata.long %>% group_by(cytokines) %>% t_test((value ~ Rx)) %>% adjust_pvalue(method = "bonferroni") %>% add_significance() stat.test My data frame looks like…
KCS
  • 67
  • 3
0
votes
1 answer

not enough 'x' or 'y' observations in ggplot2 for t-tests or Wilcoxon test

I'm able to run a t-test or a Wilcoxon test on the data with no warnings, but I get an error when I try to plot in with ggpubr 's function stat_pvalue_manual() in ggplot2 The t-test works fine: ### running a t-test (no problem): t.test(SUJ_PRE ~…
Larissa Cury
  • 806
  • 2
  • 11