Tips and Tricks

10月 172017
 

Would you like to format your macro variables in SAS? Good news. It's easy!  Just use the %FORMAT function, like this: %let x=1111; Log %put %format(&x,dollar11.); $1,111 %put %format(&x,roman.); MCXI %put %format(&x,worddate.); January 16, 1963   %let today=%sysfunc(today()); %put %format(&today,worddate.); October 13, 2017   %put %format(Macro,$3.); Mac What?!  You never [...]

The post How to format a macro variable appeared first on SAS Learning Post.

8月 102017
 

In this post I describe the important tasks of data preparation, exploration and binning.These three steps enable you to know your data well and build accurate predictive models. First you need to clean your data. Cleaning includes eliminating variables which have uneven spread across the target variable. I give an [...]

The post 3 steps to prepare your data for accurate predictive models in SAS Enterprise Miner appeared first on SAS Learning Post.

7月 182017
 

Datasets are rarely ready for analysis, and one of the most prevalent problems is missing data. This post is the first in a short series focusing on how to think about missingness, how JMP13 can help us determine the scope of missing data in a given table, and how to [...]

The post How severe is your missing data problem? appeared first on SAS Learning Post.

5月 262017
 

Elizabeth is courageous. Scoliosis since birth, corrective spinal surgery replaced her spine with steel, tripping on stairs permanently broke her right ankle. Then she decided to come take yoga with me. To help ease back pain & reduce hip stress, I offered options like bent legs not cross. In class [...]

The post Take that SAS option appeared first on SAS Learning Post.

4月 252017
 

When developing SAS® data sets, program code and/or applications, efficiency is not always given the attention it deserves, particularly in the early phases of development. Since data sizes and system performance can affect a program and/or an application’s behavior, SAS users may want to access information about a data set’s [...]

The post Determining the size of a SAS data set appeared first on SAS Learning Post.

4月 182017
 

Ok, so you know how to create multiple sheets in Excel, but can anyone tell me how to control the name of the sheets when they are all created at once? In the ODS destination for Excel, the suboption SHEET_INTERVAL is set to TABLE by default.  So what does that [...]

The post How to control the name of Excel sheets when they are all created at once appeared first on SAS Learning Post.

3月 232017
 

SAS® users have an easy and convenient way to quickly obtain useful information (referred to as metadata) about their SAS session with a number of read-only SAS DICTIONARY tables or SASHELP views. At any time during a SAS session, information about currently defined system options, libnames, tables, columns and their [...]

The post Exploring the content of the DICTIONARIES table and VSVIEW SASHELP view appeared first on SAS Learning Post.

1月 032017
 

How many of you have been given a SAS data set with variables such as Age, Height, and Weight and some or all of them were stored as character values instead of numeric?  Probably EVERYONE! Yes, we all know how to do the old "swap and drop" (rename and convert), but […]

The post Character to Numeric Conversion in SAS appeared first on SAS Learning Post.

12月 292016
 

This SAS Jedi is very excited about the SAS 9.4 M4 release, which brought many wonderful gifts just in time for Christmas. So in the interest of extending the Christmas spirit, I'm going to blog about some of my favorites! I've long loved the SAS DO statement variant which allows […]

The post SAS Jedi Christmas - SAS 9.4 M4 DS2 Do Loop Upgrade appeared first on SAS Learning Post.

11月 042016
 

JMP supports many date/time formats, but some less conventional (or downright esoteric) formats still crop up from time to time. To many users, converting an oddly formatted date/time from string to numeric form is a frustrating endeavor, requiring custom formulas and an assortment of seldom-used string and numeric operations. With the Custom Date Formula Writer, you can simply point-and-click your date/time troubles away, generating the necessary formula without writing code.

To begin, install the Data Table Tools Add-in and navigate to the formula writer:

launchtabletools

Now the new date column is just four steps away:

  1. Choose the table and column containing the character date/time data.
  2. Point and click to delimit the "words" in the data.
  3. Specify the meaning of each word, and various options, using drop-down menus and radio buttons.
  4. Press the "Build formula column" button.

Here's what the process looks like:

Step 1: Choose the table and date/time column.

 

selectfile


Step 2: Point and click the text to delimit the data, then press the "Apply delimiting and choose words" button.

 

initial-delimiting


Step 3: Complete the dialog using the radio buttons and drop-down menus to select options and word roles.

 

characterdelimiting


Step 4: Click the "Build Formula Column" button to write the new formula column to the data table.

 

datatable
The column formula is written automatically. Isn't that nice? Hopefully, your date worries are now a thing of the past.

formula

This add-in, along with many others, is available for free on the JMP User Community's File Exchange. (A free SAS profile is required for access.)

I'll be blogging on more table tools in the future, so stay tuned!

Note: This blog post is first in a series exploring the various features of the Data Table Tools add-in.

tags: Add-Ins, Date/Time Format, Tips and Tricks

The post Data table tools part 1: Custom Date Formula Writer appeared first on JMP Blog.