 # Non-tenure track salaries

I was preparing a data analysis assignment for one of my classes, and decided I needed an example for my students.  Similar to what I’m asking of my students, I wanted to use public employee salary data from the the Texas Tribune Government Salaries Explorer.  After a few moments’ thought* , I hit upon the topic of salaries for non-tenured faculty at the University of Texas at San Antonio, where I teach statistics. I downloaded the UTSA data–an Excel CSV file–and selected out employees whose job titles contained the words “ADJUNCT”, “LECTURER”, or “TUTOR”, and copied those to a separate … Continue reading Non-tenure track salaries # Data to Viz

For data analysts using R, this is huge.  Find out how to generate the graph you need for the data you have with just a few clicks. Yes, you’ll find some fine print explaining that the site is not comprehensive.  BUT, it still has a trove of graph types and accompanying R and python code to generate them. Tip from the R Bloggers Update: from the O’Reilly Data Science Newsletter, I learn that the Data to Viz site has a CAVEATS page, showing many of the most common “worst practices” of data visualization, whether confusing, misleading, or downright deceptive. I’m … Continue reading Data to Viz

# R Tutorial: the non-linear equation solver

Need a numerical solution to simultaneous non-linear equations?  The nleqslv package is just what you’re looking for!  The coding required is minimal; just define the equations you want solved in a function, set some initial values, and let ‘er rip. Here’s an example that uses the method of moments to estimate the parameters of a beta-binomial distribution. Continue reading R Tutorial: the non-linear equation solver # R Tutorial: Correlation

Fisher’s iris dataset is the basis for this extended example in the calculation and visualization of correlations.  The ggpairs() function gives an impressive coded scatterplot matrix.  And an old friend makes a last-minute cameo appearance. Update:  Dirk Eddelbuettel just released tint 0.0.3 (tint is not Tufte) with some nifty examples.  I wanted to try it out, so I’ve updated the example using tint and added two margin plots to illustrate the Simpson’s Paradox  situation.  Tip from R Bloggers. Continue reading R Tutorial: Correlation # R Tutorial: A Bayesian Estimate of Proportion

This is an old chestnut in Bayesian statistics, using the conjugate beta prior to find a beta posterior distribution for a proportion.  If you’re unfamiliar with the calculation of the posterior distribution, there’s a link in the tutorial. Continue reading R Tutorial: A Bayesian Estimate of Proportion # R Tutorial: Teasing Out a Markov Chain

Azzalini and Bowman’s Old Faithful geyser data provides fodder for a lot of data exploration in R (scatterplots, ggplot2, simple regression, kmeans clustering, and Markov chain estimation).  All the really interesting stuff in the tutorial  happens if you click through to Analysis > Models > Standardized Cluster Model.  (The standardized clustering approach is not given in the original paper.) Continue reading R Tutorial: Teasing Out a Markov Chain

# Beginning: R Tutorials

After a long, slow start, R is catching on with statisticians and (some) scientists at UTSA.  The Biology Department has asked that I use R in teaching biostatistics, and many of the courses for statistics majors are using R rather than SAS (a UTSA tradition).  Students have not been idle; the statistics club has asked me to present an occasional series of R tutorials to get their members up to speed.  Here are the first two tutorials: Getting Started with R The ggplot2 Fakebook These tutorials are all HTML files, generated with RMarkdown.  Students who attend the presentations are also … Continue reading Beginning: R Tutorials