Introduction  Main Window  Filter Window  Preferences Window  File Queue Window  Log Window

KMWin Help

Introduction

Overview

KMWin (Kaplan-Meier for Windows) is a programme for graphical presentation of Kaplan-Meier plots. KMWin connects to R, sends commands to R, loads data sources and generates survival curves with R functions. KMWin is only an interface and intended to make working with R easier.

After selection of a time and a status variable from the variables list, properties of the survival curve such as colour, line width and line type can be modified. Furthermore a curve description for the legend could be specified. Optionally a factor variable can be selected, certain levels of the factor may be chosen and corresponding graphical properties can be modified. In addition, labels, min and max values of axes and step sizes of axes can be adapted. Further features comprise marking of censored times, adding an information text to the graphic, inverting the survival curve, displaying a table with cases under risk at the respective time step, adding a legend (optionally with number of cases), calculating global or pair-wise Logrank tests with description texts and adjustable p-value accuracy (see Main Window). Plots can be saved for future use and may be reloaded for additional modifications. Every setting along with the name and folder of the data source is written to a file. If the location of the data source changes, then folder and file name can be updated.

Other options are the definition of filters (see Filter Window), modification of numerous preferences (see Preferences Window) like foreground colours, background colours, frames, font types, scale factors and margins for certain components of the plot. The communication between KMWin and R is logged to a text box (see Log Window) to follow which commands and functions of R were executed.

After drawing a plot, the generated graphic can be saved to a file or copied to the clipboard by right clicking within the R plot window or by making use of the R file menu. If plenty of plots were generated and saved with KMWin, then it is cumbersome to open and redraw every plot and save the corresponding graphic one by one. For this purpose, all the saved plots can be processed in a file queue (see File Queue Window) and saved to a folder in a certain graphic format.

Remarks

Status Bar

The status bar assists in creating new plots by suggesting what to do next and shows useful hints. It is located at the bottom of the window.

Hotkeys

Hotkeys for the programme are:

HTML Help

If the HTML help file kmwin.htm is located in the same folder as the KMWin binary kmwin.exe, then KMWin calls the help file and jumps to the appropriate section when an error occurs or F1 is pressed.

Communication between KMWin and R

KMWin and R communicate in a client/server environment. KMWin acts as server and sends commands to R which acts as client, e.g. KMWin orders R to open a file and to send back a list with names of variables.

Establishing a connection requires to create the temporary file .rProfile in the users temp folder. The .rProfile contains the client routine which is interpreted by R. The location of the temp folder is fetched via a system call.
If R is already running, then KMWin commands R to load .rProfile in order to establish a connection. The command is written to the Log Window and should be pasted into the R console when the latter did not work correctly.
If R is not running, then KMWin tries to fetch the install folder of R from the registry and loads R via a system call. The call is invoked from the temp folder, so the .rProfile is run automatically.
In case of problems when connecting, start first R and then KMWin.

Whenever KMWin instructs R to do something, R may respond with an error. The reasons can be multifaceted. Data sources cause problems if the file extension does not correspond to the content. Usually, variables are selected wrongly, i.e. the values of a variable do not correspond to the variable type. The input should be checked carefully or if necessary, both programmes should be restarted.

Development

KMWin has been developed by Arnd Groß, Marita Ziepert and Markus Scholz at the Institute for Medical Informatics, Statistics and Epidemiology at the University of Leipzig with the objective to support the evaluation of clinical studies.

This HTML file was last updated on March in 2012 and refers to the most recent version 1.51 of KMWin. The Software package can be downloaded from https://sourceforge.net/projects/kmwin/.


Introduction  Main Window  Filter Window  Preferences Window  File Queue Window  Log Window

Main Window

Description

The Main Window is the primary window on which the variables for survival time analysis can be selected (time, status, optional a factor variable). Survival curves can be selected and their style can be changed. Additionally, lots of adjustments are possible. Previous to activation of certain controls, a connection to R must be established and a new plot must be created or an existing plot must be loaded.

Remark

Positions (as Pos-x or Pos-y) are in units of the R plot window, e.g. position (0,0) is the origin.

List of Controls


Introduction  Main Window  Filter Window  Preferences Window  File Queue Window  Log Window

Filter Window

Description

Filtering survival time data prior to analysis can be achieved by applying a filter string on this window.

List of Controls


Introduction  Main Window  Filter Window  Preferences Window  File Queue Window  Log Window

Preferences Window

Description

The general settings of the plot such as colours, frames, font types, scales or margins can be modified on the preferences window. The settings are saved in the registry when closing KMWin and are stored along with other properties when saving a plot. The most recent settings are restored when restarting KMWin or when loading a plot.

List of Controls


Introduction  Main Window  Filter Window  Preferences Window  File Queue Window  Log Window

File Queue Window

Description

This window supports sequential processing of a list of previously saved plots and generating updates of them. Three different graphic output formats are available: Metafile (*.emf), Bitmap (*.bmp) or Jpeg (*.jpg). The file name of the output is the same as the file name of the saved plot. Only the file extension is substituted, e.g. example.emf is created from example.kmw.

List of Controls


Introduction  Main Window  Filter Window  Preferences Window  File Queue Window  Log Window

Log Window

Description

The whole communication between KMWin and R is logged into this text box. The output shows which R commands and functions were used. There are different keywords referring to the connection status and transferred data.

Keywords

The status task refers to the type of request: The status flag connected indicates the connection status (0=not connected, 1=connected), when the data package was processed. The status flag resend indicates whether the data package was sent again or not (0=no, 1=yes).