More samples in the graphic help pages Note that they are automatically generated...
[scilab.git] / scilab / modules / graphics / help / en_US / axes_operations / plotframe.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3  * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
4  * Copyright (C) INRIA
5  * 
6  * This file must be used under the terms of the CeCILL.
7  * This source file is licensed as described in the file COPYING, which
8  * you should have received as part of this distribution.  The terms
9  * are also available at    
10  * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
11  *
12  -->
13 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns5="http://www.w3.org/1999/xhtml" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" version="5.0-subset Scilab" xml:id="plotframe" xmlns:scilab="http://www.scilab.org" xml:lang="en">
14   <info>
15     <pubdate>$LastChangedDate: 2008-03-26 09:50:39 +0100 (Wed, 26 Mar 2008)
16       $
17     </pubdate>
18   </info>
19   <refnamediv>
20     <refname>plotframe</refname>
21     <refpurpose>
22       plot a frame with scaling and grids. <emphasis role="bold">This function is obsolete.</emphasis>
23     </refpurpose>
24   </refnamediv>
25   <refsynopsisdiv>
26     <title>Calling Sequence</title>
27     <synopsis>plotframe(rect,tics,[arg_opt1,arg_opt2,arg_opt3])
28       plotframe(rect,&lt;opts_args&gt;)
29     </synopsis>
30   </refsynopsisdiv>
31   <refsection>
32     <title>Arguments</title>
33     <variablelist>
34       <varlistentry>
35         <term>rect</term>
36         <listitem>
37           <para>
38             vector <literal>[xmin,ymin,xmax,ymax]</literal>.
39           </para>
40         </listitem>
41       </varlistentry>
42       <varlistentry>
43         <term>tics</term>
44         <listitem>
45           <para>
46             vector <literal>[nx,mx,ny,my]</literal> where <literal>mx,
47               nx
48             </literal>
49             (resp. <literal>my, ny</literal>) are the number of
50             x-axis (resp. y-axis) intervals and subintervals.
51           </para>
52         </listitem>
53       </varlistentry>
54       <varlistentry>
55         <term>arg_optX</term>
56         <listitem>
57           <para>optional arguments up to three and chosen among.</para>
58           <variablelist>
59             <varlistentry>
60               <term>flags</term>
61               <listitem>
62                 <para>
63                   vector <literal>[wantgrids,findbounds]</literal> where
64                   <literal>wantgrids</literal> is a boolean variable
65                   (<literal>%t</literal> or <literal>%f</literal>) which
66                   indicates gridding. <literal>findbounds</literal> is a boolean
67                   variable. If <literal>findbounds</literal> is
68                   <literal>%t</literal>, the bounds given in
69                   <literal>rect</literal> are allowed to be slightly modified
70                   (in fact always increased) in order to have simpler
71                   graduations: then <literal>tics(2)</literal> and
72                   <literal>tics(4)</literal> are ignored.
73                 </para>
74               </listitem>
75             </varlistentry>
76             <varlistentry>
77               <term>Captions</term>
78               <listitem>
79                 <para>vector of 3 strings
80                   <literal>[title,x-leg,y-leg]</literal> corresponding
81                   respectively to the title of the plot and the captions on the
82                   x-axis and the y-axis. Warning: the upper-case "C" is important.
83                 </para>
84               </listitem>
85             </varlistentry>
86             <varlistentry>
87               <term>subwin</term>
88               <listitem>
89                 <para>a vector of size 4 defining the sub window. The sub
90                   window is specified with the parameter
91                   <literal>subwin=[x,y,w,h]</literal> (upper-left, width,
92                   height). The values in <literal>subwin</literal> are specified
93                   using proportion of the width or height of the current
94                   graphics window (see <literal>xsetech</literal>).
95                 </para>
96               </listitem>
97             </varlistentry>
98           </variablelist>
99         </listitem>
100       </varlistentry>
101       <varlistentry>
102         <term>&lt;opts_args&gt;</term>
103         <listitem>
104           <para>
105             This represents a sequence of statements <emphasis role="bold">key1=value1</emphasis>,<emphasis role="bold">
106               key2=value2
107             </emphasis>
108             ,... where <emphasis role="bold">key1</emphasis>, <emphasis role="bold">key2</emphasis>,... can be one of the following:
109             <emphasis role="bold">tics</emphasis>, <emphasis role="bold">flags</emphasis>, <emphasis role="bold">captions</emphasis> ou <emphasis role="bold">subwin</emphasis>. These arguments have the same meaning
110             as the ones used in the first form of the routine.
111           </para>
112         </listitem>
113       </varlistentry>
114     </variablelist>
115   </refsection>
116   <refsection>
117     <title>Description</title>
118     <para>
119       <literal>plotframe</literal> is used with 2D plotting functions
120       <link linkend="plot2d">plot2d</link>, <link linkend="plot2d1">plot2d1</link>,... to set a graphics frame. It must be
121       used before <literal>plot2d</literal> which should be invoked with the
122       "000" superposition mode.
123     </para>
124     <para>
125       <emphasis role="bold">This function is obsolete.</emphasis>
126     </para>
127   </refsection>
128   <refsection>
129     <title>Examples</title>
130     <programlisting role="example"><![CDATA[ 
131 x=[-0.3:0.8:27.3]';
132 y=rand(x);
133 rect=[min(x),min(y),max(x),max(y)];
134 tics=[4,10,2,5];    //4 x-intervals and 2 y-intervals
135 plotframe(rect,tics,[%f,%f],["My plot","x","y"],[0,0,0.5,0.5])
136 plot2d(x,y,2,"000")
137 plotframe(rect,tics=tics,flags=[%t,%f],Captions=["My plot with grids","x","y"],subwin=[0.5,0,0.5,0.5])
138 plot2d(x,y,3,"000")
139 plotframe(rect,tics,[%t,%t],..
140 ["My plot with grids and automatic bounds","x","y"],[0,0.5,0.5,0.5])
141 plot2d(x,y,4,"000")
142 plotframe(rect,flags=[%f,%t],tics=tics,..
143           Captions=["My plot without grids but with automatic bounds ","x","y"],..
144           subwin=[0.5,0.5,0.5,0.5])
145 plot2d(x,y,5,"000")
146  ]]></programlisting>
147   </refsection>
148   <refsection role="see also">
149     <title>See Also</title>
150     <simplelist type="inline">
151       <member>
152         <link linkend="plot2d">plot2d</link>
153       </member>
154       <member>
155         <link linkend="graduate">graduate</link>
156       </member>
157       <member>
158         <link linkend="xsetech">xsetech</link>
159       </member>
160     </simplelist>
161   </refsection>
162 </refentry>