I have this table:
head(tb)
shot_made_flag
opponent 0 1
ATL 54.79452 45.20548
BKN 60.00000 40.00000
BOS 58.87612 41.12388
CHA 56.40000 43.60000
CHI 56.97674 43.02326
CLE 56.03113 43.96887
And this is my code:
table(opponent,shot_made_flag)
rowSums(table(opponent,shot_made_flag))
b<table(opponent,shot_made_flag)/rowSums(table(opponent,shot_made_flag))*100
head(tb)
I would like to sort my table by values in column 1, but I never get the table back as a result. I only get the values in column 1 sorted in crescent (or decrescent order)