Creating new variables and cleaning data in Statwing

You can now create new variables for analysis in Statwing:

Type Example
Bucketing numbers into groups 6-7 → “Satisfied”

3-5 → “Neutral”

1-2 → “Unsatisfied”
Grouping categories together USA & Mexico & Canada → “North America”
Colombia & Venezuela & (etc.) → “South America”
Mathematical functions and formulas =median(Score1, Score2, Score3) → median of the scores
Logic If Satisfaction < 3 and country = Canada
   then → “Unsatisfied Canadians”
   else → “Other”
Time functions 11/2/2012 → “Friday”
1/7/2014 → “Tuesday”
5/12/2014 → “Monday”

Or use similar tools to clean up dirty data:

Type Example
Grouping categories together f & female & Female → “Female”
Filtering out errant data If Date is before 1/1/1900

   then → (delete)
   else → (keep)

Let’s walk through some examples to get a feel for it. We’ll use a dataset of eleven years of point of sale data, where each row of data is one purchase.

Creating new variables from a time variable

Each purchase happened on a specific date. So if you Described the variable Purchase Date, you’d see:

Screen Shot 2014-09-25 at 9.43.17 PM

What if you wanted to know if more purchases happened on Sundays than on Mondays? Or in January versus February across all years of data?

Select one of Statwing’s time-specific functions to create a new variable, in this case tranforming dates like “2/3/2005” or “6/13/2013” to months like “February” and “June”…

new-date-var

…resulting in this:

Screen Shot 2014-09-25 at 10.22.49 PM

Cleaning categories

With hand-entered data, it’s not uncommon to see messy data like this:

Screen Shot 2014-09-25 at 10.33.46 PM

Select the variable, then “Clean”, then drag the categories into the correct positions:

female-category-grouping

So now your data will look like this:

Screen Shot 2014-09-28 at 5.46.17 PM

Bucketing numbers

Sometimes it’s useful to turn numeric data into categorical data by bucketing. So this…

Screen Shot 2014-09-28 at 5.52.34 PM

…can now easily be turned into this:

Screen Shot 2014-09-28 at 6.00.11 PM

 

You get the picture. As always, our goal is to make data analysis delightful and efficient.

To try these new tools out, sign in, upload some data (or use a sample dataset) and then use the “Clean” and “Create” buttons on the left sidebar.

Screen Shot 2014-09-29 at 2.43.54 PM

Enjoy!

Sorry, comments are closed for this post.