Environment for creative processing of text and numerical data

Home  |  News  |  Publications  |  Download  |  Flash

Seppo Mustonen (June 18, 2001):
New Windows version of Survo

SURVO MM is the new Windows version of Survo. The new SURVO MM is compatible with SURVO 84C and SURVO 98. The editorial interface and the file structures are identical. SURVO MM includes many new features. The user now has even better ways to utilize the possibilities of Windows both in management of jobs and specially in graphics.

SURVO MM provides a versatile working environment e.g. in following applications:

By using the general macro language of Survo (available already in earlier versions) the users have created large applications related to various research fields and commercial tasks. In such applications SURVO MM is unique in cost-effectiviness.

  1. How SURVO MM was developed?
  3. Wider views
  4. Graphs as metafiles
  5. Structure of SURVO MM
  6. Lowering the threshold
  7. How to get acquainted with SURVO MM?
  8. HELP window
  9. Contributors to SURVO MM
  10. Installation of SURVO MM
  11. Survo glossary

How SURVO MM was developed?

As data processing system Survo has an exceptionally long history. I started preliminary planning of the first version already in early 1960s and the first implementation (SURVO 66) was available in 1966.

In 1975-6 I programmed SURVO 76 for Wang 2200 minicomputer. It was probably the first truly interactive statistical software package in the world. When demonstrating this new system some experts claimed that "it is merely playing with the computer" or "we shall never need interactivity in statistical data processing".

At the end of the developing stage of SURVO 76 (in 1979) I got the idea of the editorial working mode on the basis of a music printing program that I made for my son Olli Mustonen. Editorial approach seemed so effective that it soon superseded the earlier menu-based working mode.

In the editorial working mode each task is carried out with the aid of the editor program of Survo. This program displays an edit field in the main window of Survo. The user can type, for example, computational formulas and various commands in the edit field. When the user activates a command or a computation scheme, Survo recognizes the task and calls a suitable Survo program module to carry out the task. The results will appear in the edit field and the user may continue the work by using them as any other text appearing in the edit field.

  Example: When I just now (June 7, 2001) am typing this text with
  Survo and I want to compute what is the area of a triangle with
  sides a=13, b=14, and c=15, I know that the result is obtained from
  area=sqrt(p*(p-a)*(p-b)*(p-c))  (Heron's formula)
  where p is a half of the circumference of the triangle, p=(a+b+c)/2.
  By typing the word 'area' with an '=' immediately after it and by
  activating I get the result area=84.
  (Thus the number 84 above has been computed and written by Survo.)
  Survo does not know Heron's formula. However, when area= is activated,
  it finds the expression for the area and other parameters needed
  from my text. In such a way it carries out the task by employing
  information written in the edit field.

From 1985 Survo has been programmed in C language (SURVO 84C) and much of that code is still in use in later Survo versions. SURVO 84C was running on 16 bit micros in the DOS environment. The limits of DOS were overridden in 1998 by using a DOS extender. In this way SURVO 98 became a true 32-bit system.

From December 2000 I have been wondering how a Windows version could be created. After testing various alternatives I started the programming work in May 2001 by employing ideas gathered so far.

This has been a challenging project since it is not easy to fit together divergent demands of Survo and Windows. It is a fact that typical, efficient working habits of an experienced Survo user are in conflict with typical Windows usage. It would be a disaster to have a Windows version without the most valuable features of the editorial working mode.

Before making the final solution I discussed about various alternatives with Kimmo Vehkalahti, Reijo Sund, and Marjut Schreck and got valuable suggestions and comments from them. Especially Kimmo has a significant role in developing this new Windows version.

My goal was that the new Survo should made in such a way that most of the source code in C - there is a huge amount of it - will do without any significant changes. Also the traditional user interface and data structures should be identical with those of earlier versions.

However, it was natural to consider alternative means; for example, what would be the role of the mouse, which was not used so far. After various trials it became evident that the new Survo would still be a collection of independent program modules (processes) with the editor program as the center of the system. Thus the edit field would be controlled by the earlier style but, for example, graphics would appear in other windows.

In order to make the editor to work and to spawn statistical, graphical, etc. program modules as child processes, I had to rewrite C functions for screen, keyboard, and mouse control with the aid of standard WIN32 API functions.

The new functions have been connected to the earlier program code of Survo and all modules of Survo have been compiled by Microsoft Visual C++ 6.0. Since all functions dependent on Windows environment are separated from the original Survo C code, it is easier to think later also implementations for other platforms, e.g. Linux.

At this moment all that can be done in SURVO 98 can be done similarly in the Windows version of Survo with few exceptions. For example, the edit fields and sucros (Survo macros) from earlier Survos are valid in the new version as such. Also data files and matrix files have the earlier structure. In general, all that belongs to the realm of editorial approach is fully compatible with preceding versions.

It is pleasant to notice that during the progress of the work it has been possible to get support from Windows environment more than I expected. On the other hand, several nuisances related especially to differences between Win95, 98, NT, and 2000 have been encountered.


The new Survo is called SURVO MM where - to say it by the own means of Survo - MM(Roman:10)=2000 .

Although the cursor can still be moved by the arrow keys and commands activated by the ESC key, many people have been longing for the mouse for those simple tasks. Therefore now the user can move the cursor also by the mouse and activate commands etc. by double-clicking. It is also possible use the mouse in many other ways in SURVO MM.

One can create sets of soft buttons located row-wise below the main window of SURVO MM. By clicking a soft button a task defined for that button will be carried out. Such a task may be simply typing a particular text and/or activating a command. Since commands may be calls to sucros (Survo macros), one can perform very complicated tasks by soft buttons.

There can be several rows of soft buttons below the main window thus forming sets of buttons. These sets are called "button boards" since they are like extended virtual keyboards. When the mouse touches a soft button, a legible description (up to 80 characters long) of the task of that button will appear on the lowest row. By clicking a soft button the task specified to it will be accomplished.

Activation of a soft button may also lead to a new button board where soft buttons are replaced at least partially by new ones. This takes place quietly by a sucro which activates a new SOFTKEYS command. This command referring to the name of a ready-made button board replaces the current board by another. This technique enables making of hierachical menus for various applications.

In typical Windows programs the pull-down menus etc. are fixed and the user has no opportunity to extend or alter them. In SURVO MM all soft buttons can be freely defined by the user. This happens by means typical for Survo. Any edit field may contain definitions of button boards. I believe that experienced users learn easily to make their own set of soft buttons on the basis of the ready-made button boards. When SURVO MM is started, the first button board gives hints about usage of this new Survo.

As an indication of the limitless possibilities of the new technique it is possible to use Survo merely by the mouse without a need to touch the keyboard. This happens by using a virtual keyboard which will appear as a button board by clicking soft buttons SYSTEM -> CHAR -> KEYBOARD. Although one may type and edit text in the edit field by the virtual keyboard, this may be an advantage only to handicapped users unable to operate the standard keyboard.

In the picture below, one of the ready-made virtual keyboards of SURVO MM is shown:

Picture: SURVO MM and one of its virtual keyboards
Picture in larger size

Wider views

In earlier Survos the Survo window had a fixed size (typically 23 or 48 lines and 72 columns + margins). Although 23 lines and 72 columns is still default in SURVO MM, the window size may increased (or decreased) according to the needs of the user. This is done by a new RESIZE command. For example, RESIZE 30,100 creates a window with 30 visible lines and 100 visible columns + margins. Large windows are helpful, for example, when viewing reports with long lines.

Even larger windows, say with 100 lines and 200 columns, may be good when studying wide and high tables loaded from Survo data or matrix files. RESIZE without parameters resets the default size.

The picture displays a Survo data set of the countries being browsed: (Source: Statistics Finland, World in Figures, www.stat.fi)

Picture: SURVO MM and the countries of the world
Picture in larger size

Graphs as metafiles

In plotting and desktop publishing the rich PostScript interface of Survo is the same as in preceding versions. In screen graphics (done by GPLOT and GHISTO) each plot appears in a window of its own. There can be several Survo graphics windows visible at the same time. The default setting is three simultaneous windows, but this setting can be changed easily up to 100 simultaneous windows. Having several graphic windows simplifies gradual enhancement of plots which is a typical procedure in practice. The screen plots are saved as enhanced metafiles (EMF) and therefore they are device-independent. On the screen it is easy to enlarge and move graphics windows by using the mouse. It is also possible to convert enhanced metafiles into other standard image formats without any loss of accuracy. EMF files can be used as such by many other Windows programs. The coordinate system of screen plots may be selected according to PostScript requirements. This simplifies planning of pictures before moving to PostScript plotting.

By means of sucros the user can create purely graphical applications where everything is seen in overlapped graphics windows and the main window of Survo (edit field) is hidden. To support such applications SURVO MM includes many new functions for management of graphics windows.

Below there are three graphs plotted with GPLOT schemes of Survo. The last graphics window has been moved and stretched bigger using the mouse. This simplified example shows how the picture gets its final form step by step.

Picture: SURVO MM and interest curves in three graphics windows
Picture in larger size

Structure of SURVO MM

SURVO MM is like its predecessors a highly modular system. It consists of over 100 programs written in C and of almost 700 other system files.

In the main window a part of the edit field is seen and it is maintained by the Survo editor program. The editor also invokes other Survo program modules as child processes according to the needs of the user. He/she has no need to know how the system is split into parts but sees the system as seamless integrity. Information from the editor to child processes and back to the editor is transmitted through environment variables and temporary files.

This simple structural solution enables high modularity and hence easy maintenance. Both in principle and practice anyone can program new Survo modules in C by employing ready-made examples and the Survo program libraries. However, even in the most advanced applications no C programming is required. Usually the macro language of Survo is sufficient for creating even the most demanding solutions.

Modularity has also helped in keeping the sizes of program modules reasonable small. The size of a typical Survo program module varies between 100 and 200 KB.

Lowering the threshold

Some people have considered Survo a difficult system to learn because its editorial interface is so different from typical usage of Windows programs. I strongly believe that the new soft button technique will give quite new tools for adopting working modes of Survo.

One of my main goals is to create a simpler interface for a new user by button boards. Already now the primary row of soft buttons includes a JOBS button which opens a button set

By JOB the user can start a new job (in its own folder if required) and it creates a new edit field for the job. The job gets a name and the first lines of the edit field will automatically have suitable schemes for saving and printing. Also a return to any of earlier jobs takes place by clicking JOB.

By the DATA button Survo data files are created, saved, and edited. The STAT button leads to a menu of various statistical methods. If, for example, the FACTA button is clicked in that menu, a new button board for factor analysis is opened. This is a menu containing boxes for making various choices. Thus by filling the boxes related to data (selecting variables and setting possible restrictions for observations), number of factors, method of factoring and rotation, etc. and finally by clicking the OK button, the factor analysis will be automatically performed. The actual Survo commands generated according to the user's selections and the results (like the rotated factor matrix) will appear on the first free lines of the edit field. After each operation the edit field is automatically saved; this ensures that the job and its results will not be losed. The PLOT button opens the way for making statistical graphics. By the PRINT button the whole job with texts, commands, tables and plots will be printed either directly by a PostScript printer or indirectly (through the GSview or Adobe Acrobat program, for example) by any Windows printer.

Picture: SURVO MM and factor analysis with the softened interface
Picture in larger size

In this way, anybody - without previous knowledge about Survo - has a a simple access for making typical statistical data analysis, plotting, and data management. It is my hope, however, that when seeing how all this actually is done by Survo, the user learns to do corresponding things without the support of soft buttons.

For the time being this softened interface covers a very restricted portion of possible Survo functions. There is no purpose to replace everything by soft boards. Every experienced Survo user can create - according to ready-made models - new variations and extensions of this teaching kit.

How to get acquainted with SURVO MM?

When SURVO MM is started, the primary set of soft buttons offers keys to the world of this new Survo. Experienced Survo users learn about the new possibilities of SURVO MM by clicking the right side of the HELP button. The left side of the HELP button leads to the start of the help system.

New users may start also by watching tutorials made as sucros. The DEMO button gives a list of them.

More information can be found from our website which is maintained by Survo.

Since SURVO MM is compatible with its predecessors, the user guide S.Mustonen: Survo - An Integrated Environment for Statistical Computing and Related Areas (Survo Systems, 1992, pp.494). is still a valid introduction to Survo although it contains only about a half of the functions which are now available.

The examples in this book can be run by clicking the START button and by selecting item 6.

HELP window

The up-to-date source of information related to Survo is its help system. It is continuously maintained by the Survo Editor because files belonging to it are ordinary edit fields.

An inquiry is initiated either by pressing the HELP key (F1) or by clicking the HELP button or by activating a keyword with a question mark (e.g. PRINT?). Also any word in the edit field may work as a link to the help system by double-clicking it by the rightmost button of the mouse.

The help system is working in its own window. In the help window the cursor can be moved (by the mouse or by arrow keys) to indicate any word in the help text and more information on the new word is obtained by clicking the mouse or by the F1 key.

The user may copy text shown in the help window to the edit field and use it as a basis for his/her own work.

Below, the user has clicked the right side of the HELP button, and the help window is now visible.

Picture: SURVO MM and its help window
Picture in larger size

Contributors to SURVO MM

I am responsible for the general planning and for the main part of programming of SURVO MM.

Kimmo Vehkalahti has programmed so-called desktop modules (DESKTOP?) and certain functions related to multivariate statistical analysis. He has created the Survo HTML interface for making WWW pages. He is also responsible for making several sucros especially for combined graphical presentations.

Markku Korhonen has programmed a collection of modules for the analysis of variance and covariance. He has also made certain programs for more advanced data base management and for multivariate statistical analysis.

Single program modules and sucros have been produced by Mikko Karpoja, Jyrki Nummela, Juha Puranen, Reijo Sund, Lauri Tarkkonen, and Fredrik Åberg.

Installation of SURVO MM

SURVO MM requires a 300 MHz Pentium PC or better with at least 64 MB (Win95, 98, Me) or 128 MB (NT, 2000, XP, Vista). Windows Vista, XP, and 2000 environments are more stable in Survo applications.

Installation takes place from the SURVO MM CD by selecting My Computer -> SURVO MM -> SETUP. The default directory for the SURVO MM system folder is the standard folder of Windows programs.

After installation a SURVO MM icon will appear on the Windows desktop. SURVO MM is started by double-clicking this icon.

SURVO MM can be removed like any Windows program by selecting Start -> Settings -> Control Panel -> Add/Remove Programs etc.

Control of SURVO MM windows

When SURVO MM is started, its main window will be displayed in the left upper corner of the screen. Other Survo windows will appear when needed either below the main window (OS and Help windows) or on the right side of the screen (graphics windows).

The places and sizes of the windows are altered by soft keys SYSTEM -> WINDOW.

The default setting of Survo graphics windows is three windows below each other on the right hand side of the screen. The number, sizes, and positions of these windows are controlled by the GPLOT /LAYOUT command. Other standard settings of graphics windows can be selected and tested by soft buttons SYSTEM -> GRAPH.

More information is found by SYSTEM -> GRAPH -> HELP or directly by inquiry GLAYOUT?


Texts and graphics generated by SURVO MM is printed on paper either directly by a PostScript printer connected to the computer or indirectly by saving printouts to PostScript files and then using a suitable Windows program (like GSview or Adobe Acrobat) for printing PostScript files on any Windows printer. More information is obtained by inquiry PRINTER?

Home  |  News  |  Publications  |  Download  |  Flash
Copyright © Survo Systems 2001-2008. All rights reserved.
Updated 2008-10-20 by webmaster'at'survo.fi.
Best viewed with any browser.