I have a database, where in the first column are some basketball teams and the following columns are some observed variables. I would like to do a cluster analysis using such packages:
library("cluster") ;
library("factoextra") ;
library("magrittr")
Database:
Whenreadingmydatabasethatwasincsv,Iturneditintoadata.frame,butinanattempttoscalethevariableswiththecodebelow,thiserrorappearssayingthatmy"Time" column should be numeric and thus consequently I can not also do the correlation matrix because in the label some random numbers appear instead of the name of the teams.
ERROR
my_data <- na.omit(my_data)
my_data <- scale(my_data)
Error in colMeans(x, na.rm = TRUE) : 'x' must be numeric
CORRELATION GRAPHIC ERROR
res.dist <- get_dist(my_data, stand = TRUE, method = "pearson")
fviz_dist(res.dist, gradient = list(low = "#00AFBB", mid = "white", high = "#FC4E07"))
Does anyone know how to solve this?