I tried to test if the matrix is symmetric, but this doesn't work.
> View(new.function)
> View(new.function)
> new.function <- function(a){
+ for(i in 1:nrow(a)){
+ for(j in 1:ncol(a)){
+ if(a==t(a)){
+ print("true")
+ }else{print("false")}
+ }
+ }
+ }
> a <- matrix(1:3,3,3)
> a
[,1] [,2] [,3]
[1,] 1 1 1
[2,] 2 2 2
[3,] 3 3 3
> new.function(a)
[1] "true"
[1] "true"
[1] "true"
[1] "true"
[1] "true"
[1] "true"
[1] "true"
[1] "true"
[1] "true"