software docs sas enterprise guide

Upload: nicolas-frazier

Post on 07-Apr-2018

240 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/6/2019 Software Docs SAS Enterprise Guide

    1/13

    May 2008

    Stanford UniversitySocial Science Data and Software

    Getting Started with SAS Enterprise Guide

    Table of Contents

    Overview of the User Interface .................................................................................................. 1

    Useful Pull-down Menus ............................................................................................................ 3

    Working with Data ..................................................................................................................... 4SAS data files ...........................................................................................................................................................4 Other data files.........................................................................................................................................................5

    Working with Tasks ................................................................................................................... 5Choosing a Task.......................................................................................................................................................5 Performing a Task....................................................................................................................................................6 Exploring a Typical SAS Task Window .......................................................................................................................7 Example: Creating a Simple Report............................................................................................................................7

    Working with Results ................................................................................................................. 8Changing the Result Format and Style........................................................................................................................8

    Working with Process Flow ...................................................................................................... 10

    For More Information and Assistance ...................................................................................... 12SAS Enterprise Guide Help..................................................................................................................................... 12SAS Enterprise Guide Tutorials............................................................................................................................... 12Books.................................................................................................................................................................... 12SSDS at Stanford................................................................................................................................................... 13

    Overview of the User Interface

    SAS Enterprise Guide is a Windows client application with an easy-to-use interface. It has a graphicalinterface consisting of pull-down menus, dialog boxes, and windows that display and organize data, and

    perform numerical and graphical tasks. You can perform all tasks in SAS Enterprise Guide by pointing

    and clicking the mouse. This section describes the basic features of the SAS Enterprise Guide pull-down

    menus and windows. SAS Enterprise Guide is a stand-alone application that requires a SAS server,

    which can be either a local server or a remote server on any major computer platform. To use SAS

    Enterprise Guide with a remote server, SAS Integration Technologies is also required.

    A basic familiarity with the Windows operating system is all you need to get started with SAS

    Enterprise Guide. You can access SAS Enterprise Guide on a PC from the Start menu, or by double-

    clicking on the Enterprise Guide icon (shown below) on the desktop if applicable.

    When you start SAS Enterprise Guide, a screen like the one below will appear:

  • 8/6/2019 Software Docs SAS Enterprise Guide

    2/13

    Getting Started with SAS Enterprise Guide - 2

    This area is the workspace, and the Project Designer is the only window that is open in the workspace.New windows open in the workspace when you generate reports or open data. When there is more than

    one window open in the workspace, you can use the tabs at the top of windows to navigate between

    them.

    The Project Explorer window displays a hierarchical view of the active project. When you create a new

    project, the Project Explorer window is empty. As you add data, run tasks, and generate results, an icon

    for each object is added to the Project Explorer window.

    The Project Designer window is a container for one or more process flows for the project. A process

    flow is a relational view of the objects in the project. As you add data, run tasks, and generate results, an

    icon for each object is added to the process flow and any relationship between the objects is shown withan arrow.

    You can create new process flows and you can copy or move objects between process flows. You can

    also run a portion of the process flow or the entire process flow.

    The Task Status window displays messages about the status of tasks as they are processing.

  • 8/6/2019 Software Docs SAS Enterprise Guide

    3/13

    Getting Started with SAS Enterprise Guide - 3

    The Task List is hidden by default, but you can display it by clicking or moving your mouse pointer

    over the Task List button. Task List allows you to perform various kinds of tasks (e.g. statistical

    analysis, graphs, etc.) by a simple click.

    Comprehensive help is available from the Help menu. By using the tabs in the Help window, you can

    browse the contents or index, perform a search, or bookmark pages for future reference.

    Useful Pull-down MenusLike most Windows programs, SAS Enterprise Guide has a toolbar and menu bar with pull-down menus

    that you can use to access many of the features of the program. The toolbar contains buttons for more

    commonly used procedures. To see what each button does, hold the mouse over the button for a moment

    and a description of what the button does will appear. The following is a summary of the main pull-

    down menus and their functions:

    Menu Functions

    File

    Open and save project, data, code, report, and process flow.

    Import and export data. Print process flow.

    EditModify or copy text, search and replace data. Expand or collapse

    data.

    View

    Customize the look of the SAS Enterprise Guide window by

    selecting to view the tool bars, project designer, project flow,

    task list, task status, and what is window.

    Code Edit and run SAS codes and macros.

    Data

    Edit data, add or delete rows and columns. Transpose and sort

    data. Append and split data. Generate a random sample from the

    data.

    Describe

    List data. Generate summarize statistics of the data. Distribution

    analysis. One-way frequencies. Wizards for summary statistics

    available.

    Graph

    Create charts and graphs such as scatterplots, bar charts, line

    graphs, and pie charts, donut charts, and box plot. Wizard for bar

    charts, pie charts, and line plot available.

    AnalyzePerform statistical procedures to produce descriptive and

    inferential statistics.

    Add-in The Addin Manager menu enables you to add and remove add-intasks.

    ToolsCombine multiple reports into one. Set style of report. Schedule

    and order tasks.

    Window Bring a different window to the foreground.

    HelpGet help on SAS Enterprise Guide procedures. Getting Started

    tutorial. Connect to the online SAS Enterprise Guide resources.

  • 8/6/2019 Software Docs SAS Enterprise Guide

    4/13

    Getting Started with SAS Enterprise Guide - 4

    Working with Data

    Before you can do anything in SAS Enterprise Guide, you need to add the data that you want to analyze

    to your project. In addition to SAS data files, SAS Enterprise Guide can read most PC data files such as

    HTML, Microsoft Access, dBASE, Microsoft Excel, Microsoft Exchange, IBM Lotus 1-2-3, and

    Paradox files. You can open data that is located on your own computer or on SAS server that you are

    authorized to access.

    SAS data files

    Data on a server can either be opened from the Libraries or Files folder. SAS libraries are pointers to

    locations that store SAS data sets. The Files folder enables you to browse the directory structure of the

    server and open any data file that SAS Enterprise Guide can read.

    If you choose to look for data on your local computer, you can browse the file structure of your

    computer. There is a large collection of sample data that is installed with SAS Enterprise Guide in the

    Sample directory.

    Here is an example to open a SAS data set on the local computer:

    From the File menu, select Open Data. Select Local Computer, find the folder where the data islocated, and double-click the data.

    When you open data, it opens in a data grid that is located in the workspace area. The tab at the top of

    the data grid shows the data filename. At the same time, a shortcut to the data is automatically added to

    the current project and the data opens in a data grid. By default, the data opens in read-only mode. In the

    Process Flow window there are shortcuts to a SAS data set.

  • 8/6/2019 Software Docs SAS Enterprise Guide

    5/13

    Getting Started with SAS Enterprise Guide - 5

    Other data files

    If you select an Excel file to open, you must decide if you want to open the file as it is or if you want to

    import the data to create a SAS data set. If you choose to create a SAS data set from the data, the Import

    Data task opens automatically.

    If you have data in a text file that you want to use in a task, you must import the data or create a SASdata set first. You can open the Import Data task from the File menu.

    After having added data to your project, you can explore the data by viewing it in the data grid. You can

    also view the properties of data by right-clicking the data object in the Project Explorer or Process

    Flow window and selecting Properties from the pop-up menu. The Columns page of the Properties

    window lists all the columns, or variables, in the data as well as the properties of each column.

    You can also set options for your task results by going to Tools, select Options and make changes in the

    pop-up menu. There are options you can set that affect the way that data is opened and displayed in SAS

    enterprise guide.

    SAS reads the data in each column as either character data or numeric data. Numeric data is grouped

    into four different types of data depending on how it is displayed. These icons appear in the column

    headings of the data grid.

    In addition to opening existing data and using it, you can also work with your data in the following

    ways:

    use the Import Data wizard to create SAS data sets from raw data files and Excel files

    use the New Data wizard to create a new SAS data file

    use the Query Builder to manipulate your data (for example, filter, join, add columns, and sort)

    make changes directly to data in the Data Grid

    Working with Tasks

    Choosing a Task

    After you have data in your project, you generally want to work with it in some way. In SAS Enterprise

    Guide, you use tasks to do everything from manipulating data, to running specific analytical procedures,

    to creating reports.To help you decide which task to use, descriptions and business examples for each SAS task are

    available in the What is window. You can open this window by selecting View > What is. As you

    move your mouse pointer over a task in the Task List, a description of that task appears in the What is

    window. The image below shows a description for the Summary Tables task in the What is window.

    After you have opened a task window, you can view help for the entire task by pressing F1 to open the

    help window for that task. In addition, you can view a short description of each option that you can

    select in a task by moving your mouse pointer over the option and reading the description in the help

    pane at the bottom of the task window.

  • 8/6/2019 Software Docs SAS Enterprise Guide

    6/13

    Getting Started with SAS Enterprise Guide - 6

    Performing a Task

    One way to select tasks is by using the Task List. The Task List is hidden by default, but you can

    display it by clicking or moving your mouse pointer over the Task List button.

    If a task has a wizard version and you want to use it, you can clickUse Wizard.

    As you scroll down in the Task List, you see tasks in the Graph category. As you scroll down further,

    you see tasks for Statistical Analysis.

    The Task by Name tab lists individual tasks alphabetically. This tab also lists the SAS procedure or

    procedures that are used in the task.

    The same tasks that you can select from the Task List are also available from the Data, Describe,

    Graph, and Analyze menus. Tasks on the Analyze menu are grouped by type of statistical analysis.

    In each task window, there are certain steps that you must complete before you can run the task. For

    example, you must specify which variables you want to analyze and how you want to analyze them.After that, you can select from a variety of options that pertain to the particular task. The most common

    options for each task are selected for you, so after you've specified the information that is necessary to

    run the task, the Run button becomes available and you can run the task and get the default results.

  • 8/6/2019 Software Docs SAS Enterprise Guide

    7/13

    Getting Started with SAS Enterprise Guide - 7

    Exploring a Typical SAS Task Window

    All tasks have a Task Roles page where you assign variable to roles in the task. This is how you tell

    SAS enterprise guide how you want to analyze your data. The Task Roles list displays all the ways that

    variable can be used in the task.

    The Variables to Assign list displays all the variable from the data that you have selected.

    Note: The data icon next to each variable shows the variables type, and the icon next to each task roleshow the type of variable that the role will accept.

    To assign a variable to a task role, you select the variable and drag it to the role. You can also select the

    variable, click the right arrow, and select the role from the menu. Most tasks enable you to set a title and

    footnote for the task.

    Note: As you assign variables to roles and select options, SAS Enterprise Guide generates code that it

    will send to SAS to process. You can see this code by clicking the Preview code button in the lower-

    left of each task window.

    Example: Creating a Simple Report

    The most basic report that you can create is a List Report. This type of report has one line for each row

    (or observation) in your data. You can select the columns that you want in your report, group the data,

    and add totals and subtotals. The task that creates this report is the List Data task.

    In the Project Explorer window, select the data set. Then in the Describe menu, select List Data.

    Select variables of interest, by pressing CTRL and clicking them, and drag them to the List Variables

    category on the right, or click the right arrow and select List variables. After that, assign the grouping

  • 8/6/2019 Software Docs SAS Enterprise Guide

    8/13

    Getting Started with SAS Enterprise Guide - 8

    variable (if applicable) by dragging it to the Group analysis by role, and the Identifying label role.

    You can now set Options if needed and clickRun. When the report is displayed, clickMaximize

    Workspace so that you can see all the columns in the report. The following graph is an example of List

    variable reports.

    Working with Results

    Changing the Result Format and Style

    The default report format of SAS Enterprise Guide is HTML report that uses a default style. To create

    an HTML report in a different style or to create a report in a different format (e.g. PDF), you don't have

    to start over to do this. You can do this for all the tasks that you run by using the Options window, or

    you can override the defaults that you set in the Options window by changing options in the Properties

    window for the specific task.

    Suppose you want to change the preferences for the List Data task so that results are generated in PDFas well as HTML format. Then set the default style for HTML results to sasweb.

    In the Project Explorer window, clickList Data and select Properties from the pop-up menu. In the

    selection pane, select Results. Select the Override the preferences set in Tools -> Options check box.

    Click the style drop-down list for HTML. Click once to scroll down, and then select sasweb. Under

    Result Formats, select PDF, and clickOK.

    Now rerun the List Data task to generate PDF results and HTML results in the new style.

  • 8/6/2019 Software Docs SAS Enterprise Guide

    9/13

    Getting Started with SAS Enterprise Guide - 9

    In the Project Explorer window, clickList Data and select Run List Data from the pop-up menu. In

    the message window, clickYes. The PDF results open because they are the list results to be generated.

    Now suppose you would like to export the HTML List Data as a step in the project, so each time you run

    the project an updated HTML file is exported to a specified location. First, in the Project Explorerwindow, clickHTML - List Data and select Export -> Export HTML - List Data As A Step In

    Project from the pop-up menu.

    The first page of the Export wizard enables you to select the file that you want to export. ClickNext.

    The second page of the Export wizard enables you to specify a location for the exported file. If you

    would like to change the name of the file, so clickEdit, and click in the File name box to change the

    name. ClickSave. ClickNext.

    The third page of the Export wizard enables you to review the selections that you have made. Click

    Finish.

    The Export task runs and creates the HTML file. You have changed the result format and style, and you

    have learned to export an HTML file as a step in a project.

  • 8/6/2019 Software Docs SAS Enterprise Guide

    10/13

    Getting Started with SAS Enterprise Guide - 10

    Working with Process Flow

    In practice you will probably have multiple data sets and tasks in one project. Sometimes it is helpful to

    create a new process flow and move some of the objects from the default process flow to a separate

    process flow. This makes it easy to run a process flow to refresh your results. You can even use Tools in

    SAS Enterprise Guide to schedule the task to run automatically.

    Here is an example how you can run the same task repeatedly, on different data sets without doing

    everything from the beginning. The Project Designer window that is shown below contains two

    Process Flow windows. The process flow named Candy Nutritional Report contains the objects that

    you want to run repeatedly (e.g. each month) to refresh your results.

  • 8/6/2019 Software Docs SAS Enterprise Guide

    11/13

    Getting Started with SAS Enterprise Guide - 11

    First, you need to create a new process flow for the project and rename it. Click the Project Designer

    tab. Click in a blank area of the Process Flow window and select New -> Process Flow from the pop-upmenu. ClickProcess Flow 1 and select Rename from the pop-up menu. Fill in the name box Candy

    Nutrition Report and then clickOK.

    Then, you need to move the List Data task and associated results from the default process flow to the

    new one. Click the Process Flow tab. ClickList Data and select Move List Data to Candy Nutrition

    Report. Click the Candy Nutrition Reporttab. Click in a blank area of the Process Flow window

    and select Run Candy Nutrition Report from the pop-up menu. Note: You can look at the Task

    Status window to see the messages about processing. Also notice the background color around the tasks

    that indicates the status. Click anywhere in the window to continue. Now, you have created a process

    flow for a particular report so that you can run it to refresh your reports.

  • 8/6/2019 Software Docs SAS Enterprise Guide

    12/13

    Getting Started with SAS Enterprise Guide - 12

    For More Information and Assistance

    SAS Enterprise Guide Help

    SAS Enterprise Guide has an extensive help system that provides information about using it andunderstanding the results. To access the Help system, go to the Help menu and select an option.

    The Explore SAS Enterprise Guide lists a table of contents from which you can link to the topics

    listed, the Getting Started Tutorial walks you through the most frequently used features of SAS

    Enterprise Guide. You are also only a click away from online resources of SAS enterprise guide. This

    resource contains much up-to-date information about this product.

    SAS Enterprise Guide Tutorials

    For information on SAS Enterprise Guide tutorials and resources, see

    http://support.sas.com/documentation/onlinedoc/guide/.

    Books

    SAS for Dummies, by Stephen McDaniel and Chris Hemedinger

    The Little SAS Book for Enterprise Guide 4.1, by Susan Slaughter and Lora Delwiche, SAS

    Corporation

    Statistics Using SAS Enterprise Guide, by James Davis, SAS Corporation

  • 8/6/2019 Software Docs SAS Enterprise Guide

    13/13

    Getting Started with SAS Enterprise Guide - 13

    SSDS at Stanford

    The software consultants at Social Science Data and Software (SSDS) provide technical support for SAS

    Enterprise Guide users at Stanford. Users can view documents, access information about our drop-in

    hours, and submit questions from our web page at:

    http://ssds.stanford.edu/

    Copyright2008, by The Board of Trustees of the Leland Stanford Junior University. Permission granted to copy for non-commercial purposes, provided we receive acknowledgment and a copy of the document in which our material appears. Noright is granted to quote from or use any material in this document for purposes of promoting any product or service.

    Software Support, Social Science Data and Software

    Document revised: May 7, 2008