1994-06 a review of agss: a graphical statistical system · tisements for language s+, a very...

7
Calhoun: The NPS Institutional Archive Faculty and Researcher Publications Faculty and Researcher Publications 1994-06 A Review of AGSS: "A Graphical Statistical System" Lewis, P.A.W. http://hdl.handle.net/10945/38281

Upload: others

Post on 24-Nov-2020

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: 1994-06 A Review of AGSS: A Graphical Statistical System · tisements for Language S+, a very extensive graph- ical statistical package, and for Minitab, SAS, etc., but again, nothing

Calhoun: The NPS Institutional Archive

Faculty and Researcher Publications Faculty and Researcher Publications

1994-06

A Review of AGSS: "A Graphical

Statistical System"

Lewis, P.A.W.

http://hdl.handle.net/10945/38281

Page 2: 1994-06 A Review of AGSS: A Graphical Statistical System · tisements for Language S+, a very extensive graph- ical statistical package, and for Minitab, SAS, etc., but again, nothing

and the APL interpreter executes it as an expression and returns the result in the same vari- able. Your callback routine can be doing other things while APL is mulling over your expression. The sample C code that does this is not distributed, but I think IBM will make it available soon.

An even simpler way of using Motif is possible if the application is going to run from the APL2 environment. You write the C code that utilizes Motif as a stand-alone process and get to it with DNA or wi th AP100 (or the supplied HOST func- tion). The disadvantage here is tha t the C code will grab the focus unti l its window is closed. This may be the effect you want , say, to force the user to answer a quest ion or make a se lec t ion before moving on.

I t h ink the r ight choice was made by not t ry ing to shove Mot i f into the product . MIT and the X-consor t ium and o thers will cont inue to update X-Windows and IBM would be ca tching up all the t ime. Also, APL2 doesn ' t have any par t i cu la r advantage t ry ing to repl ica te C code. Jus t witness the gyra t ions t ha t the D E M 0 1 4 tt workspace has to go th rough to use Xlib, the lowest layer of X-Windows- -over 100 l ines o f APL2 to wr i te H e l l o W o r l d .

Sharing Across Systems APL2 allows you share variables with process-

ors on remote systems connected by TCP/IP. This works for all of the AP's that are supplied with the workstation products, and it works between the workstation and most of the AP's on a mainframe --but the gotcha is that on the mainframe, the older ones, like APli0 in CMS or AP210 in TSO, were impure. But no matter--you may want to use a cover function in either case. IBM supplies two, one in APL2 and one in C. This APSERVER is a function that runs on the other side; it needs the names of four other functions which you can supply--one for initiation when a share is offered, one for processing when a shared variable is speci- fied, one when it's waiting around for something to happen, and one to use when a share is retracted. Samples of these functions are also supplied and A P S E R V E R has defaul t behavior in any case. I f you were t ry ing to cover AP110, for example, when a share comes across the network, your ini t ia t ion func t ion could share a pair of var iables with the rea l 110 processor (making names up from C, D, his var iable name and processor id). Later , when he specifies, you r process ing funct ion gets called and you can use 110 to open, close, read, wri te , check author iza t ion , whatever , and r e t u r n data or control values or both in his shared variable. You may wan t to put some logic in this server machine to slim down wha t you have to send across, since TCP/ IP isn ' t a data channel . There are a few other detai ls l ike s ta r t ing the por t server and supplying

processor profile entr ies , all wel] descr ibed in the User 's Guide. When you are finished, one s e rve r workspace can supply all the AP110 data for all o f the worksta t ions . This looks l ike a ve ry simple, non- t raumat ic way to ease a use r popula t ion over to the Unix env i ronment .

Conclusion Buy, is the recommendation, especially on Sun

where it only costs $1500., regardless of machine size, or on the IBM PowerPC, where it is currently only $1050. The RISC Systerrd6000 and PowerPC line is processor-size priced, but I expect this will be repriced soon to bring it into line with the APL2 for Sun product. The ruggedness of the system makes it a good choice for a production environ- ment, where I would be reluctant to recommend any PC APL product. Of course there was a list of things it would have been nice to see in the prod- uct, but as you use it, you add a filter here, a Motif application there , and the list gets shor t . •

A Review of AGSS: "A Graphical Statistical System"

P. A . W. L e w i s Depar tment of Opera t ions Resea rch

Naval Pos tg radua te School Monterey , Cal i fornia 93943 USA

Tel: 408-656-2283 E-mail: [email protected]

You can pick up the S I A M N e w s and you will find it full of adver t i sements for graphical applica- tions packages like Mathemat i ca , GAUSS and MATLAB, and for p rogramming languages l ike C++, but nothing on APL2 or appl icat ion packages based on it. Similarly, look at a S ta t i s t ics J o u r n a l l ike the American Statist ician and y o u will see adver- t isements for Language S+, a ve ry ex tens ive graph- ical s tat is t ical package, and for Mini tab, SAS, etc., but again, no th ing r emote ly smack ing o f APL2. To anyone who knows the power o f APL2, for example for data manipulat ion, th is is distressing.

For tuna te ly there is some hope in the form of a sadly neglected and unhera lded APL2 based pack- age called AGSS---A Graphical Statistical S y s t e m - - which runs at p resen t under IBM's APL2 p r o d u c t on mainframes, works ta t ions , and micros. Also, according to a speaker f rom IBM at a r e c e n t meet- ing of the APL Bay Area User ' s Group (APLBUG), it will eventua l ly be re leased unde r the new IBM APL2 products r e c e n t l y announced for micros run-

2 8 June 1994 - Volume 24. Number 4

Page 3: 1994-06 A Review of AGSS: A Graphical Statistical System · tisements for Language S+, a very extensive graph- ical statistical package, and for Minitab, SAS, etc., but again, nothing

ning under OS/2, for RISC Systern/6000 systems and Sun SPARCstations, as well as for mainframes.

A G S S is the subject o f this review. I have been associa ted wi th the AGSS projec t

in IBM re s e a r c h for t en years and we have used AGSS dur ing t ha t t ime for r e s ea r ch and teaching in the Opera t ions Research Depa r tmen t a t the Naval Pos tgradua te School in Monterey , California, under a jo int tes tbed ag reemen t wi th IBM Research. Ori- ginally AGSS was an in terna l p roduc t in IBM under the name GRAFSTAT, but two years ago it was re leased as an "AISPO" ("as-is so t tware pro- ducts and offerings") p roduc t by IBM. I was actu- ally somewhat in s t rumen ta l in get t ing this re lease because we were faced wi th the fact t ha t while our s tudents almost un iversa l ly p re fe r red AGSS for sta- t ist ical work, data analysis and graphics, they could not obtain it aRer leaving the School. It was there- fore in our in teres t , i f we were to cont inue teach- ing wi th it, to have it available to our s tudents al%er graduat ion .

Let me say first o f all t ha t AGSS is clearly competi t ive in faci l i ty and conten t wi th o the r high- end, extensible s ta t i s t ics and graphics products like Language S+, MATLAB and GAUSS. Al though all of these packages have extensive graphics capabili- ties, none of these appl icat ion languages have iden- t ical contents_ B u t what sets A G S S aside from other application languages is that its macro lan- guage and its local function language are all the same as the language it is written in, namely APL2, and that the power o f that language is fully useable in A G S S . In fact AGSS extends APL2 because its myriad of built-in funct ions extend the computing env i ronment in exac t ly the same way as is done with built-in funct ions in packages like MATLAB and Language S+. This fact alone should make APL2/AGSS the package of choice and a delight to anyone versed in APL2_

AGSS is menu-driven, with the four pages at the top level conta in ing the following overal l topic headings:

• Basic graphics functions • Catalogs • File interfaces • Exploratory data analysis and descriptive statistics • Reliability analysis--distribution fitting • Accelerated life testing • Regression analysis • Design and analysis of experiments • Quality control • Time series • Table functions • SQL interface

The coverage wi th in these groupings is vast; for instance, under the topic of "BASIC GRAPHICS F U N C T I O N S " one finds, amongst o thers , the fol- lowing input screens:

Plot Scatter plot (with curve fitting)

• 3-D contour plot • 3-D surface plot • 3-D contour/surface plot • 3-D trajectory plot • 3-D scatter plot • 3-D parametric Y-Z plots • Surface fitting

Under "REGRESSION ANALYSIS" on the third page of the menu one finds M u l t i v a r i a t e Scat- ter Plots, Lifetime Regress ion, L inea r Regress ion , Nonl inear Regression, Robust Regress ion and Ridge Regression. The coverage o f the field o f r e g r e s s i o n analysis and the quan t i ty o f s t a t i s t i ca l me thodo logy encompassed is s taggering.

The re is also a full sui te o f "bus iness g raph ics" screens with such descr ip t ions as " F I L L E D PLOT," "HISTOGRAM," "BAR CHART," "PIE CHART" and "SKYSCRAPER PLOT." These are general ly sneered upon by s ta t i s t i c ians , b u t a re nev- er theless widely used by invoking, for example , Har- vard Graphics. Why would one wan t to use t h e m here in AGSS instead o f in H a r v a r d Graph ics? The answer is simple; the access to the APL2 language in AGSS makes for da ta man ipu la t ion in the inputs to the procedures which one would on ly d r eam of in Harva rd Graphics.

But, besides the extens ive l ist of g raph ics and stat is t ics funct ions implemented in AGSS, the real genius o f A G S S is the full-screen interface to plot- ting and statistical procedures which are accessed at the next level of the menu. Thus , F igu re 1 shows the first page of the menu, and the f i r s t e n t r y ( "PLOT") gives the inpu t s c r een shown in F igu re 2 which with the filled in i tems, gives t he o u t p u t shown in Figure 3.

The output in Figure 3 is a s imple mul t ip le plot of the powers o f x, x •, aga ins t x to i l l u s t r a t e plot- t ing to a beginning s ta t i s t ica l g raph ics class. The input sc reen in F igure 2 i l lus t ra tes all o f the capa- bilities associated wi th the inpu t sc reen . You may note in pa r t i cu la r f rom the " X - A X I S L A B E L ( I N Q U O T E S ) " e n t r y t ha t the color, size and dis- tance from the axis o f the X-axis label is con t ro l l ed by three ent r ies aRer the ac tua l label. T h e va lues 8 for the size o f the label and 2 0 0 for i ts d i s tance from the x-axis are ob ta ined i n t e r a c t i v e l y by t r y ing different values and p lo t t ing the r e su l t i ng f igure wi thout eras ing the previous one. T h e " P L O T HEADER ( I N Q U O T E S ) " e n t r y shows the mini- word-processer available for all labels; sub, supers and, for example, Greek l e t t e r s and m a n y o the r alphabets and sets o f symbols are avai lable in AGSS.

A r ecen t con t r ibu to r to one o f the A P L bu l l e t in boards called this s c r een in te r face "barbarous," bu t he had plainly never used ACGS8 or he would neve r have t r ied to fit i t in to his p r o c r u s t e a n Windows

APL Quote Quad 29

Page 4: 1994-06 A Review of AGSS: A Graphical Statistical System · tisements for Language S+, a very extensive graph- ical statistical package, and for Minitab, SAS, etc., but again, nothing

T~m.I[ OF ~iTIDqTS -

EMSIC I ~ F X H I ~ F U N C T I ( ~ PLOT W;IIT£ 3 - 0 CON¥OJR PLOT 3-D ~.IHF~C( PLOT 3 - 0 C~I, ITO.IR/~JJRFAI~ PLOT .3-0 "m.AJECTORY PlOT LEGGqD N ( I S CGN'IRGL F I L L e ) PLOT DEFNJLT COL(~ I N~

~ , ' I ' A L ~ CmnROL VEC~RS USER WAR INBL(S ~ S FILES OLkq I ES OEM) N~O 0 m I T FIL,I~

P~I~E I OF 4

5cA'r[(]q PLOT (WITH ~ F ' i 1 " r l l ~ ) CURVE FITTING 3--D sCKrTB~ PLOT 3 -0 FI"I-rlIqC/IEM=II~IICAL .~.IRF.q~ PLOT 3'-0 P , ~ T R I C Y-Z PLOTS POINT 1DOLT IFICATION DR,W/ IM.'TRI~ DI,SPI.AY D I kqy/CRAF'F" I L(/JOURNAL ON/OFF P LOT/~:R(E~I I'X]NiT I FICAT ION

~ S CIq,NJltlII~ FUNCTIQI6 USE1R F'UNCI"I ~ CK41~41CS F ' IL(S. APL ~t~ AND FIt .E~ J~5S FUIICTIC~II/VARI~diLE LIERA.qY

FOR PAGE3 2 -4 IqJ~.l PF B

TO ~ E ~ FUNCTION. POSlIrI(),I ~ AT FtJNCTI(~I ~ AND P R ~ E~lnrl~. I:'Oq FtJkCTION DESCRIPTION. P051TION CIJRS(~ AT FUNCTION NAG N~O PLJ~4 PF1.

PLOT FLJI~T I ON

]1 VARIaBLE(S) : ] l g - - ( - - 1 4 - t ( N N t - 1 ) ) - ~ - ~ V VN i l ABLES(S) : H ; XX-O . ~ ; NN • ~ .3 : ~ - ~ . O TYPE(S) OF PILOT : O I 1 1 TYPE( ' ) OF" LINE : 1 3 4 : I ~ ]EN , BLUE .I~.IRQIJO'~ TYPE(S) OF ~ 1 . : - ; l ~ PLO'Ir IF.N)tE~ ( IN IQuD'r[s) : 'Powerm mr S - I l l ' T - I | a~- ,~_ f a r " 10 o ~ ' . ' ~ @ . S . ~..

3 . 15 .O ' ;YELLO/ / ;8 ..~ . ~ES~ l ~ ( IN QUO11[S) : ' ' 1 8 D m n m t r a t l o n o f P l o t r u n © [ ; a n ' ; l f l l n [ ; 1 2 20

X-ANIS I..,~IO. ( I N ~DT~S~ : ' X ' ; . i ' n [ ; , 2 ~ Y-ANIS L#m[L ( I N 'Y ,mN ' r ' IEm ' ; t tH ITE ;8 200 I ~ IT IOq : I S,/-LE X-kMIS : L IN 0 1 SCALE Y-AXIS : L IN 0 I PARTIJU. PLOT : 1 I 1 AXES N 4 ) ( ~ I D Cl[~Ill~)L : 0 1 0 0

ENTEI~a3 CLENiaOEF4UL¥

PF: ImHEI.P 2~VIE3~ ~ P H I ~ ~ 4~AiRITE I ~ S [~EDi

IO~STIDI~.,/RETqlEVE I I - - I K I O NPL 1 2 ~ ' L ~1"1(316

Figure I. The first page of the AGSS menu.

bed. In fact, not only is every entry (with some ]imitations) a programmable APL expression, but all entries have help accessed via F1. In fact the menu and the additional entries below them on the screen form a natural differentiation of the help topics so that when you use F1 to get help on, say, the " X - V A R I A B L E " entry for a part icu lar screen , the he lp is a b s o l u t e l y germane to that entry and so is "context sensitive." The Help s c r e e n for the " X - V A R I A B L E " entry is s h o w n in Figure 4. N o t e that on e can e v e n use APL funct ions in the entries_

P r e s s i n g Enter in i t iates the p r o c e s s i n g o f the en tr i e s on the input s creen and resu l t s in graphica l output , s u c h as in Figure 3, on a graphics s c r e e n w h i c h can be i n v o k e d u s i n g "F2 - - VIEW GRAPHICS" on the A l p h a n u m e r i c input screen .

Addi t iona l (usual ly common) ac t ions for e a c h screen are on the function keys (see Figure 2---a nice touch is in "F12 -- (ADD'L ACTIONS)" where one possibility is to selectively erase any of the graphs on the graphics screen, which alternates with the aIphanumerical screen shown in Figure 2.)

Also one can move to APL2 and the Session Manager via F11 to try out the intended entry or to browse back through the Session Manager for previous work or to bring in more data or files. This easy access to APL2 whilst in a input screen is a great plus for the system. Return to the cen- tral point of the input screen is via F3.

An important point to make here is that the f i l l e d in i n p u t s c r e e n c a n b e s a v e d (F10) a s an A P L v e c t o r a n d s u b s e q u e n t l y e d i t e d a n d i n c o r - p o r a t e d i n t o A G S S G r a p h i c s f u n c t i o n s . T h e s e m a c r o s a r e j u s t A P L 2 f u n c t i o n s a n d h a v e al l t h e p o w e r a n d f u n c t i o n a l i t y o f A P L 2 a v a i l a b l e in t h e m .

As two examples of the of the capabilities of these screens, consider the PLOT and "SCATTER PLOT ( WITH CURVE FITTING)" screens at

Figure 2. The PLOT screen for Figure 3. This is stored as a Control Vector , a special APL vector with delimiters and the number of the screen at the beginning. Note the com- plete control one has over the color and size and distance from the screen oF all entries .

the top o f the first page o f t h e m e n u s h o w n in Figure 1.

In the PLOT screen , the "X-VARIABLE" and " Y - V A R I A B L E " data can be A P L v e c t o r s , or APL2 funct ions w h i c h g e n e r a t e data; for m u l t i p l e entr ies the x and y pairs are s e p a r a t e d f r o m s u c c e s - s ive x and y pairs by s e m i - c o l o n s . In a d d i t i o n a s ing le x- input can be p lo t t ed a g a i n s t t h e s e p a r a t e c o l u m n s o f a matr ix en tered as the y en try .

T h i s type o f input capabi l i ty l eads to t h e fo l low- ing l o v e l y pedagog ica l example . T h e A G S S f u n c t i o n for g e n e r a t i n g m i n d e p e n d e n t n o r m a l (0,1) r a n d o m variables is M NORRAND (/~,~). Thus, let If00 be the "X-VARIABLE" entry in the PLOT screen, and let +~ I00 5p 500 NORRAND 0 1 be the "Y-VARIABLE" entry. This generates five normal random walks and the color and line type of each can be varied to differentiate the walks. (In fact the color control in AGSS is the best I have ever seen in any package; again, it is on-line in the input screen. ) P r e s s i n g F3 r e t u r n s o n e t o the a lphanumer ic s c r e e n and i f one p r e s s e s F6 to e r a s e the g r a p h i c s s c r e e n and t h e n E n t e r ' s aga in , the graphics s creen reappears w i t h a n e w se t o f r a n d o m walks . (This is b e c a u s e the r a n d o m n u m b e r g e n e r a - tor k e e p s go ing un le s s reset . )

As the s econd example , l o o k a t th e "SCATTER PLOT (WITH CURVE FITTING)" s c r e e n in the top right in Figure I. This screen is a sleeper. At first look it is a clone of the PLOT screen, but without the ability to do multiple plots, although a s e l e c t i o n poss ibi l i ty , the entry- "SELECTION VECTOR( S )," is n o w avai lab le . N o w , ai%l~r a p lo t is done , F7 a c c e s s e s the curve - f i t t ing s c r e e n , and w h a t a r i c h n e s s is there . One c a n ~ t p o l y n o m i a l s , s inuso ids or n o n l i n e a r f u n c t i o n s o f x to t h e d a t a by

3 0 June 1994 - Volume 24. Number 4

Page 5: 1994-06 A Review of AGSS: A Graphical Statistical System · tisements for Language S+, a very extensive graph- ical statistical package, and for Minitab, SAS, etc., but again, nothing

Demonstration o [ Plot Function P o w e n o ! • - - - l " fmr • = 0.5. 2.$. 16 .0

j J_ . . . . . . . ~ i I I I I l - J

0.0 0.4 0.0 0 . | |.O

)1

Figure 3. An example or" the use of the PLOT screen. This simple multiple plot is used to introduce students to the use of the PLOT screen. Note the legend, accessible via F7 in the input PLOT screen, and the different line-types and colors of the plotted lines.

least squares or robust least squares. One also has the choice of spline fitting and nonparametric smoothing with LOWESS (locally-weighted scatter- plot smoothing). After the fit has been done, appro- priate statistical tests and results are given on the table screens. What I would have given in Engi- neering School or during graduate studies in Statis- tics for such a screen.

Remarkably, there is more to the "SCATTER PLOT" screen. Since the size, color and symbol for each plotted x,y point can be controlled, the " S E L E C T I O N V E C T O R ( S ) " inpu t and the avai l - able A P t 2 log ica l exp re s s ions a l lows one to p roduce the coded s c a t t e r p lo t s w h i c h are one o f the bes t w a y s o f p r o d u c i n g p lo ts o f h ighe r d i m e n s i o n a l (up to five) da ta .

I f t h i s A G S S p a c k a g e is as good as I say i t is, w h y do A P t peop le s e e m to shy a w a y f rom it? One e x a m p l e o f th i s " s h y i n g a w a y " is t h e r e c e n t I B M S y s t e m s J o u r n a l i ssue c e l e b r a t i n g the 25th Ann ive r - s a r y o f A P t . I was f l abbe rgas t ed to see no p a p e r on AGSS, or on i ts use. S imi la r ly , t he r e c e n t I B M a n n o u n c e m e n t o f t h e i r n e w APL2 p r o d u c t s shows a g r a p h g e n e r a t e d by G R A P H P A K ; y o u cou l dn ' t even s t a r t to c o m p e t e w i t h M A T L A B us ing j u s t G R A P H - P A K , b u t t h e A P L 2 / A G S S c o m p u t i n g e n v i r o n m e n t wou ld be c o m p e t i t i v e w i t h a s y s t e m l ike M A T L A B . So w h y i s n ' t I B M m i n i n g AGSS for all i t ' s w o r t h to sel l A P t 2 ?

One l ikes to t h i n k t h a t i t is s imply t h a t s ince t he A P t 2 peop le a re no t in s t a t i s t i ca l or m a t h e m a t - ica l app l i ca t i ons , t h e y h a v e n ' t had the o c c a s i o n to r e a l l y use AGSS; I h a v e m e t and c o n v e r t e d some o f t h e s e b l ind people . A n o t h e r r e a s o n for the neg lec t

X ¥&qldlBLE(S): A ee l of • c G o r d l n a l e s e n t e r e d as an ~ numer i c vm=~or . Thor i n t r y mDy be any ~ empreas lan ~ n l a ama©ut lon gonmrotom a mdweri© r e = t a r . . S m l o aaoTpleo o | p e r m i s s i b l e a ' ~ t r i a a orB:

A) 1.1 3 4 .7 B g D) DATA r i o

F%JNCT Imi ~ ¥ A

whare thm e n t r • A r e a u | t a i n the p l o | t l n g a f t ha mor rmml~nd lng Y v a r i a b l o mml.r|am u g o i n a l the p o e i i l v a I n L q w r w . 'DATA' l e the rtaws o! an APt. numer ic v e c t o r m d 'FUNCTION' Im on /tPL f u n © t | o q which g a n m r a t N an APL humer i© v ~ t o r .

IF t h e r e Iw Jmrm than one © e a r d i n o | a mat. a n t r l e w s h o u l d be ampara |uJ by wemioolonw. For waOVlple. K1;1 2 3 : A : X 4

Citer the @ a a c r i p i ; o n a | m c h a r a c t e r v e c t o r o l t e r n o t i l m , m©ro l l v ; o P F I _ ) DE~ILILT: Any da| imad APt ore©tar nolvwd • .

INPUT kUl, l r E EZqlllc.ltJI] [ IT I 'ER EEl.O# ~ (]14 PREVIOUS

PF2-OEFMJI.T ~ , ~ IN /IPL ~ IqESPI]~E~ 7 - ~ . L UP ~ OOW4 IE~'IE]~=~IETi.~_/Pl~ EV I OJS

Figure 4. The Help Screen for the X-VARIABLE entry in the PLOT screen, reached by placing the cursor on the X-VARIABLE entry position and pressing FI .

s eems u n f o r t u n a t e l y to be t h a t A G S S is n o t "~ure" A P t 2 . For e x a m p l e , d i f f e r e n t " Y - V A R I A B L E ' " i npu t s in t he P L O T s c r e e n a r e s e p a r a t e d b y semi - colons, w h e r e in p u r e A P L 2 t h e y m i g h t be n e s t e d a r r a y s . E v e n i f t h i s w e r e d e s i r a b l e - - a n d a n a rgu- m e n t cou ld be m a d e t h a t i t i s n ' t - - n o one is l i k e l y to i nves t the t i m e and m o n e y in to A G S S to do th i s . A n d i f t h e u s e r s t i l l i n s i s t s , i t is p o s s i b l e t o w r i t e A P t 2 f u n c t i o n s t o a l l o w t h e u s e r t o u s e p u r e A P t 2 in t h e p r e s e n t c o n t e x t . A l s o one can use A P L 2 p r o g r a m m i n g t echn iques in the screen entries as long as the f i na l i npu t to the p a r t i c u l a r par t o f the screen con ta ins no A P L 2 s ym b o l s or nested arrays.

An e x a m p l e o f th i s use o f A P L 2 is to a p p l y a F I L T E R , a v e c t o r o f n u m b e r s w h i c h add to one, to a t ime s e r i e s s t o r e d in T S E R I E S , so t h a t we can, for example , s m o o t h i t o r b a n d - p a s s it. T h e n t h e " Y - V A R I A B L E " i n p u t is g iven b y

(cFILTER) +.x'" (pFILTER) , / TSKRIES

The lazy way to generate the "X-VARIABLE" input , is g iven as

( c( pFILTER )/÷pFILTER ) +. x"( pFILTER ), / *pTSERIES

Robust smoothing using running medians, etc., is done in exactly the same way.

To return to the neglect of AGSS, another reason for this denigration of AGSS is that people who have not really used it say that "there are lots o f good A P t 2 g raph ic s f u n c t i o n s a r o u n d . " T h i s c a n be seen in the A P L 2 p r o d u c t a n n o u n c e m e n t , w h e r e as I sa id above, G R A P H P A K is t o u t e d r a t h e r t h a n AGSS. I n t en y e a r s o f u s i n g A G S S a t N P S I h a v e y e t to see a n y o n e who , fo r s imp le p lo t t ing , w o u l d choose a su i t e o f A P L g r a p h i c s f u n c t i o n s o v e r AGSS. And o f c o u r s e i f s o p h i s t i c a t e d s t a t i s t i c a l p r o c e d u r e s a re a lso n e e d e d be s ide s the g r a p h i c s , AGSS is the o b v i o u s cho ice . W h e n I see one o f

A P t Quote Quad 31

Page 6: 1994-06 A Review of AGSS: A Graphical Statistical System · tisements for Language S+, a very extensive graph- ical statistical package, and for Minitab, SAS, etc., but again, nothing

these references to GRAPHPAK I go back to the GRAPHPAK manual to see if I have missed any- thing, and believe me, I haven't.

Off-line documentation for AGSS is good, despite the fact that the on-line helps really do make it almost stand-alone. There is an overall 94- page i n t roduc t i on to AGSS en t i t l ed "A Graphical Statistical System (AGSS): A n Introduction," for wh ich the g raph ics sc reens are avai lable on-line.

S imi lar manua l s exis t for Regress ion Analysis , T ime Ser ies Analys is , Rel iabi l i ty Analysis , Qual i ty Cont ro l and Design o f Exper iments .

Access to AGSS func t ions is only fa i r - - - there is a ve ry wel l - implemented ca ta logue o f AGSS func- t ions wi th a s e a r c h faci l i ty. The prob lem is t h a t t h e r e are many AGSS func t ions which are no t l is ted in the ca ta logue and an a t t empt wh ich w a s made to b roaden the index of funct ions has neve r been implemented . For example , t he re is a nonlin- ea r opt imizer w h i c h is used in the non- l inear r eg re s s ion in AGSS. My PhD s tuden ts and I have found it b e t t e r t h a n any o the r package we t r i ed w h e n s tudy ing non- l inear cont ro l s for Var i ance Reduct ion . On a s impler level t he r e is an AGSS func t ion TO which is no t in the cata logue. Thus, for example , 3 TO 5 gives the sequence 3 tt 5. I t is equ iva l en t to the func t ion 3 : 5 in Language S+.

Ou tpu t o f g raph ics is good too, via Pos tSc r ip t files and an IBM method for s to r ing graphics files on disk---this l a t t e r faci l i ty is pa r t i cu l a r ly helpful in t each ing . Graphs can be p repa red ahead of time.

Improvements and Lacunae There are many improvements to this already

extensive package which could be implemented. A few major ones are given below.

1. It would have been nice to have a set of screens for multivariate statistical analysis, and also for contingency table analysis. These can be implemented as AGSS Graphics functions, but they then lack the utility of the interface screen with its on-line helps.

2. GLIM (Generalized Linear Models) should be added to the already fine set of Regression tech- niques provided.

3. The scope of the initial PLOT screen can be considerably broadened by allowing the " X - V A R I A B L E S " inpu t to be a mat r ix whose co lumns are to be p lo t ted aga ins t co r responding co lumns in the " Y - V A R I A B L E S " input matr ix . A simple example o f the u t i l i ty o f this approach is to cons ider d rawing an empir ica l d i s t r ibu t ion func t ion for a se t o f da ta (X1,---, X~). The func-

. 1 t i on ,nc reases by -K- at each o f the o rdered

va lues o f the data. Now we requi re t h a t the

rises be in dashed lines, the flats be solid. This is difficult without the matrix input, and a triv- ial reshaping of the ordered data set with the double matrix input capability.

4. A little bit of color would improve the human factors aspects of the input, screens. Thus, one could put textual entries in a different colors, as well as the F-keys.

5. The 3-D plotting screens would be better if the X-Y grids were defined-before the function was executed. Then the matrix form of the surface could be more easily employed.

6. In such an extensive package, access to all the functions and functionality must be a problem worth thinking about. Thus, it is difficult to find box plots. A more extensive catalog of functions (and procedures) would help, or a Kwik-index.

7. Input and output facilities in AGSS are really antique. One can read in ASCII files, but not comma-delimited files. Similarly output tables are basically character matrices because of the original use of plain APL, and this makes it dif- ficult to get information out in the right form. Nested APL2 arrays would be better, but failing this one can export the character array table to our input/output editor, UEDIT (APL Quote- Quad, Vol. 23, Number 3, March 1993, pp. 9-14) and convert it to the desired form. In fact UEDIT was designed to supplement AGSS in this and other ways. For instance it has the categorical data facilities which AGSS lacks.

8. The Design and Analysis of Experiments section needs to be expanded to more than two level designs.

9. IBM's support for AGSS is my greatest concern. The chief architect of AGSS, Dr. Peter Welch, has retired, though he is still around IBM Research on a contract basis. Dr. Martin Schatzoff, who, along with many others, put in the guts of the program, has also retired. Hope- fully the APL2 people will take over the AGSS product and provide user support for the APL2/AGSS package. The first thing they should do is to create a bulletin board for post- ing and sharing AGSS Graphics functions. This would put them on a par with, say, Language S+ in at least one respect.

On a broader level, it seems to me that IBM has shown a great deal of short-sightedness about the market for APL2 and AGSS. This comes from the prejudice about ACG,~5 which I discussed above.

In this vein, at the Naval Postgraduate School we have about sixty active AGSS users, and maybe three people who really know APL2 and use it inde- pendently of the AGSS package. I think that this

3 2 June 1994 - Volume 24, Number 4

Page 7: 1994-06 A Review of AGSS: A Graphical Statistical System · tisements for Language S+, a very extensive graph- ical statistical package, and for Minitab, SAS, etc., but again, nothing

situation is typical of institutions I know and con- sequently I think one can say that while its use of the APL2 language should sell AGSS to expert APL2 users, it is AGSS's use of APL2 which will really sell APL2. Along these lines we now teach the APL2 language to students at the Naval Post- graduate School as part of the APL2/AGSS comput- ing environment. Extensive notes for this purpose, ent i t led "Teaching and Learning Statistics with the APL2 Program A G S S and Learning APL2 on the Side," are available on request .

As for the future , I hope tha t IBM will con- t inue to support the APL2/PC product which runs AGSS on microprocessors under DOS. There are problems with this APL2 interpre ter , namely memory handling for ve ry big data sets, but in gen- eral, i t is an excel lent product . In developing the input /output edi tor UEDIT, we have staked our hopes for be t te r memory management on the OS/2 vers ion of APL2 and the promised OS/2 version of AGSS. However , our measurements of the speed of APL2OS2 against t ha t of APL2/PC showed that one is paying a price for a windows envi ronment with a six-fold reduc t ion in computing speed! This may well be a funct ion of the memory and swapping configurat ion of OS/2 which is in use. Adjusting this, and improvements in the APL2OS2 product, hopefully will give acceptable performance to APL2OS2, and consequent ly to a new version of AGSS. In the meanwhile , one might want to stick to the original vers ion of APL2 for microcomputers and to the cur ren t AGSS.

Finally, let me close by with some recommenda- t ions for s tat is t ics programs for filling the gaps in AGSS when using it. I have mentioned UEDIT, which is still be ing act ively developed, and which fills the gap in ca tegor ical data analysis. The gap in GLIM is filled by the very fine "Regression and Generalized Linear Models Volume--ASLGREG" package, which is a she l f in the APL Statistics Library put out by the Bri t ish APL Association. The au thor is Dr. Alan Sykes ~om the European Business Management School in Swansea, U.K. It is very well implemented.

Another in te res t ing package is the APL2STAT package devloped by Michael Friendly and John Fox at the Univers i ty of York. Besides showing how APL2 can be used in modernizing the APL2 milieu, this package is strong on multivariate tech- niques, which are in short supply in AGSS.

At a basic level there are the various versions of the British APL Association Bottom Shelf. These are all written by Norman Thomson and are all first class. The original one cssentially the Statistics workspace in TryAPL2--is very useful. A good package for exploratory data analysis (EDA) is available from us at the Naval Postgraduate School.

The AGSS for APL2/PC DOS package is avail- able by dialing 1-800-1BM-CALL (1-800-426-2255) and

asking for Program number 5764-009. The price is $250. One needs APL2/PC as well and this cur- rently lists for $630, despite an earlier sale price of $189. Ask for Program number 5799-PGG (PRPQ@ RJ0411) at the same telephone number. The price is steep, but there are an incredible number of aux- iliary processors and applications workspaces which come with it.

Conclusions In conclusion, then, APL2/AGSS is a very pow-

erful statistics, mathematics and graphics comput- ing package which will run on the smallest 386-microcomputer with a numeric coprocessor and at least four megabytes of random access memory and on the largest IBM-compatible mainframe. At the Naval Postgraduate School, since the smart money knows that mainframes are dead, APL2/ AGSS on the under-utilized mainframe with work- spaces up to 999 megabytes is the most formidable data analysis environment available any'where. Almost the full power of the interactive APL2 pro- gram is available to the AGSS user, and in my opinion, this sets it above other similar packages where the mathematical substrate seems to be a large afterthought which is built as the package expands. One hopes that the APL2 community will embrace AGSS and perhaps help to ensure the future of APL2. They won't be sorry. •

Book Review: APL Notes by Jim Weigang, Fourth Edition

As reviewed by

Robert Wil lhofl 1320 Main S t r ee t

Vestal, NY 13850 USA Tel: 607-752-5964 office Tel: 607-748-8386 home

E-Mail: willhoft@acm, org

Being asked to rev iew this book b r o u g h t back memories o f when I learned APL using on-line lessons and r'APL: A n Interactive Approach" by Gilman and Rose over f if teen yea r s ago. Al though formal t ra in ing followed later , much of wha t I know about APL I learned from these sel f - teaching aids. "APL Notes" by J im Weigang follows in this tradi- tion.

"APL Notes" was developed over at leas t twelve years from teaching APL in l inear a lgebra classes at the Univers i ty of Massachuse t t s . I t is designed to complement an APL re fe rence manual . "APL Notes" comes with eve ry th ing you need to pu t APL

APL Quote Quad 33