- Home
- Products
- Integration
- Tutorial
- Barcode FAQ
- Purchase
- Company
java qr code app PGPLOT devices in Java
PGPLOT devices QR Code JIS X 0510 Generator In Java Using Barcode creation for Java Control to generate, create QR Code JIS X 0510 image in Java applications. www.OnBarcode.comQR Code JIS X 0510 Decoder In Java Using Barcode reader for Java Control to read, scan read, scan image in Java applications. www.OnBarcode.comThe pgopen() call takes one argument: the device to write to. A device specification is made up of two parts: optionally, the name of the device or file and the device type, ECC200 Maker In Java Using Barcode drawer for Java Control to generate, create Data Matrix image in Java applications. www.OnBarcode.comDrawing EAN-13 Supplement 5 In Java Using Barcode maker for Java Control to generate, create GS1 - 13 image in Java applications. www.OnBarcode.comVersion 5.0.0 was released in December 1994, and the current version, 5.2.0, was released in June 1997. Creating UPC - 13 In Java Using Barcode creation for Java Control to generate, create EAN 13 image in Java applications. www.OnBarcode.comCode 128 Code Set A Generation In Java Using Barcode printer for Java Control to generate, create Code 128 image in Java applications. www.OnBarcode.comCHA PTE R 5
ANSI/AIM Code 128 Creation In Java Using Barcode maker for Java Control to generate, create ANSI/AIM Code 128 image in Java applications. www.OnBarcode.comIdentcode Drawer In Java Using Barcode maker for Java Control to generate, create Identcode image in Java applications. www.OnBarcode.comCREATING CHARTS
QR Maker In .NET Framework Using Barcode printer for Reporting Service Control to generate, create Denso QR Bar Code image in Reporting Service applications. www.OnBarcode.comDenso QR Bar Code Printer In None Using Barcode creation for Word Control to generate, create QR-Code image in Microsoft Word applications. www.OnBarcode.compreceded by a slash (/). If the device or file name contains slashes, it should be enclosed in double quotes: Barcode Encoder In Java Using Barcode creation for Eclipse BIRT Control to generate, create Barcode image in BIRT reports applications. www.OnBarcode.comEAN 13 Scanner In VS .NET Using Barcode decoder for .NET Control to read, scan read, scan image in .NET applications. www.OnBarcode.commy $device_id = pgopen('"/tmp/file.ps"/PS'); Encode Denso QR Bar Code In Objective-C Using Barcode printer for iPad Control to generate, create QR Code ISO/IEC18004 image in iPad applications. www.OnBarcode.comEuropean Article Number 13 Maker In C# Using Barcode creator for VS .NET Control to generate, create EAN-13 Supplement 5 image in .NET framework applications. www.OnBarcode.comIf the device or filename is left off, PGPLOT will use a default name. Which devices are available to you depends on how your local copy of the library has been compiled. The distribution ships with code for a large number of devices, some of which are shown in table 5.2. Draw Data Matrix ECC200 In None Using Barcode drawer for Software Control to generate, create Data Matrix 2d barcode image in Software applications. www.OnBarcode.comMaking EAN / UCC - 13 In C# Using Barcode maker for .NET Control to generate, create GTIN - 128 image in .NET applications. www.OnBarcode.comTable 5.2 The devices that can be used in PGPLOT programs, by specifying them as an argument to pgopen(). The device names starting with a V cause the output to be vertically oriented, the others have a horizontal orientation. For the devices that output to a file, a nondefault file name can be specified between double quotes before the slash. Type GIF file HPGL plotters Portable pixel map PostScript X Windows Null device (no output) LaTeX picture environment Type specifications /GIF /VGIF , /HPGL, /VHPGL /PPM, /VPPM /PS, /CPS, /VPS, /VCPS /XWINDOW, /XSERVE /NULL /LATEX pgplot.tex Default device pgplot.gif pgplot.hpgl pgplot.ppm pgplot.ps default X display Creating UPC Code In None Using Barcode drawer for Online Control to generate, create UPC-A Supplement 5 image in Online applications. www.OnBarcode.comRecognize PDF-417 2d Barcode In Java Using Barcode recognizer for Java Control to read, scan read, scan image in Java applications. www.OnBarcode.comThe device names that start with a V plot their output in portrait (vertical) mode, the other ones plot in landscape mode. For example: to plot a GIF file in landscape mode, use /GIF. To plot in portrait mode, use /VGIF. The PostScript drivers with a C in the name will output color PostScript. Each device can be controlled by setting environment variables which are described in the user manual. If you want to specify a different width, height or resolution than is the default for the driver, you would set the appropriate environment variables. For example, to set the width and height of a GIF output file, you would do something like: USS Code 128 Decoder In VB.NET Using Barcode scanner for Visual Studio .NET Control to read, scan read, scan image in VS .NET applications. www.OnBarcode.comCode 3/9 Drawer In None Using Barcode generation for Microsoft Excel Control to generate, create Code 39 Full ASCII image in Office Excel applications. www.OnBarcode.com$ENV{PGPLOT_GIF_WIDTH} = 640; $ENV{PGPLOT_GIF_HEIGHT} = 480; pgopen('"/tmp/resized.gif"/GIF'); The user manual contains an appendix with a full description of each driver, including all the environment variables that affect the output for that driver. There are a number of device drivers available for specific printers, plotters, terminals and special applications, such as tcl/tk widgets. 5.3.2 Example: A simple X-Y plot PGPLOT produces simple X-Y plots with a minimum of fuss, but there is a certain methodology that needs to be followed. 77 PGPLOT
Figure 5.6 This graph illustrates how to use PGPLOT to plot data points with their respective error bars, a function to fit the data, and a visual label for this function s line. Let s walk through the code that produced figure 5.6: use PGPLOT; my my my my @x = (-0.5, 0, 1, 2, 3, 5); @y = (0.35, 0.1, 1.2, 3.3, 9.5, 23); @y_err = (0.6, 0.3, 0.8, 1.6, 2.0, 3); $num = @x; First, the PGPLOT module is included, which exports all the functionality we need into the current name space, hence we can use the functions just as described in the PGPLOT user s manual. We then set up some data to plot. Most of the PGPLOT calls require an array of X values and an array of Y values of the same length. Since we want to draw error bars as well, we define an array containing the error in the measurements in both the upward and downward directions, i.e., the total error is twice as large as the elements of the array. These arrays will be used later in the program in calls to pgpt() and pgerry(). It s now time to open a device to write to, and set up the environment: $ENV{PGPLOT_PS_WIDTH} = 4000; $ENV{PGPLOT_PS_HEIGHT} = 3000; my $dev_id = pgopen('pgplot1.eps/VPS'); die "Couldn't open plot" if $dev_id <= 0; pgslw(2); pgsch(1.5); pgenv(-1, 5.5, -5, 30, 0, 0); The pgopen() function is called to open a PostScript file for output. If this fails, pgopen() will return a false value, allowing us to check for success in the same way that we would with a regular open(). You will occasionally see a call to pgbeg() instead of pgopen(). This is a sign that you re looking at an older program, since pgbeg() is deprecated nowadays, and only available for compatibility with existing programs. 78
|
|