Using Graphics

[Genhelp | Program Manual | User's Guide | Data Files | Databases | Release Notes ]

Table of Contents

Overview

Initializing your graphics configuration

Defining your graphics configuration

Using SetPlot

Using a graphics configuration command

Abbreviating graphics configuration commands

Checking your graphics configuration

Displaying your graphics configuration

Testing your graphics configuration

Working with graphic output files

Saving graphic output to a figure file

Redirecting graphic output

Graphic global parameters

For advanced users

Modifying the graphic image

Drawing a grid

Controlling density

Changing fonts

Changing colors

Zooming

Panning

Page orientation

Skewing the graphic

Preparing data for publication

Editing figure files

Including graphics in a document

Printing graphic output from a Macintosh or PC

Printing from a Macintosh to a LaserWriter

Printing from a PC


Overview

[ Top | Next ]

By now you have learned the basics of working with command lines and parameters, and you've gained some experience working with sequences and Accelrys GCG (GCG) programs. At some point in your work with GCG programs, you probably will use one that produces graphic output. This section presents the basics of creating, displaying, printing, and plotting graphics produced by the package.

Beginning users should read "Initializing Your Graphics Configuration" to learn about setting up their graphics configuration. The remaining sections in this section are for intermediate and advanced users who want to modify the graphic output file or redirect it to a different file or device.

In this section, you will learn how to


Initializing your graphics configuration

[ Previous | Top | Next ]

Many GCG programs produce graphic output. To display, print, or plot that output, you must have a supported graphics device (see Appendix C, Graphics for a list of supported graphics devices). In some cases, you will have multiple devices available to you, such as a graphics terminal, printer, or plotter. To display on a device or to switch between devices, you must specify the appropriate graphics language, the kind of supported device you have, and the port to which it is connected before you run a graphics program. Once you define your graphics configuration for GCG, all graphics programs display their output on the device that you named until you initialize for a different configuration or until you log off.

This section teaches you how to

Defining your graphics configuration

[ Previous | Top | Next ]

Before you run a GCG program that produces graphic output, you must define your graphics configuration. Defining your graphics configuration means telling the computer what graphics language you want to use and on what device you want to display. If you plan on directing graphics to a single device for an entire session, you will need to define your graphics configuration only once. However, if you decide to switch to a different graphic device, you must redefine your graphics configuration for each device.

There are two ways you can define your graphics configuration:

The SetPlot program lets you set up your configuration in one step. This program lets you pick a graphics device from a menu that lists the names of each device available in your work environment.

A system manager usually sets up the SetPlot command for users at a site. However, if SetPlot is not set up for you, or if you have your own personal graphics devices you want to send output to, you can add them to the SetPlot menu; these devices will then appear only on your SetPlot menu. For more information, see "Using SetPlot" below.

Configuration commands correspond to the names of graphics languages. For example, if you have an HP7550 plotter, you would use the HPGL configuration command. (HPGL stands for Hewlett Packard Graphics Language, a language used for many of Hewlett Packard x-y plotters.) For more information see "Using a Graphics Configuration Command" below.

For example, consider the following example which sets up a graphics configuration for an HP7550 plotter connected to the port /dev/tty15.

 

 

Using SetPlot

To use SetPlot:

  1. Type % setplot. The computer displays a list of available graphics devices at your site.

  1. Choose a device by pressing the <Up Arrow> or <Down Arrow> keys.
  2. Choose from the following options:

·       Select a graphics device. With the device highlighted that you want, press <Return>. The program initializes and displays your chosen graphics configuration and returns you to the command-line prompt. You are now ready to run a graphics program.

·       View a device's configuration. Type v. The screen displays the chosen device's configuration, including unique abbreviation, description, port/queue/file, language, and device name.

You cannot edit a device's configuration from this display.

·       Create a new device.

a.       Type c. The program makes a copy of the chosen device and displays its configuration, including unique abbreviation, description, port/queue/file, language, and device name.

b.      Press <Tab> to move to the field you want to edit.

c.       Type e to edit the field.

d.      Type the new configuration in the text box provided or press the <Up Arrow> or <Down Arrow> keys to select a new configuration.

e.       Press <Return> to enter the edit.

f.        Repeat steps b - e for each field you need to edit.

g.       Press m to return to the main menu.

·       Edit the configuration for an existing device.

Note: You can edit only your own personal graphics devices. You cannot edit the configuration of a site device.

a.      Type e. The program displays the chosen device's configuration, including unique abbreviation, description, port/queue/file, language, and device name.

b.      Press <Tab> to move to the field you want to edit.

c.      Type e to edit the field,.

d.      Type the new configuration in the text box provided or press the <Up Arrow> or <Down Arrow> keys to select a new configuration.

e.      Press <Return> to enter the edit.

f.        Repeat steps b - e for each field you need to edit.

g.      Press m to return to the main menu.

·       Delete a device. Press d. The chosen device is deleted from the SetPlot menu.

Note: You can delete only your own personal graphics devices. You cannot delete a site device.

·       Quit the program. Press q. The program returns you to the command-line prompt.

Using a graphics configuration command

To use a graphics configuration command:

  1. Type one of the following at the system prompt:

·       % gif (Graphics Interchange Format)

·       % hpgl (Hewlett Packard Graphics Language)

·       % png (Portable Network Graphics)

·       % postscript

·       % regis

·       % sixel

·       % tektronix

·       % xwindows

Note: The high-performance terminals, such as workstations (running X Windows), GraphOn 250 and 407, and Tektronix 4107 and 4207, are the recommended devices for previewing GCG graphics. On these devices, a complicated illustration takes only a few seconds to display.

The computer lists the devices which support the graphics language you selected and displays the prompt "Please choose one."

  1. Enter the type of graphics device you have. The graphics languages listed above support many graphics devices. For more information on these graphics languages and the devices they support, see "Configuring Graphics Languages and Devices" in Appendix C, Graphics.

    The computer displays the prompt "To what port is your device connected:".
  1. Choose from the following:

·       Printer or plotter. Type the name of the port to which the graphics device is connected. A port is a part of a computer through which a peripheral device, such as a terminal, printer, or plotter, may communicate. Every port has a name. To determine the name of a port, ask your system manager or refer to your system documentation.

·       File. Type the name of the file to which you want to save the output. The file is written in the graphics language for the device which you initialized. Note that each time you run a graphics program with this configuration, the file will be overwritten with the output of the most recently run program.

·       Screen. Type term to display output on your screen. You must have a graphics terminal or use graphics terminal emulation software.

·       Queued Device. Type "| print_queue_command". A queued device is one in which your system manager has set up a method for controlling jobs submitted to it. That is, when you submit a job to a queued device, it is added to the end of a list of other jobs waiting to execute. Your job will execute after all preceding jobs have completed.

Note: When you direct graphics output to a printer, plotter, screen, or queued device, the output is not saved in a file for future use. To temporarily redirect output to a different device or to a file, see "Redirecting Graphic Output" in this section.

The computer also may prompt you for the correct paper size. It then initializes your graphics device and displays a summary of your plotting configuration. You are now ready to run a graphics program.

TIP - You can define any graphics configuration on a single command line, thus avoiding the interactive prompts. To do so, type the answers to each prompt on the command line, separating each response with one space, for example, % hpgl HP7550 /dev/tty15 A4.

 

Abbreviating graphics configuration commands

If you have more than one graphics device available and you want to switch between them efficiently, you can define aliases that configure your devices quickly and correctly. (For more information about aliases, see "Using Aliases" in the "For Advanced Users" section of Section 3, Using Programs.)

As an example, let's say you have an Apple LaserWriter printer and a Tektronix 4207 graphics terminal that you switch between frequently. To speed up the process of configuring each device, and to ensure you configure them correctly each time, you could define two short commands, % lw and % tk to configure these devices.

To define aliases for your graphics configuration:

  1. Open your .gcgrc (csh) or .gcgrc.ksh (ksh) file in the text editor of your choice, for example vi. For more information about creating and using your .gcgrc or .gcgrc.ksh file, see "Customizing Your Login" in the "For Advanced Users" section of Section 1, Getting Started.
  1. Type the alias(es). Aliases use the following syntax:

    (csh) alias abbreviation command_line
    (ksh) alias abbreviation="command_line"

Using the scenario given above, you could define your Apple LaserWriter printer and Tektronix terminal as follows:

(csh) alias tk tektronix Tek4207 Term
alias lw postscript LaserWriter /dev/tty15

(ksh) alias tk="tektronix Tek4207 Term"
alias lw="postscript LaserWriter /dev/tty15"

  1. Save the file and exit from the text editor.
  1. Test the alias. Follow these steps:

a.       Type % source .gcgrc (csh) or % . .gcgrc.ksh (ksh) to rerun the file.

b.      Type the alias you assigned, for example % lw.

c.       Type % showplot to display your graphics configuration. ShowPlot displays a summary of your graphics configuration. If the summary is incorrect, edit the alias as necessary and test it again.

 

 

Checking your graphics configuration

[ Previous | Top | Next ]

You can verify that your graphics configuration is set up correctly by displaying a summary of your configuration settings or by running a test plot.

 

Displaying your graphics configuration

Perhaps you've forgotten what graphics language you've configured your graphics output for, or maybe you've switched between several devices and don't remember your current settings. In any case, you can use the ShowPlot command to display your graphics configuration for you.

To display a summary of your current graphics configuration settings:

Type % showplot. The computer displays your configuration. For example

 

Graphics programs also display your graphics configuration settings on your terminal screen when you are ready to plot the results of a graphics program, for example "When your LaserWriter attached to /dev/tty16 is ready, press <rtn>." If this message reveals a configuration other than the one you want, press <Ctrl>c to exit the program and redefine your graphics configuration. Then run the program again.

Testing Your Graphics Configuration

GCG provides the PlotTest program for you to test if you've defined your graphics configuration correctly. Use this program to display, print, or plot a test graphics file which uses every supported GCG graphics feature.

To test if your graphics are initialized correctly:

Define your graphics configuration. For more information, see "Defining Your Graphics Configuration" earlier in this section.

Type % plottest. The computer writes the graphics display output as shown below into a graphics.dat image file, which can be opened using any graphics viewer.

.

 

If you see the above graphic, you can assume your graphics configuration is correctly set up.

 

Working with graphic output files

[ Previous | Top | Next ]

Note: If you are using a program that produces text output, see Section 3, Using Programs for more information on working with text output files.

This section teaches you how to

·         Save graphic output to a Figure file.

·         Redirect graphic output to a file, screen, printer or plotter, or queued device.

Saving graphic output to a figure file

[ Previous | Top | Next ]

Typically when you define your graphics configuration, you direct your output to a graphics terminal, printer, or plotter. When output is directed to a device such as one of these, it is not saved in a file for future reference. To save output to a file which you can direct to multiple devices, use the -FIGure command-line parameter, which writes the file in Figure file format.

Figure file format is interpreted by the Figure program, which gives you flexibility in combining text and graphics. You will find Figure file format advantageous for two reasons: 1) you can use a text editor to modify a Figure file, for example to add explanatory text to a graphic (see "Figure" in the Program Manual for more information); and 2) Figure files are device independent. You can display, print, or plot a file in Figure format on any device, regardless of the device for which you were configured when you initially saved the file. This allows you to display the graphic results of an analysis on multiple devices without rerunning the analysis program each time.

To save graphic output to a Figure file:

Add -FIGure=filename to the command line, where filename is the name of the output file, for example, % isoelectric pir1:kihua -FIGure=kihua.figure. The program writes the graphic output in Figure file format that can be interpreted by the Figure program.

Note: If you type -FIGure without including a filename, the computer will give the file the default name of the program with the extension .figure, for example isoelectric.figure.

To display, print, or plot a Figure file:

Initialize your graphics configuration for the graphics device on which you want to display, print, or plot. For more information, see "Initializing Your Graphics Configuration" in this section.

Run the Figure program, which interprets the Figure file format. Type % figure filename, where filename is the name of the file created earlier with the -FIGure parameter.

Figure displays, prints, or plots the file according to your current configuration. To redirect the Figure file to a different device, initialize your graphics configuration for that device and run the Figure program again.

 

Redirecting graphic output

[ Previous | Top | Next ]

You typically direct where your graphic output goes (that is, to a file, a graphics terminal, a printer, or a plotter) when you define your graphics configuration. However, when you run a program you can temporarily redirect output to another device as long as they both support the same graphics language. For instance, let's say the printer for which you're configured is busy, but a second printer supporting the graphics language you defined is available. Or, what if you've defined your configuration to send output to your terminal, but you want to save the next output in a file? You can solve both problems by using the -PLOt= parameter to temporarily redirect graphic output to a file or to a different device.

To permanently redirect the output, redefine your graphics configuration. For more information, see "Defining Your Graphics Configuration" in this section.

To temporarily redirect output to a file or a different device:

Choose from the following.

Note: You can redirect graphic output only to other devices supporting the graphics language for which you currently are configured. That is, if you are configured for the PostScript language, you cannot redirect output to an HPGL device.

File. To save output to a file, add -PLOt=filename to the command line, where filename is the name of the file to which you want to save the output.

Note: The file is written in the graphics language and for the device you previously initialized. To save output to a device-independent file, use the -FIGure=filename command-line parameter. For more information, see "Saving Graphic Output to a Figure File" in this section.

Screen. To display output in a window on your screen, add -PLOt=term to the command line.

If you are using the XWindows graphics language and have multiple graphics windows open, you can direct output to a specific window. To do so, add -PLOt=banner_name to the command line, where banner_name is the title that appears in the banner along the top of the plot window.

Note: To display graphics on your screen, you must have a graphics terminal or use graphics terminal emulation software.

Printer or Plotter. To redirect output to a printer or plotter, add -PLOt=port to the command line, where port is the name of the port where your graphics device is connected. If the printer or plotter is queued, see "Queued Device" below.

If the printer or plotter is connected to your computer in "pass-through" or "eavesdrop" configuration, add -PLOt=Term to the command line. Output is then directed to the device. For more information about these types of configurations, see "Connecting a Graphics Device to the Computer" in Appendix C, Graphics.

Queued Device. To redirect output to a queued printer or plotter, add -PLOt="| print_queue_command" to the command line, for example -PLOt="| lpr -Pplotter". See your system manager for the appropriate print queue command on your system.

A queued device is one for which your system manager has set up a method for controlling jobs submitted to it. That is, when you submit a job to a queued device, it is added to the end of a list of other jobs waiting to execute. Your job will execute after all preceding jobs have completed.

Graphic global parameters

[ Previous | Top | Next ]

You can find parameters specific to each program described in the "Command Line Summary" topic toward the end of each program in the Program Manual. However, there are a number of parameters that are global to graphic programs within the package; that is, they can be used with all GCG graphic programs. To avoid repetition, not all of these optional parameters are displayed in the "Command Line Summary" in the online or printed documentation of graphics programs.

You can use the following parameters with all GCG graphics programs. However, some graphics devices do not support each parameter.

For more information on using parameters, see "Using Program Parameters" in the "Customizing Program Analysis" section of Section 3, Using Programs.

Global Parameters

Example

Description

Supported Graphics Language

-AUTOFeed

 

Advances the second and all subsequent pages of the plot automatically. You must load the first sheet of paper as you normally would.

Plotters equipped to support automatic paper feed must be set up locally. For example, the HP7550 must have the autofeed button pushed and paper in the feed tray.

If your plotter is queued or if you are writing the plotting instructions into a file, then this option is automatically in effect.

HPGL

PostScript

Tektronix

XWindows

ReGIS

Sixel

PNG

GIF*

-BOX=horizontal_start, horizontal_end,

vertical_start,

vertical_end,

grid_color,

distance_between_frames, line_width

-BOX=0,150,0,100,1,2,0.2

Draws a box or frame on the plot. The first four parameters set the position of the box in platen units. The fifth parameter sets the color. The sixth parameter sets the distance between the inner and outer frames. The seventh parameter sets the line thickness in platen units of the outer frame.

 

All parameters are optional. You can specify just the first parameter, the first two parameters, the first three parameters, etc., or no parameters, When you do not specify any parameters, a box is drawn by default with the values in the Example column to the left.

HPGL

PostScript

Tektronix

XWindows

ReGIS

Sixel

PNG

GIF*

-CLIpping

 

Does not plot or print line segments that go outside the plotting window. (See -NOCLIpping.)

HPGL

PostScript

Tektronix

XWindows

ReGIS

Sixel

PNG

GIF*

-COLor=number

-COLor=3

Draws the plot with the color number you specify. GCG graphics programs expect the plotting pens to be installed in the following order:

Black 1

Green 2

Blue 3

Red 4

 

Your plotter also may support other colors using numbers greater than 4.

HPGL

ReGIS-

(340, 241)

PostScript

Tektronix-

(4107, 4105)

XWindows

PNG

GIF*

-COPies=number

-COPies=2

Prints the number of copies you specify for each page on a laser printer.

PostScript

HPGL-

(LaserJet III)

-FASt

 

See -NOTEXT

 

-FIGure=filename.figure

-FIGure=Gamma.Figure

Writes the plot as a text file of plotting instructions for input to the Figure program. You can customize the plotting instructions in the text output file and can plot at any time on any graphics device. If you type -FIGure without including a filename, the computer will give the file the default name of the program with the extension .figure, for example program_name.figure. For more information, see the Figure program in the Program Manual.

HPGL

PostScript

Tektronix

XWindows

ReGIS

Sixel

PNG

GIF*

 

-FONT=number

-FONT=1

Draws all text characters on a plot using the font number you specify. Font 0 is a monospaced firmware font that plots much faster than software generated fonts. You can find fonts and their font numbers in Appendix I of the Program Manual.

HPGL

PostScript

Tektronix

XWindows

ReGIS

Sixel

PNG

GIF*

-GIFInterlace

 

Generates an interlaced image. This format lets the web browser load the image in waves instead of waiting until the entire image is downloaded. It is sometimes described as the Venetian blind effect.

GIF*

-GRId=grid_interval, grid_color

-GRId=5,1

Draws a grid behind a plot in the color you specify. The first parameter sets the grid interval in platen units. If this parameter is negative, the numbering along the bottom axis will be suppressed. The second optional parameter sets the grid color.

 

You can specify the parameters, just the first parameter, or none. When you specify none, a grid is drawn in black with the default interval of 5 platen units.

GCG graphics programs expect the plotting pens to be installed in the following order:

Black 1

Green 2

Blue 3

Red 4

For more information, see the "For Advanced Users" section in this section.

HPGL

PostScript

Tektronix

XWindows

ReGIS

Sixel

PNG

GIF*

-LINEWidth=number

-LINEWidth=0.5

Sets the line thickness for all lines on the plot to a percentage of a platen unit. A platen unit is one percent of the vertical height of the platen. A platen is represented on every supported graphics device as 150 horizontal units (x) by 100 vertical units (y).

 

Many devices do not support this option.

PostScript

XWindows

HPGL-

(LaserJet III)

-NOCLIpping

 

Plots or prints line segments that go outside the plotting window. (See -CLIpping.)

HPGL

PostScript

Tektronix

XWindows

ReGIS

Sixel

PNG

GIF*

-NOTEXT

 

Suppresses all of the text on a plot. This option can sometimes make plotting faster on devices where character plotting is slow.

HPGL

PostScript

Tektronix

XWindows

ReGIS

Sixel

PNG

GIF*

-NOUNLoad

 

Superimposes a second picture over the top of an existing plot on some devices that would normally unload the paper automatically after plotting each page.

 

Most laser printer device drivers do not yet support this option.

HPGL

Tektronix

XWindows

ReGIS

Sixel

-XSCAle=number

-YSCAle=number

-XSCAle=0.7

-YSCAle=1.5

Scales the x and y axes independently. (See -SCAle.)

 

For more information, see the "For Advanced Users" section in this section.

HPGL

PostScript

Tektronix

XWindows

ReGIS

Sixel

PNG

GIF*

 

For advanced users

[ Previous | Top | Next ]

This section covers advanced tasks you may want to perform after you have become familiar with graphics programs and their output. This section teaches you how to

·         Modify the graphic image.

·         Prepare data for publication.

·         Print graphic output from a Macintosh or PC.

Modifying the graphic image

[ Previous | Top | Next ]

After you become familiar with displaying, printing, or plotting graphic output, you may find that you want to modify a graphic image by zooming in to a section of the graphic or changing the font of the text. GCG lets you easily make these and other modifications by adding parameters to the command line when you run the program.

Some of the parameters discussed below modify the length and width of the graphic, which involves changes in platen units (pu). A platen unit is one percent of the length of the vertical axis of the platen. A platen is the plane of your graphics device; GCG programs use 100 pu x 150 pu as the platen (see figure below). You should become familiar with these terms and their meanings to understand how to use the parameters in this section.

You can modify a graphic image in the following ways:

·         Draw a grid behind a graphic.

·         Control the density, or number of bases plotted per 100 platen units.

·         Change the font.

·         Change the color.

·         Zoom in or out of the graphic.

·         Pan the graphic by moving it up and down or left and right.

·         Change from landscape to portrait page orientation.

·         Skew the graphic.

Drawing a grid

To draw a grid behind any GCG graphic:

Add -GRId to the command line. For example, % isoelectric pir1:kihua -Default -GRId produces the following graphic image:

-GRId supports two optional parameters:

-GRId=grid_interval, grid_color

grid_interval. This parameter sets the grid interval in platen units. A platen unit is one percent of the vertical dimension of the platen, or plane of your screen. If this parameter is negative, the numbering along the bottom axis will be suppressed.

grid_color. This parameter sets the grid color. You can specify the parameters, just the first parameter, or none. When you specify none, a grid is drawn in black with the default interval of 5 platen units.

GCG graphics programs expect the plotting pens to be installed in the following order:

1.      Black - 1

2.      Green - 2

3.      Blue - 3

4.      Red - 4

Controlling density

 

Let's say you want to compare the graphic output for sequences of different length. However, because all sequences are plotted on one page by default, regardless of sequence length, this may be hard to do. Some GCG programs let you line up plots for different sequences using the -DENsity=number command-line parameter, which specifies the number of bases or residues per 100 platen units. (A platen unit (pu) is one percent of the length of the horizontal axis of the platen. A platen is the plane of your screen, which is 100 pu x 150 pu.) Therefore, if you specify an identical density for sequences of different length, base 100 from one sequence will line up with base 100 from a different sequence and so on. This may mean that graphics may stretch onto multiple pages.

To change the number of bases or residues per 100 platen units:

Add -DENsity=number to the command line.

Note: This command-line parameter does not work with all graphics programs. In addition, some programs do not allow you to specify a lower density.

 

Changing fonts

 

To change the font used to create text in a graphic:

Add -FONT=number, where number is the number of the font you want to use. Font 0 is a monospaced firmware font that plots much faster than software generated fonts. You can find a list of available fonts and their numbers in Appendix I of the Program Manual.

For example, % pepplot pir1:kihua -Default -FONT=4 produces the following graphic image:

Changing colors

If your graphics device supports color, you can specify the color of the graphic image.

To change the color of the graphic image:

Add -COLor=number to the command line, where number is the number of the color you want to use:

1.      Black - 1

2.      Green - 2

3.      Blue - 3

4.      Red - 4

Your printer or plotter may support colors other than those listed above. You can access additional colors using numbers greater than 4. Refer to your printer or plotter documentation for more information.

Zooming

You can zoom in on a graphic to focus on sections in more detail, or you can zoom out to scale a graphic down in size.

To zoom in or out of a graphic:

Add -SCAle=number, to the command line, where number is the proportion at which you want to scale the graphic. For example, % dotplot hpr.pnt hpf.pnt -Default -SCAle=1.5 zooms in on the graphic, producing the following graphic image:

TIP - If you are using the XWindows graphics configuration, "Zoom" and "Restore" buttons will appear at the bottom of the graphics window. You can use the Zoom button and the mouse to zoom in on and pan the graphic. Use the Restore button to return the graphic to its original display.

As another example, % helicalwheel sw:mel_apido -Default -SCAle=0.5 zooms out of the graphic, creating a smaller graphic image:

Panning

You can move an entire plot either up and down or left and right in platen units to focus on different areas of the graphic.

To pan a graphic image:

Add -XPAN=number and -YPAN=number to the command line, where number is the x or y coordinate of the platen unit where you want to start plotting or printing the graphic image. For example, % plottest -XPAN=40 -YPAN=30 move the plot to the right and up, producing the following graphic image:

In this example, instead of beginning the plot at coordinate (0,0), the plot begins at coordinate (40,30).

Page Orientation

GCG graphics can appear in landscape or portrait orientation. Landscape orientation means that graphics appear on a page that is wider than it is tall. Portrait orientation means that the graphics appear on a page that is taller than it is wide. For example

By default, GCG programs create graphics in landscape orientation.

To change the page orientation to portrait:

Add -PORtrait to the command line.

Skewing the graphic

You can scale the x and y axes independently if you want to change the aspect ratio of the graphic image.

To change the aspect ratio of a graphic image:

Add -XSCAle=number and -YSCAle=number on the command line, where number is the proportion by which you want to scale the graphic. For example, % plottest -XSCAle=0.8 -YSCAle=1.4 changes the ratio of the graphic from the normal 1.5:1.0 (150 platen units x 100 platen units) to 0.8:1.4 (80 platen units x 140 platen units).

Note: -XSCAle and -YSCAle can be used individually of each other. That is, you can change the aspect ratio of the x axis without changing the y axis ratio, and vice versa.

Preparing data for publication

[ Previous | Top | Next ]

This section gives you guidelines on how to prepare your graphic data for publication in a report, manuscript, or other document. Let's say you've worked with a GCG graphics program and produced output you'd like to include in a manuscript. The graphics look great, but you'd like to add a heading or two, and maybe put a box around the whole image. Editing a graphics file sounds intimidating, but GCG can write graphics output in a file in plain English (called a Figure file), making it easier for you to modify.

This topic provides pointers for

·         Editing figure files.

·         Including graphics in a document.

Editing figure files

 

GCG provides the Figure program to help you prepare your data for publication. Figure lets you combine text and graphics. You can create graphics from scratch, annotate graphics you created with another GCG program, include graphics within another file, size a graphic image, add color and borders, change fonts, and much more.

For instance, in the example below, two PlasmidMap images were combined and captions were added.

For more information on using Figure, see the Program Manual.

Including graphics in a document

 

When you prepare reports, manuscripts, or other types of technical documents, there may be times when you want to include GCG graphics within them. The package lets you save files in a number of formats: Encapsulated Postscript (EPS), color EPS (CEPS), and Graphics Interchange Format (GIF). You can include the graphics files created in these formats in most commercial document processing programs.

To include graphic files in a document:

Set your graphics configuration to use the PostScript or GIF language driver. For more information, see "Defining Your Graphics Configuration" in this section.

Run the graphics program of your choice, adding -PLOt=filename.eps or -PLOt=filename.gif to the command line, for example % pepplot pir1:kihua -PLOt=kihua.eps. The program runs as you directed, writing its output to the file you named.

If necessary, download the graphics file(s) from the host computer to your Macintosh or PC. To do so, you can use Kermit or FTP, widely available protocols for file transfer, or any other protocol you are familiar with. Set the file type as ASCII or binary. For example, you would transfer a PostScript file as ASCII and a GIF file as binary.

Import the EPS or GIF file into the document processing program of your choice. Refer to the document processing program documentation for information on how to import EPS or GIF files.

 

Printing graphic output from a Macintosh or PC

[ Previous | Top ]

If you are accessing GCG on a Macintosh or PC using terminal emulation software, you may also have a printer connected directly to your microcomputer. Printing output on a printer directly connected to your microcomputer has its own procedure and special considerations.

In general, you use the following process when printing output on a printer connected to your Mac or PC:

Create and save the graphic output from a GCG program as a file on the host computer.

Transfer the file from the host computer to your Mac or PC using a file transfer program such as Kermit or FTP.

Use software that can read the format of the transferred file to open and print the file

 

Printing from a Macintosh to a laserwriter

 

You can create a GCG graphics file on the host computer and transfer it to a Macintosh to print to an Apple LaserWriter connected to your microcomputer.

To print a GCG graphics file on a LaserWriter connected to a Macintosh:

Note: The following instructions are guidelines only. The exact steps for transferring a file depend on the terminal emulation and file transfer software you use. For more information, see the documentation for the terminal emulation and file transfer software you use.

On a Macintosh, log in to the host computer using a terminal emulator of your choice and initialize GCG.

In the GCG terminal window, define your graphics configuration as PostScript. For more information, see "Defining Your Graphics Configuration" earlier in this section.

Run GCG graphics program of your choice, adding -PLOt=filename to the command line, where filename is the name of the output file. The file is saved in PostScript format on the host computer.

Using the file transfer software available at your site set the file type for the file being transferred as ASCII and transfers the file.

On the Macintosh, choose between the following:

If your Macintosh has Mac OS X:

Open the transferred file using software that can read PostScript files.

Use the software's print function to print the file.

If your Macintosh has Mac OS 8 or 9:

Locate the transferred file.

Drag the file onto the LaserWriter's icon on the desktop. The file prints on the LaserWriter.

TIP - Accelrys also offers GCGFigure, a Macintosh program that allows you to display and print high-quality GCG graphics. Using GCGFigure, you are able to save GCG graphic images as PICT files, a standard file format for importing into word processing, desktop publishing, and graphic/drawing programs.

GCGFigure is freely available to all GCG users. If you are interested, you can transfer the program to your computer using anonymous ftp from ftp://alanine.gcg.com in the /pub/mac directory. We also recommend you transfer the ReadMe.GCGFigure file in that directory for more detailed information about using the program.

To display graphics with the GCG Figure program:

Run a graphic-producing program with the command-line parameter -FIGure=filename, for example % dotplot -FIGure=mydotplot.figure.

Transfer the file in ASCII mode to your Macintosh.

Start the GCGFigure program and select the transferred file to display it. See the GCGFigure ReadMe file for more information about using the program.

 

Printing from a PC

You can create a GCG graphics file on the host computer and transfer it to a PC to print on a printer connected to your microcomputer.

To print a GCG graphics file on a printer connected to a PC:

Note: The following instructions are guidelines only. The exact steps for downloading a file depend on the terminal emulation and file transfer software you use. For more information, see the documentation for the terminal emulation and file transfer software.

On a PC, log in to the host computer using a terminal emulator of your choice and initialize GCG.

In GCG terminal window, initialize the graphics configuration appropriate for your graphics device. For example, if you have a HP printer connected to your computer, it probably supports the HPGL language. For more information, see "Defining Your Graphics Configuration" earlier in this section.

Run the graphics program of your choice, adding -PLOt=filename to the command line, where filename is the name of the output file. The file is saved on the host computer in the graphics format for which you configured.

Transfer the file using the file transfer software available at your site. You must set the appropriate file type (ASCII or binary) before transferring the file. For example, you would transfer a PostScript file as ASCII and a PNG file as binary.

 

On your PC, navigate to the file you transferred using Microsoft Windows Explorer. Then double-click on the file to open it up in the appropriate viewer. Most viewer applications provide a print functionality you can use to print the graphic to any printer connected to your PC.

 

Note that you will need to install appropriate viewer software in your PC for this to work. PNG and GIF graphics are usually supported in a default installation of recent versions of Microsoft Windows.

 

 

Printed:  June 3, 2005  17:02


[Genhelp | Program Manual | User's Guide | Data Files | Databases | Release Notes ]


Technical Support: support-us@accelrys.com, support-japan@accelrys.com,
or support-eu@accelrys.com

Copyright (c) 1982-2005 Accelrys Inc. All rights reserved.

Licenses and Trademarks: Discovery Studio ®, SeqLab ®, SeqWeb ®, SeqMerge ®, GCG ® and, the GCG logo are registered trademarks of Accelrys Inc.

All other product names mentioned in this documentation may be trademarks, and if so, are trademarks or registered trademarks of their respective holders and are used in this documentation for identification purposes only.

www.accelrys.com/bio