Sample 25554: Modify a key map using PROC GKEYMAP
This sample uses PROC GKEYMAP to modify multiple characters in an existing key map.
These sample files and code examples are provided by SAS Institute
Inc. "as is" without warranty of any kind, either express or implied, including
but not limited to the implied warranties of merchantability and fitness for a
particular purpose. Recipients acknowledge and agree that SAS Institute shall
not be liable for any damages whatsoever arising out of their use of this material.
In addition, SAS Institute will provide no support for the materials contained herein.
This sample uses PROC GKEYMAP to modify multiple characters in an existing key map.
/* Specify the libref GFONT0 at the location */
/* where the font to be stored. */
libname gfont0 'your-directory';
/* Set the graphics environment */
goptions reset=all cback=white border htitle=12pt htext=10pt;
/* Find the name of the current keymap */
proc goptions option=keymap;
run;
/* Copy the key map of DEFAULT to the data set TEMP */
proc gkeymap name=default
out=temp;
run;
/* Create data set NEW, used to create a keymap for the */
/* character conversions */
data new;
from='@';
to='b8'x;
output;
from='*';
to='d5'x;
output;
run;
/* Sort data set NEW by the FROM variable and update */
/* the data set TEMP with the coverted characters */
proc sort data=new;
by from;
run;
data temp;
update temp new;
by from;
run;
/* Create a new key map from the data set TEMP */
proc gkeymap name=mykeymap
data=temp
keymap;
run;
/* Specify the key map */
goptions keymap=mykeymap ftext=swissb ftitle=swissb
htext=5pct htitle=5pct;
/* Print titles with the special characters */
title1 'Kaiserstra@e';
title2 'Sa*o Paulo';
proc gslide;
run;
quit;
These sample files and code examples are provided by SAS Institute
Inc. "as is" without warranty of any kind, either express or implied, including
but not limited to the implied warranties of merchantability and fitness for a
particular purpose. Recipients acknowledge and agree that SAS Institute shall
not be liable for any damages whatsoever arising out of their use of this material.
In addition, SAS Institute will provide no support for the materials contained herein.
This sample uses PROC GKEYMAP to modify multiple characters in an existing key map.
Type: | Sample |
Topic: | SAS Reference ==> Procedures ==> GKEYMAP
|
Date Modified: | 2011-04-05 11:13:30 |
Date Created: | 2005-05-23 14:15:11 |
Operating System and Release Information
SAS System | SAS/GRAPH | All | 8 TS M0 | n/a |