source: trunk/SRC/Tests/TestsOld/tst_basic_old.pro @ 134

Last change on this file since 134 was 134, checked in by navarro, 18 years ago

change *.pro file properties (del eof-style, del executable, set keywords Id

  • Property svn:keywords set to Id
File size: 842 bytes
Line 
1PRO tst_basic_old
2;
3; figure 1: basics plots
4;
5; 1) plot
6;
7;
8  compile_opt idl2, strictarrsubs
9;
10  n = 10
11  y = findgen(n)
12; basic plot
13  splot, y, petit = [2, 2, 1], /portrait
14; improved plot by using plot and "graphic keywords"
15  splot, y, petit = [2, 2, 2], /noerase, yrange = [0, (n-1)^2], title = 'x and x^2'
16  oplot, y^2, color = 100, linestyle = 2, thick = 3
17;
18; 2) contour
19;
20  z = dist(n)
21; basic plot
22  scontour, z, /fill, nlevels = 15, petit = [2, 2, 3], /noerase
23; improved plot by using contour and "graphic keywords"
24  ind = findgen(2*n)/(2.*n)
25  scontour, z, levels = n*ind, c_orientation = 180*ind, c_spacing = .2*ind $
26            , petit = [2, 2, 4], /noerase
27  contour, z, /overplot, c_label = rebin([1, 0], 2, n), levels = n*ind $
28           , c_charthick = 2, c_charsize = 1.5, c_colors = 250*ind
29           
30  return
31end
Note: See TracBrowser for help on using the repository browser.