mjskay / mjskay/ARTool

How to get rownames from anova()

Open
#38 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
R
Stars
66
Forks
9
PR merge metrics
No merged PRs in 30d

Description

When rownames_to_column() is called on the anova results, the text is replaced with numbers.

# make some data
expand.grid(
  aaa = LETTERS[1:4],
  bbb = LETTERS[1:4],
  subject = 1:10
) %>% 
  mutate_all(factor) %>% 
  mutate(measure = rnorm(n())) %>% 
  
# ART ANOVA
art(measure ~ aaa * bbb + Error(subject/bbb), .) %>% 
  anova() %>% 
  
# get row names as a column
  rownames_to_column()

There are numbers instead of text:
image

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Run the reproducible example using art(), anova(), and rownames_to_column() to inspect where the row labels become numeric. Compare the anova result before and after rownames_to_column(); done when the intended text labels are preserved in the resulting column.

Written by the indexing model from the issue text.

Assessment

Tech stack
r
Domain
data
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.