The SASEFAME Interface Engine

Example 41.6 Reading Other Fame Data Objects with the FAMEOUT= Option

This example shows how you can designate the data objects that are output to your SAS data set by using the FAMEOUT= option. In this example, the FAMEOUT=FORMULA option selects the formulas and their source definitions to be output. The RANGE= option is ignored since no time series are selected when FAMEOUT=FORMULA is specified.

options validvarname=any ls=90;

%let FAME=%sysget(FAME);
%put(&FAME);
%let FAMETEMP=%sysget(FAME_TEMP);
%put(&FAMETEMP);

libname lib6 sasefame "%sysget(FAME_DATA)"
   fameout=formula
   convert=(frequency=business technique=constant)
   range='02jan1995'd - '25jul1997'd
   wildcard="?YIELD?" ;

data crout;
   set lib6.training;
   keep 'S.GM.YIELD.A'n -- 'S.XON.YIELD.A'n ;
run;

title1 'Formulas from the TRAINING DB, FAMEOUT=FORMULA Option';
title2 'Using WILDCARD="?YIELD?"';
proc contents
   data=crout;
run;

Output 41.6.1shows the results.

Output 41.6.1: Contents of OUT=CROUT from the FAMEOUT=FORMULA Option of the Training Fame Data

Formulas from the TRAINING DB, FAMEOUT=FORMULA Option
Using WILDCARD="?YIELD?"

The CONTENTS Procedure

Alphabetic List of Variables and Attributes
# Variable Type Len
1 S.GM.YIELD.A Char 82
2 S.GM__PP.YIELD.A Char 82
3 S.HWP.YIELD.A Char 82
4 S.IBM.YIELD.A Char 82
5 S.INDUT.YIELD.A Char 82
6 S.SPAL.YIELD.A Char 82
7 S.SPALN.YIELD.A Char 82
8 S.SUNW.YIELD.A Char 82
9 S.XOM.YIELD.A Char 82
10 S.XON.YIELD.A Char 82


The FAMEOUT=FORMULA option restricts the SAS data set to include only formulas. The WILDCARD=?YIELD? option further limits the selection of formulas to those whose names contain YIELD.

options validvarname=any linesize=79;

title1 'Formulas from the TRAINING DB, FAMEOUT=FORMULA Option';
title2 'Using WILDCARD="?YIELD?"';
proc print 
   data=crout noobs;
run;

Output 41.6.2 shows the results.

Output 41.6.2: Listing of OUT=CROUT from the FAMEOUT=FORMULA Option of the TRAINING Fame Data

Formulas from the TRAINING DB, FAMEOUT=FORMULA Option
Using WILDCARD="?YIELD?"

S.GM.YIELD.A S.GM__PP.YIELD.A S.HWP.YIELD.A S.IBM.YIELD.A S.INDUT.YIELD.A S.SPAL.YIELD.A S.SPALN.YIELD.A S.SUNW.YIELD.A S.XOM.YIELD.A S.XON.YIELD.A
(%SPLC2TF(C37044210X01, IAD_DATE.H, IAD.H)/C37044210X01.CLOSE)*C37044210X01.ADJUST (%SPLC2TF(C37044210X01, IAD_DATE.H, IAD.H)/C37044210X01.CLOSE)*C37044210X01.ADJUST (%SPLC2TF(C42823610X01, IAD_DATE.H, IAD.H)/C42823610X01.CLOSE)*C42823610X01.ADJUST (%SPLC2TF(C45920010X01, IAD_DATE.H, IAD.H)/C45920010X01.CLOSE)*C45920010X01.ADJUST (%SPLC2TF(C00000110X00, IAD_DATE.H, IAD.H)/C00000110X00.CLOSE)*C00000110X00.ADJUST (%SPLC2TF(C00000117X00, IAD_DATE.H, IAD.H)/C00000117X00.CLOSE)*C00000117X00.ADJUST (%SPLC2TF(C00000117X00, IAD_DATE.H, IAD.H)/C00000117X00.CLOSE)*C00000117X00.ADJUST (%SPLC2TF(C86681010X60, IAD_DATE.H, IAD.H)/C86681010X60.CLOSE)*C86681010X60.ADJUST (%SPLC2TF(C30231G10X01, IAD_DATE.H, IAD.H)/C30231G10X01.CLOSE)*C30231G10X01.ADJUST (%SPLC2TF(C30231G10X01, IAD_DATE.H, IAD.H)/C30231G10X01.CLOSE)*C30231G10X01.ADJUST


Additional examples of the FAMEOUT= option are shown in Example 41.11, Example 41.12, Example 41.13, Example 41.14, and Example 41.15.