SAS

Blogs on the SAS software

6 tips for timing the performance of algorithms

August 21, 2017
By
6 tips for timing the performance of algorithms

When you implement a statistical algorithm in a vector-matrix language such as SAS/IML, R, or MATLAB, you should measure the performance of your implementation, which means that you should time how long a program takes to analyze data of varying sizes and characteristics. There are some general tips that can [...] The post 6 tips for timing the performance of algorithms appeared first on The DO Loop.

Read more »

Use a bar chart to visualize pairwise correlations

August 16, 2017
By
Use a bar chart to visualize pairwise correlations

Visualizing the correlations between variables often provides insight into the relationships between variables. I've previously written about how to use a heat map to visualize a correlation matrix in SAS/IML, and Chris Hemedinger showed how to use Base SAS to visualize correlations between variables. Recently a SAS programmer asked how [...] The post Use a bar chart to visualize pairwise correlations appeared first on The DO Loop.

Read more »

What is rank correlation?

August 14, 2017
By
What is rank correlation?

When someone refers to the correlation between two variables, they are probably referring to the Pearson correlation, which is the standard statistic that is taught in elementary statistics courses. Elementary courses do not usually mention that there are other measures of correlation. Why would anyone want a different estimate of [...] The post What is rank correlation? appeared first on The DO Loop.

Read more »

Robust principal component analysis in SAS

August 9, 2017
By
Robust principal component analysis in SAS

Recently, I was asked whether SAS can perform a principal component analysis (PCA) that is robust to the presence of outliers in the data. A PCA requires a data matrix, an estimate for the center of the data, and an estimate for the variance/covariance of the variables. Classically, these estimates [...] The post Robust principal component analysis in SAS appeared first on The DO Loop.

Read more »

The curse of non-unique eigenvectors

August 7, 2017
By
The curse of non-unique eigenvectors

A SAS customer asked, "I computed the eigenvectors of a matrix in SAS and in another software package. I got different answers? How do I know which answer is correct?" I've been asked variations of this question dozens of times. The answer is usually "both answers are correct." The mathematical [...] The post The curse of non-unique eigenvectors appeared first on The DO Loop.

Read more »

Dimension reduction: Guidelines for retaining principal components

August 2, 2017
By
Dimension reduction: Guidelines for retaining principal components

Last week I blogged about the broken-stick problem in probability, which reminded me that the broken-stick model is one of the many techniques that have been proposed for choosing the number of principal components to retain during a principal component analysis. Recall that for a principal component analysis (PCA) of [...] The post Dimension reduction: Guidelines for retaining principal components appeared first on The DO Loop.

Read more »

Flip it. Flip it good.

July 31, 2017
By
Flip it. Flip it good.

A SAS user needed to convert a program from MATLAB into the SAS/IML matrix language and asked whether there is a SAS/IML equivalent to the fliplr and flipud functions in MATLAB. These functions flip the columns or rows (respectively) of a matrix; "LR" stands for "left-right" and "UD" stands for [...] The post Flip it. Flip it good. appeared first on The DO Loop.

Read more »

Options for teaching R to beginners: a false dichotomy?

July 27, 2017
By
Options for teaching R to beginners: a false dichotomy?

I've been reading David Robinson's excellent blog entry "Teach the tidyverse to beginners" (http://varianceexplained.org/r/teach-tidyverse), which argues that a tidyverse approach is the best way to teach beginners.  He summarizes two competing cu...

Read more »

thinking with data with "Modern Data Science with R"

July 26, 2017
By
thinking with data with "Modern Data Science with R"

One of the biggest challenges educators face is how to teach statistical thinking integrated with data and computing skills to allow our students to fluidly think with data.  Contemporary data science requires a tight integration of knowledge...

Read more »

Random segments and broken sticks

July 26, 2017
By
Random segments and broken sticks

A classical problem in elementary probability asks for the expected lengths of line segments that result from randomly selecting k points along a segment of unit length. It is both fun and instructive to simulate such problems. This article uses simulation in the SAS/IML language to estimate solutions to the [...] The post Random segments and broken sticks appeared first on The DO Loop.

Read more »


Subscribe

Email:

  Subscribe