SmryEachVar A Data Review Suite

From sasCommunity
Jump to: navigation, search

SmryEachVar: A Data Review Suite For Each Variable in All Data Sets in a Libref


previously known as:

Summarize Memnames in Libname

Author: Ronald J. Fehd

Abstract: This paper providess a set of parameterized include module, routines and subroutines which provide a summary of each data set (Memname) in a library (Libname).

Description:

  1. call execute routine ProcFreq (previously FreqAll), on all variables in each data set in a library.
  2. for numerics add: ProcMode and ProcSmry

Purpose: data review

Audience: data managers, intermediate to advanced users and macro programmers

Keywords: call execute, data review, dynamic programming, includes, list processing, nrstr, routines, source2, subroutines%, sysparm


Introduction:

Users responded favorably to Fehd's fall 2006 paper: FreqAll which provides a concise summary data set of one data set: one Memname.

And, of course, everyone wants to run this data review routine on every member in their library! ... or just one!

Updates of 2009-June

  • simplified modules for user copy and edit
    • SE0-sashelp-class.sas
    • SE0-library-all.sas
  • changed parameter names:
    • In_Data: sashelp.class, library._all_
    • Out_Txt for reports

Updates of 2008-May

Based on feedback and commentary from our user community since I published this suite in the fall RUGs and at SGF-2008 I have added the following features:

  • added parameter: DotSAS, default: blank, set to .sas for Unix usage
  • added parameter: Memname, default: _all_

users can now choose just one data set to review

  • added parameter, ExportFreq2csv, when true, 1, writes

proc freq output data set to .csv when CardRatio lt .5

  • removed variable Unique and replaced with:
  • added variables: CardRatio and CardNote which provide information of Cardinality Ratio, which is calculated as NobsFreq / NobsData.

see: http://www.sascommunity.org/wiki/Cardinality_Ratio

  • provided format value CardRatio; proc format is automagically submitted

by autoexec if not cexist(Library.Formats.CardRatio.format)

  • report of duplicate names is executed only when Memname ne _all_
  • consolidated 5 CallX* programs into CallXany; this reduces the level of %includes
  • new program CallXany which transforms _character_ variables into macro variables

and calls the named parameterized %include program

References

see also successors:

BibTex entry for this page and paper:

@inproceedings{sas-wiki.SmryEachVar,
    booktitle={SAS Community Wiki},
    year     = 2008,
    author   ={Ronald J. Fehd},
    title    ={{SmryEachVar}: A Data Review Suite For Each Variable in All Data Sets in a Libref},
    note     ={has .zip with version 2},
    url      ={http://www.sascommunity.org/wiki/SmryEachVar_A_Data_Review_Suite}}

@inproceedings{sgf2008.003,
    booktitle={Proceedings of the SAS Global Forum},
    year     = 2008,
    author   ={Ronald J. Fehd},
    title    ={{SmryEachVar}: A Data-Review Routine for All Data Sets in a Libref},
    note     ={Applications Development (Best Contributed Paper), 25 pp.;
              bibliography},
    url      ={http://www2.sas.com/proceedings/forum2008/003-2008.pdf}}

-- created by User:Rjf2 17:09, 7 March 2008 (EST)

--Ronald_J._Fehd macro.maven == the radical programmer