File: README.en

package info (click to toggle)
ruby-pgplot 0.1.3-6
  • links: PTS, VCS
  • area: contrib
  • in suites: wheezy
  • size: 480 kB
  • sloc: ruby: 1,382; ansic: 73; makefile: 37
file content (99 lines) | stat: -rw-r--r-- 2,623 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
      Ruby/PGPLOT ver 0.1.3 by Masahiro TANAKA  2006-12-13

= Description

  * Ruby interface to PGPLOT.
    It provides PGPLOT functions as a Ruby module.

= Requirement

  * PGPLOT ver 5.2.x
     (http://astro.caltech.edu/~tjp/pgplot/)
  * Libraries which PGPLOT drivers use:
    ** X11 library
    ** PNG library
    ** GrWin Graphics Library for MS-Windows.
     (http://spdg1.sci.shizuoka.ac.jp/grwinlib/english/)
  * Ruby ver 1.8.x
  * NArray Extension library ver 0.5.9
     (http://www.ruby-lang.org/en/raa-list.rhtml?name=NArray)

= Installation

  * install PGPLOT library

    - FORTRAN77 compiler required for source-compile.
    - C interface library (libcpgplot.a) is also required.

  * install Ruby, NArray

  * install Ruby/PGPLOT

    - extract distribution.

    - compile and install by:

      ruby extconf.rb [options (see below)]
      make
      make site-install
      (or make install)

    - Options for `ruby extconf.rb':
       --with-pgplot-include=path : path to cpgplot.h
       --with-pgplot-lib=path	  : path to PGPLOT libraries.
       --with-x11-dir=path	  : path to X11
       --with-grwin : for using GrWin (cygwin/mingw).
       --with-sunws : PGPLOT is compiled with Sun WorkShop f77.
		      gfortran is assumed without this option.

      example:
       ruby extconf.rb --with-x11-dir=/usr/X11R6 \
	--with-pgplot-include=/usr/local/pgplot \
	--with-pgplot-lib=/usr/local/pgplot

= Usage

  * Environment variables for PGPLOT (csh):

      setenv PGPLOT_DIR  /usr/local/lib/pgplot/ # pgxwin_server, rgb.txt
      setenv PGPLOT_FONT ${PGPLOT_DIR}/grfont.dat
      setenv PGPLOT_DEV  /xwin

  * To load the Ruby/PGPLOT extension;

      require "pgplot"

  * Module name is `Pgplot'.  If you want to omit the module name;

      include Pgplot

  * Pgplot module method names are lower case of corresponding
    PGPLOT functions.  To start plotting:

      pgbeg('/xwin')

    See PGPLOT manual for function usage.
    Arguments are not always same as the FORTRAN PGPLOT.
    "FuncUsage" file includes a list of functions with
    different arguments.

= Platforms tested

  * Ruby 1.8.5 (2006-08-25) [i686-linux]
  * NArray 0.5.9
  * gcc/gfortran 4.1.1 20060525 (Red Hat 4.1.1-1)

= License

  This program is free software.
  You can distribute/modify this program
  under the same terms as Ruby itself.
  NO WARRANTY.

= Acknowledgment

  M.T. thanks to Tim Pearson for developing the useful PGPLOT library
  and giving me the permission to distribute the Ruby version of pgdemos.
  M.T. also thanks to the developers of the Ruby language
  for providing the wonderful language.