Home > database >  I'm trying to find multivariate outliers but the outlier() function only works for one df and n
I'm trying to find multivariate outliers but the outlier() function only works for one df and n

Time:02-14

I'm trying to use the outlier() function from psych. I have 2 df, both integers, 300x10. They are literally the same length and type of df the only difference is it's measurements from different expositions to a stimuli.

When I do it for df1 it's all good. If I do it for df2 it says

Error in solve.default(Sx) : 
  Lapack routine dgesv: system is exactly singular: U[10,10] = 0

I tried the solve() but oc doesn't work. I have no idea how to proceed pls help.

df1:

structure(list(AD_BORING_1 = c(1L, 2L, 3L, 5L, 4L, 5L, 3L, 6L, 
4L, 3L, 5L, 3L, 5L, 4L, 3L, 7L, 7L, 4L, 1L, 4L, 4L, 5L, 2L, 3L, 
3L, 5L, 6L, 6L, 1L, 2L, 2L, 3L, 4L, 4L, 2L, 1L, 5L, 7L, 3L, 3L, 
3L, 4L, 3L, 5L, 3L, 3L, 6L, 6L, 5L, 7L, 4L, 3L, 7L, 5L, 6L, 7L, 
5L, 2L, 3L, 5L, 3L, 2L, 4L, 6L, 2L, 5L, 2L, 2L, 2L, 5L, 6L, 2L, 
4L, 2L, 4L, 1L, 5L, 7L, 4L, 3L, 4L, 2L, 5L, 3L, 2L, 3L, 3L, 5L, 
6L, 6L, 3L, 6L, 2L, 5L, 4L, 4L, 6L, 3L, 5L, 6L, 5L, 5L, 4L, 6L, 
3L, 2L, 4L, 4L, 1L, 4L, 2L, 5L, 4L, 6L, 4L, 5L, 6L, 2L, 3L, 3L, 
3L, 4L, 6L, 5L, 5L, 3L, 3L, 2L, 2L, 1L, 4L, 6L, 2L, 5L, 2L, 4L, 
6L, 1L, 2L, 4L, 5L, 6L, 3L, 3L, 2L, 3L, 6L, 1L, 6L, 5L, 3L, 6L, 
5L, 3L, 3L, 3L, 6L, 4L, 5L, 3L, 6L, 5L, 5L, 6L, 3L, 3L, 5L, 5L, 
3L, 5L, 6L, 3L, 5L, 1L, 3L, 3L, 3L, 4L, 6L, 4L, 6L, 5L, 4L, 3L, 
6L, 3L, 1L, 2L, 4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
5L, 7L, 5L, 5L, 4L, 5L, 2L, 6L, 6L, 6L, 7L, 5L, 5L, 6L, 5L, 6L, 
5L, 6L, 1L, 5L, 6L, 6L, 4L, 5L, 5L, 5L, 5L, 5L, 5L, 6L, 6L, 6L, 
7L, 5L, 5L, 4L, 6L, 5L, 5L, 3L, 5L, 2L, 5L, 3L, 6L, 6L, 5L, 4L, 
5L, 2L, 5L, 6L, 5L, 6L, 5L, 5L, 2L, 5L, 4L, 3L, 6L, 7L, 5L, 6L, 
1L, 4L, 6L, 4L, 6L, 3L, 2L, 2L, 6L, 5L, 3L, 6L, 4L, 5L, 4L, 5L, 
4L, 6L, 4L, 5L, 5L, 5L, 5L, 6L, 1L, 5L)), row.names = c(NA, -300L
), class = c("tbl_df", "tbl", "data.frame"))

CodePudding user response:

Load libraries and group data

I'm not entirely sure what you are trying to group for your multivariate side of things, but I grouped your data by the "AD" variable and tried to identify outliers with their ratings that way:

# Load libraries:
library(tidyverse)
library(rstatix)

# Pivot data to get groups for df1:
df1pivot <- df1 %>% 
  pivot_longer(cols = everything(),
               names_to = "AD",
               values_to = "Rating")

Find Mahalanobis distance and its outliers

# Find mahalanobis distance for df1 and filter outliers:
df1pivot %>% 
  group_by(AD) %>% 
  mahalanobis_distance(Rating) %>% 
  filter(is.outlier==T)

Which gives us no multivariate outliers so far:

# A tibble: 0 x 3
# ... with 3 variables: Rating <int>, mahal.dist <dbl>, is.outlier <lgl>

Repeat for df2

# Same for df2 pivot:
df2pivot <- df2 %>% 
  pivot_longer(cols = everything(),
               names_to = "AD",
               values_to = "Rating")

# Find mahalanobis distance for df2 and filter outliers:
df2pivot %>% 
  group_by(AD) %>% 
  mahalanobis_distance(Rating) %>% 
  filter(is.outlier==T)

And as it was with df1, no outliers in df2:

# A tibble: 0 x 3
# ... with 3 variables: Rating <int>, mahal.dist <dbl>, is.outlier <lgl>

Edit

Based off your comments, here is a possible answer:

# Rename "good" and "bad" ratings of people and pivot:
df1pivot <- df1 %>%
  rename_with(.cols = everything(),
              .fn   = ~str_c(., c(rep('_Bad', 3),
                                  rep('_Good', 7)))) %>%
  pivot_longer(cols = everything(),
               names_to = c('Test', 'Test_Type'),
               names_pattern = '(.*)_(.*)',
               values_to = 'Score')

# Check Mahalanobis:
df1pivot %>% 
  group_by(Test_Type) %>% 
  mahalanobis_distance(Score) %>%
  filter(is.outlier==T)

# Same for df2
df2pivot <- df2 %>%
  rename_with(.cols = everything(),
              .fn   = ~str_c(., c(rep('_Bad', 3),
                                  rep('_Good', 7)))) %>%
  pivot_longer(cols = everything(),
               names_to = c('Test', 'Test_Type'),
               names_pattern = '(.*)_(.*)',
               values_to = 'Score')

# Check df2 outliers:
df2pivot %>% 
  group_by(Test_Type) %>% 
  mahalanobis_distance(Score) %>%
  filter(is.outlier==T)
  •  Tags:  
  • r
  • Related