df<- apply(temp2, 2, table)
I used this code and it only shows frequency. What can I add to this code to calculate percentage? temp2 has Gender(Male, Female), Age, location, Income & Investment. All of these are catagorical variables coded as 1, 2, 3 ,4, 5 except for Gender.