# Creating a dataframe df1 = data.frame( "Name" = c("Amar", "Akbar", "Ronald"), "Language" = c("R", "Python", "C#"), "Age" = c(26, 38, 22) ) # Converting into numeric matrix df2 <- data.matrix(df1)