me on twitter

brain of mat kelcey


simple statistics with R

October 03, 2009 at 03:43 PM | categories: statistics, r, language | View Comments

i'm learning a new statistics language called R and it's pretty cool.make a vector ...12> c(3,1,4,1,5,9,2,6,5,3,5,8) [1] 3 1 4 1 5 9 2 6 5 3 5 8turn it into a frequency table ...123> table(c(3,1,4,1,5,9,2,6,5,3,5,8))1 2 3 4 5 6 8 92 1 2 1 3 1 1 1sort by frequency ...123> sort(table(c(3,1,4,1,5,9,2,6,5,3,5,8)))2 4 6 8 9 1 3 51 1 1 1 1 2 2 3and plot!1> barplot(sort(table(c(3,1,4,1,5,9,2,6,5,3,5,8))))so simple!...
Read and Post Comments

old projects...